| Posted | Nick | Remark | |
|---|---|---|---|
| #openstack-nova - 2019-12-13 | |||
| 19:59:57 | efried | yeah, looking at the previous run, it's only pep8 and docs. | |
| 20:00:01 | efried | so it ought to work. | |
| 20:06:29 | openstackgerrit | Matt Riedemann proposed openstack/nova stable/rocky: Add --dry-run option to heal_allocations CLI https://review.opendev.org/698525 | |
| 20:06:30 | openstackgerrit | Matt Riedemann proposed openstack/nova stable/rocky: Add BFV wrinkle to TestNovaManagePlacementHealAllocations https://review.opendev.org/698531 | |
| 20:06:30 | openstackgerrit | Matt Riedemann proposed openstack/nova stable/rocky: Add --instance option to heal_allocations https://review.opendev.org/698529 | |
| 20:17:27 | mriedem | efried: i replied for gibi on https://review.opendev.org/#/c/696574/ - see if that answers your question | |
| 20:19:22 | efried | thanks mriedem, +A | |
| 20:19:49 | efried | mriedem: wanna hit this trivial +A? https://review.opendev.org/698988 | |
| 20:23:49 | efried | dansmith: bikeshedding opportunity: | |
| 20:23:56 | mriedem | done | |
| 20:24:59 | efried | RequestSpec needs a field (possibly two) to store root_required (which can take required or forbidden (with !) just like regular required). This is parallel with requested_resources. | |
| 20:25:31 | efried | It's what we always wanted to use from those request_filters rather than hacking into the flavor and doing obj_reset_changes(), which I'll fix up at the same time. | |
| 20:25:33 | mriedem | that can't be hacked into the RequestGroup? | |
| 20:25:50 | efried | No, specifically because it's not per request group. | |
| 20:25:51 | dansmith | right, was just going to say.. why isn't it inside requested_resources? | |
| 20:26:02 | efried | That's it's whole raison d'être | |
| 20:26:11 | efried | requested_resources is a list of RequestGroup. | |
| 20:26:14 | mriedem | the issue i always had with the RequestGroup for that traits-only stuff is the RequestGroup stuff in the scheduler made resources required | |
| 20:26:35 | dansmith | oh because requested_resources is a list of requestgroup objects | |
| 20:27:09 | dansmith | that field probably should have been an ObjectField('PlacementyShit') | |
| 20:27:11 | efried | well a) pretty sure that's not a thing anymore, I think we did away with that on the placement side; but b) that's exactly what root_required is for: so you can specify required/forbidden traits that you *for sure* want to look for on the root RP, without association with any request groups | |
| 20:27:12 | mriedem | can you have a root unnumbered group or something for modeling this? | |
| 20:27:26 | mriedem | DictOfStringsField(put all the crap) | |
| 20:27:58 | mriedem | so building on RequestGroup as an object would probably just be confusing for tihs right? | |
| 20:28:11 | efried | would make no sense | |
| 20:28:24 | efried | a request has N RequestGroup. It only has one root_required | |
| 20:28:39 | efried | RequestGroup contains resources, traits, aggregates. root_required only traits. | |
| 20:28:41 | dansmith | efried: what is your actual quesiton? | |
| 20:28:46 | efried | what should we name those fields | |
| 20:28:54 | dansmith | ? | |
| 20:28:54 | dansmith | field or fields | |
| 20:28:56 | efried | One for required, one for forbidden. SetOfStringsField. | |
| 20:29:03 | efried | root_required, root_forbidden? | |
| 20:29:14 | efried | root_required_traits, root_forbidden_traits? | |
| 20:29:21 | mriedem | feels like a field explosion | |
| 20:29:28 | efried | requested_root_traits_required, requested_root_traits_forbidden? | |
| 20:29:30 | mriedem | throw it into a RootProviderConstraints objects? | |
| 20:29:30 | dansmith | how about we add PlacementyShit and put them on that object, so that when we have the next thing, we don't keep adding placementy fields to reqspec? | |
| 20:29:42 | dansmith | mriedem: PlacementyShit | |
| 20:30:36 | dansmith | pretty sure the tc had to cancel their phone plan to pay the electric bill | |
| 20:30:53 | efried | yeah, we could make ResourceRequest an OVO and make RequestSpec.resource_request. That's probably something we want to consolidate eventually anyway. | |
| 20:31:04 | mriedem | ha | |
| 20:31:25 | mriedem | RequestSpec.resource_request and RequestSpec.requested_resources | |
| 20:31:26 | efried | that would mean we should drop requested_resources though. Deleting a field from an OVO sounds scary. | |
| 20:31:27 | mriedem | very confusing | |
| 20:31:33 | mriedem | it's a major version bump | |
| 20:31:39 | mriedem | the likes of which only dan-o can navigate | |
| 20:31:40 | efried | Course, everything OVO is scary to me. | |
| 20:31:58 | efried | so what's the lesser evil here? | |
| 20:32:13 | efried | placement_shit = DictOfStringsField? | |
| 20:32:14 | dansmith | yep, don't do that right now, I'd just add a peer object next to requested_resources, leave the latter the same, put your flags and stuff in the new object | |
| 20:32:16 | dansmith | no | |
| 20:32:21 | dansmith | god no. | |
| 20:32:56 | efried | new PlacementShit OVO and placement_shit = PlacementShitField()? | |
| 20:33:03 | dansmith | no | |
| 20:33:29 | dansmith | reqspec.PlacementShit = ObjectField('PlacementShit'), | |
| 20:33:48 | dansmith | then in the PlacementShit object, whatever fields you need | |
| 20:33:52 | dansmith | root_required is what, a boolean? | |
| 20:33:58 | efried | set of traits | |
| 20:33:59 | dansmith | or a list of traits | |
| 20:34:08 | efried | prefer a set if poss, to squash dups | |
| 20:34:10 | dansmith | so root_required = ListOfStringsField() | |
| 20:34:26 | efried | We have a SetOfStringsField, any reason to avoid it? | |
| 20:34:28 | mriedem | we do have a set of strings field, RequestGroup uses it | |
| 20:34:34 | dansmith | not sure we have one of those, but seriously we don't have to use sets everywhere, just run it through a set somewhere | |
| 20:34:43 | dansmith | no, if we have one that's fine | |
| 20:34:43 | mriedem | sets or bust! | |
| 20:34:48 | efried | cool | |
| 20:34:52 | dansmith | it's silly, IMHO, but... :) | |
| 20:34:53 | efried | thanks. | |
| 20:34:56 | mriedem | BagODicts | |
| 20:41:05 | openstackgerrit | Balazs Gibizer proposed openstack/nova master: Func test for qos live migration reschedule https://review.opendev.org/699015 | |
| 20:43:42 | efried | dansmith: and what's the accepted way to use default on a field? | |
| 20:44:15 | efried | e.g. default=set(), does that help me not have to check if present => check if None => check if empty? | |
| 20:46:07 | openstackgerrit | Merged openstack/nova-specs master: [ussuri][goal] Drop python 2.7 support https://review.opendev.org/698988 | |
| 20:48:07 | openstackgerrit | Merged openstack/nova stable/pike: Add functional regression test for bug 1849409 https://review.opendev.org/690734 | |
| 20:48:08 | openstack | bug 1849409 in OpenStack Compute (nova) pike "openstack server list --deleted --limit -1 hangs" [High,In progress] https://launchpad.net/bugs/1849409 - Assigned to Matt Riedemann (mriedem) | |
| 20:50:40 | dansmith | efried: default=set() isn't going to work anyway | |
| 20:50:55 | efried | it's what RequestGroup is doing | |
| 20:51:03 | efried | so, in what way not work? | |
| 20:51:31 | dansmith | efried: IIRC, that will result in every object getting the same set(), potentially cross-polluting between requests | |
| 20:51:41 | dansmith | because the field is once per definition, and done at import time | |
| 20:51:47 | efried | oh, neat. | |
| 20:52:19 | dansmith | I don't see request group doing that | |
| 20:52:46 | dansmith | er, maybe I'm looking in the wrong place | |
| 20:53:22 | dansmith | ah yeah I see | |
| 20:54:09 | dansmith | oh, hmm, maybe we copy the field's definition in obj_set_defaults, hang on | |
| 20:54:17 | dansmith | ISTR that coming up and we hacked around it that way | |
| 20:54:44 | dansmith | yeah https://github.com/openstack/oslo.versionedobjects/blob/master/oslo_versionedobjects/base.py#L588 | |
| 20:54:57 | dansmith | alright, so ignore me I guess | |
| 20:55:31 | dansmith | a little dangerous but probably not in practice | |
| 20:55:47 | efried | then back to the original question, how should I manage this field? | |
| 20:55:48 | dansmith | but no, it doesn't help you not have to check for setted-ness | |
| 20:56:01 | dansmith | efried: you should always set it, or call obj_set_defaults() after you create it | |
| 20:56:11 | efried | but not via __init__ | |
| 20:56:22 | dansmith | I think you know the answer to that :) | |
| 20:56:35 | efried | would this be a thing for __new__ somehow? | |
| 20:56:55 | dansmith | it's less of a problem for a transient rpc-only object, but we really shouldn't create more examples for people to copy, not knowing the problems | |
| 20:56:56 | dansmith | efried: no | |
| 20:57:18 | mriedem | RequestGroup just sets defaults if it lazy-loads a field and i think all fields have defaults | |