-
Notifications
You must be signed in to change notification settings - Fork 107
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
Caching SLURM account information for use in app forms #1970
Comments
Yes I think we'd want this. We're adding That said, I don't think we'd want to use My guess is a simple group filter would do the trick. For us at OSC it'd be |
Unfortunately, it would not (I have groups, but not a pattern isolated to just slurm projects, and they might be present some time after expired projects). It just seems to me that the using the actual slurm account database just guarantees this is simply unconditionally correct for every site using OOD. What actually prompted me to write this feature request was due to seeing #1964 and thinking that this would basically render |
These would be separate fields.
No, not at all if it fits there.
This a choice you're presenting to the user. |
My goal here is to be able to stay as close to upstream as possible (since maintaining a fork is painful), so my hope is to find something pretty much everyone could be happy with to eliminate the need for forking off code. I have a few question marks/design decisions;
I suppose the main 2 options for problem 2 would be; b. Keep track of what combinations exist. Not at all difficult in the code; basically just a hierarchy e.g. {
'cluster_a': {
'account_a': ['partition_a', 'partition_b']
'account_b': ['partition_a']
}
'cluster_b': {
'account_c': ['partition_c']
}
} I've seen there is attributes:
account:
widget: "select"
options:
- [ "account_a", data-option-for-cluster-cluster_a: true ]
- [ "account_b", data-option-for-cluster-cluster_a: true ]
- [ "account_c", data-option-for-cluster-cluster_b: true ]
partition:
widget: "select"
options:
- [ "partition_a", data-options-for-account-account_a: true, data-options-for-account-account_b: true ]
- [ "partition_b", data-options-for-account-account_a: true ]
- [ "partition_c", data-options-for-account-account_c: true ] If other schedulers actually don't have this split of project allocations per partition, then, one could still just populate the struct completely. QoS is probably overkill (I don't want to present it), but I see no reason why it couldn't be done generally like this. |
We don't use partitions like that, so I'll have to think on how to compose these relationships. Ours are more like 'you request a gpu' so you get put into the That said - I think the interface would look more like this in I'll submit a ticket to it for the same and link it here. That way the adapters (slurm in this case) have to worry about how to implement it and OOD (in this ticket) can then stitch it all together because it is cluster + account aware. def queues
[ {
name: 'partition_a',
accounts: [ 'account_a', 'account_b' ]
}]
end
absolutely see this below.
|
Already had the ticket actually but now I can refine it. |
Sorry for a million questions here; the link to auto_modules.rb; isn't that just for automatically adding things to the form? I'm also a bit confused because I see both
and also https://github.com/OSC/bc_osc_jupyter/blob/master/form.yml.erb#L134 both the variants which made me even more confused in how it could work for |
I see how you got there. Disregard that fixture file. That was copied from our real rstudio app which had it's own javascript at the time (so cluster was assumed or the only thing toggling). This is the fixture file we use to test these features. I'm not sure what commit you'd linked but it seemed older.
This is exactly how this would work. Also look at Here are the docs on this feature. |
Thank you for the link! I tried searching but the RTD style page is pretty terrible when it comes to searching for dashes (https://osc.github.io/ood-documentation/develop/search.html?q=data-option-for) So then the only step required for this particular PR would be to implement the smart attributes. I think i have the full picture now. |
Sorry for the delay. No steps required - just submit a pull request! I did however get around to I'm looking more into getting the available queues from a system. The sticking point is that while Slurm can do this, other systems may not be able to. In any case, it'll be limited to slurm support if we can pull queues & accounts from Slurm. |
I had been meaning to have a go at this myself, but severe staff shortage ha forced me to completely drop everything non vital. Looking forward to see something like this upstream, as it would let me minimize my local changes. |
Feature request:
I currently have a dashboard initializer
apps/dashboard/initializers/ood.rb
which does;(which could of course be cleaned up (I think it should have used CurrentUser?), extended to fetch partitions, reservations, clusters. but I have not yet had any such need).
It lets me switch away from free text field as input and instead conveniently configure my apps to just do;
which conveniently only presents the user with valid options; and for most users there is just one option which gets auto-selected.
In fact, this seems so generally applicable, I can't think of a reason why you wouldn't always want to do it like this, having all of this just be the default behavior.
Extending it to a multi cluster setup also seems feasible.
Is there any broader interest in this? I can work on a PR if there is (though my ruby is weak)
┆Issue is synchronized with this Asana task by Unito
The text was updated successfully, but these errors were encountered: