-
-
Notifications
You must be signed in to change notification settings - Fork 727
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fine performance metrics: apportion to Computations #7776
Comments
Note: it's been observed that there's occasional overlap between Computation objects. This should not happen, and needs to be treated as a blocker to this ticket. |
Here's an example Coiled cluster w/ overlapping computations, though it may be an odd case: https://cloud.coiled.io/clusters/194048/overview?account=dask-engineering |
Here's the relevant code: distributed/distributed/scheduler.py Lines 4322 to 4327 in b83c055
If the cluster is idle, compute() and submit() create a new Computation. Otherwise, they attach to the last one chronologically. @fjetter @hendrikmakait how much do you trust @ntabris @hendrikmakait I don't think we have anything on our dashboard highlighting hard worker restarts (e.g. not graceful shutdown, not calls The worker crash use case is a bit of a problem. Because on one hand, adding to a computation that is no longer the latest is the correct thing to do in this case. On the other hand, though, we don't have this kind of information with the metrics coming from the heartbeat, so we can only attach to the latest computation. |
Another use case for overlapping computations:
>>> x = client.submit(lambda: 1, key="x", resources={"XXX": 1})
>>> y = client.submit(lambda: 1, key="y")
>>> client.cluster.scheduler.computations
deque([<Computation cb97f633-68e3-45d5-9684-3bc670b357ae: Tasks: no-worker: 1>,
<Computation 0562da4e-71a2-4573-80dc-c9a10abedfdd: Tasks: memory: 1>],
maxlen=100) Again, this logic is sound but is not compatible with metrics apportion. |
Yet another way to get overlapping computations: |
Not really, no. What are the ways I can tell these occurred? |
None of these are nice or intuitive - we could use a dedicated prometheus counter. |
Hm, okay, yeah, I don't really want to rely much on indirect signals like that. Those would be pretty hard to query on. |
@fjetter @ntabris @hendrikmakait This conversation has become very fragmented, so I'll recap everything that has been said so far here. End goalAs an intermediate Dask user, I want to
[a] Here, a computation is what a novice to intermediate dask user would intuitively intend as a monolithic group of work; which means
Current stateWe are currently sending from the workers to the scheduler this information through the heartbeat:
On the scheduler, we have
The problemNaively, one would think that by construction I believe there are at least three use cases which causes computations to overlap:
The phenomenon of computations overlap is an obstacle to apportioning fine performance metrics to
The moment you have 2+ computations active at the same time, they will steal time from each other. I don't have a measure of how much idle time we currently have in coiled/benchmarks. I expect it to be frequently substantial, and heavily use case-dependent. Observations
This design would make multitenancy scenarios more readable, at the cost of having massive amounts of "idle" time which can only be explained by looking at all the other computations going on at the same time. It would also, in my opinion, be problematic when the "multitenancy" is actually a single (human) user invoking |
Just throwing around a thought: Should all this detailed and analytics-focused functionality even live on the scheduler? The scheduler is both an operational component and the most prone to becoming a bottleneck in large-scale scenarios. Since what we are trying to do here is some mix of collecting and processing traces/metrics, a dedicated component might make more sense here. This could potentially help us address some of the complications we face with the current state. |
@fjetter, @hendrikmakait, @ntabris and I had an extensive offline discussion about this. This conversation continues on #7860 |
This ticket will now be closed by apportioning the fine performance metrics to Spans. |
Computation objects are commonly used by third-party Scheduler plugins (e.g. Coiled Analytics) to visualize data.
They can be crudely defined as everything that happened to the cluster between two moments when it was idle.
As there should be only one active at any given time, it makes perfect sense to apportion the metrics to the Computation objects, in addition to the Scheduler's global ever-increasing counter.
The text was updated successfully, but these errors were encountered: