Giter Club home page Giter Club logo

Comments (4)

jacobtomlinson avatar jacobtomlinson commented on June 16, 2024 1

Right now we propagate labels from the top-level DaskCluster and DaskWorkerGroup objects down to their child resources. So if you set foo=bar on the DaskCluster then you could use the foo=bar,dask.org/component=scheduler selector to select the scheduler service.

from dask-kubernetes.

jacobtomlinson avatar jacobtomlinson commented on June 16, 2024

I quickly threw together a ServiceMonitor that will scrape metrics for all Dask schedulers deployed with the operator.

apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
  name: dask-operator-scheduler
  labels:
    dask.org/component: "scheduler"
spec:
  selector:
    matchLabels:
      dask.org/component: "scheduler"
  targetLabels:
    - dask.org/cluster-name
  endpoints:
  - interval: 15s
    port: http-dashboard

I think it would make sense to optionally include this in the Operator Helm Chart with all the same templating and customisation as is available in the basic helm chart. This is a slightly different approach because one ServiceMonitor would be registered which would select all Dask clusters created by the operator. Compared to the Helm Chart which creates one ServiceMonitor per cluster.

I also had a play around with a PodMonitor for scraping worker metrics but the operator currently doesn't configure worker ports by default so that will take more work.

from dask-kubernetes.

preneond avatar preneond commented on June 16, 2024

@jacobtomlinson Wow., thank you! I already forked the repo and wanted to create PR for that feature. It would be also nice to have specs customizable in make_scheduler_spec / make_worker_spec to include some extra matadata labels when creating KubeCluster instance.

from dask-kubernetes.

jacobtomlinson avatar jacobtomlinson commented on June 16, 2024

Ok now that #688 is merged we can also create a PodMonitor to scrape worker metrics.

apiVersion: monitoring.coreos.com/v1
kind: PodMonitor
metadata:
  name: dask-operator-workers
  labels:
    dask.org/component: "worker"
spec:
  selector:
    matchLabels:
      dask.org/component: "worker"
  podTargetLabels:
    - dask.org/cluster-name
    - dask.org/workergroup-name
  podMetricsEndpoints:
  - interval: 15s
    port: http-dashboard

from dask-kubernetes.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.