Earlier  
Posted Nick Remark
#openstack-nova - 2019-11-22
20:01:05 mriedem since https://docs.openstack.org/python-openstackclient/latest/cli/command-objects/server-event.html doesn't take a --delete option, to fix the bug there i'd probably handle a NotFound when looking up the server by name or id, and if --os-compute-api-version >= 2.21 then just assume you were given an ID and pass it through
20:01:15 mriedem it'll either work or the user will get a 404 anyway
20:02:13 melwitt KeithMnemonic: yeah, like I said, I think even with the legacy client, the underlying binding that osc is using, there's no way to lookup deleted by name
20:02:37 melwitt so if you want that, you'd have to add it to the novaclient python binding too, afaik
20:02:38 mriedem i'm not sure that's true - if you're admin you can list servers filtering on deleted=True and name
20:03:01 melwitt list you can, but I'm not sure about like nova show
20:03:16 mriedem right, not in the api - it would be client side sugar
20:03:48 melwitt yeah, that's what I mean. novaclient needs something to be able to. unless you're saying on the cli can't and that the python api can
20:03:58 mriedem heh, "Filters the response by a server name, as a string. You can use regular expressions in the query. For example, the ?name=bob regular expression returns both bob and bobb. If you must match on only bob, you can use a regular expression that matches the syntax of the underlying database server that is implemented for Compute, such as MySQL or PostgreSQL."
20:04:13 mriedem "if you know the cloud you're talking to is using mysql or postgres, just fashion your filtering that way"
20:04:37 melwitt lol
20:05:02 melwitt I'm super rusty on the clients, gotta get back in there
20:05:24 artom mriedem, sql injection as a service
20:07:16 KeithMnemonic and also the using "id" only started working after I applied mriedem's fix for the marker. Gentle plug, any change to get those last few you submitted merged? https://review.opendev.org/#/c/690721/4
20:11:09 mriedem fwiw i would not spend a bunch of time trying to build "find deleted service by name using list" for this action events osc bug - it's likely more of a corner case, only possible to do that with admin anyway (list deleted servers and filter by name), i would just make it work if an id is provided and not a name, like i said above
20:11:18 mriedem *server
20:11:36 mriedem you don't have to know if it's an id or a name, just:
20:11:45 mriedem 1. if find by name or id returns NotFound
20:11:51 mriedem 2. if microversion >= 2.21
20:11:55 mriedem 3. then pass through to the api and assume it works
20:12:13 mriedem probably update the osc docs as well to say if you're trying to list actions for a deleted server, you must provide the server id
20:14:40 KeithMnemonic melwitt do you me to abandon my patch or do you want to add to it,. the code there does work with marker being an ID
20:15:55 mriedem KeithMnemonic: she's talking about fixing a different bug
20:15:58 mriedem different command
20:16:01 openstackgerrit Matt Riedemann proposed openstack/nova master: Add contributor doc for resize and cold migrate https://review.opendev.org/695609
20:16:01 openstackgerrit Matt Riedemann proposed openstack/nova master: Add sequence diagrams to resize/cold migrate contrib doc https://review.opendev.org/695759
20:21:08 KeithMnemonic ah ok
20:23:15 KeithMnemonic i thought you were talking about the osc behavior sean-k-mooney mentioned above when you referenced my bug
20:24:19 melwitt well, I thought maybe the two (not being able to get --deleted) had the same root cause but they might not. I didn't look that deeply at it yet nor do I already know that much about osc
20:26:58 melwitt but yeah actually we can already tell they're not because KeithMnemonic's problem is only around the name
20:27:40 melwitt mriedem: ack, that was my intention, make it work with id. because even the legacy novaclient can't do name for the instance action list
20:27:51 melwitt for deleted servers
20:29:47 KeithMnemonic my bug is with id also
20:30:08 melwitt I thought you said it works with id earlier
20:30:20 KeithMnemonic the nova cli, sorry the person who reported it to us used id
20:30:34 KeithMnemonic this worked nova list --deleted --marker c244e139-98fe-44eb-a971-c067954da026
20:31:44 KeithMnemonic this did not openstack server list --delete --marker f1ed3399-b4d3-4c74-a8aa-4b5b935bc8d1
20:32:20 KeithMnemonic but with that patch i have up, marker works
20:32:37 KeithMnemonic sorry for the confusion
20:45:57 artom mriedem, did you mean to not push the sequence diagram?
20:46:03 artom Because... you didn't.
20:48:24 mriedem artom: but i....did
20:48:28 mriedem https://review.opendev.org/695759
20:48:37 mriedem "A sequence diagram is sorely needed for this as well but that will come in a separate change."
20:49:12 artom gdi it's on top
20:49:18 artom mriedem, sorry
20:57:33 openstackgerrit Merged openstack/nova master: Remove '/os-tenant-networks' REST API https://review.opendev.org/686810
20:57:39 openstackgerrit Merged openstack/nova master: nova-net: Remove 'USE_NEUTRON' from functional tests https://review.opendev.org/686811
20:57:46 openstackgerrit Merged openstack/nova master: docs: Remove 'adv-config', 'system-admin' subdocs https://review.opendev.org/684402
20:57:53 openstackgerrit Merged openstack/nova master: docs: Replacing underscores with dashes https://review.opendev.org/685929
20:58:00 openstackgerrit Merged openstack/nova master: docs: Strip '.rst' suffix https://review.opendev.org/687264
20:58:13 openstackgerrit Merged openstack/nova master: Don't claim that CLI user data requires manual base64 encoding https://review.opendev.org/674665
20:58:21 openstackgerrit Merged openstack/nova master: Make it easier to run a selection of tests relevant to ongoing work https://review.opendev.org/677180
21:05:48 melwitt KeithMnemonic: if I were you I'd make it work with ID only and forget about name for now. the name requires a further change to python-novaclient (AFAIK) and it's already standard operating procedure that some APIs or options only work with ID. not ideal perhaps but it is what it is. just MHO
21:06:23 KeithMnemonic ok so my patch does that ;-)
21:06:31 melwitt yeah, you need to update it no?
21:06:41 KeithMnemonic i can
21:06:54 melwitt update the doc and everything mriedem pointed out on the patch
21:07:11 KeithMnemonic as long as it seems everyone here is ok with the concept
21:07:14 melwitt to make sure marker referenced by ID is consistent
21:07:21 KeithMnemonic thanks for the help
21:07:55 melwitt yeah I think so, unless I'm totally missing something, which I might be. people letting me know lately that I've missed a lot ;)
21:08:17 melwitt I don't see why doing it ID only would not be ok
21:10:38 KeithMnemonic ok thanks again, any chance i can get some movement on that other patch by mriedem for rocky that fixes the marker? he made a ton of progress before the summit but it seems to have stalled
21:10:57 KeithMnemonic it is merged through stein now
21:11:40 melwitt yeah. my head's spinning with all the stuff I'm trying to do but I'll try to get those. they're not 100% easy bc there's differences and conflicts to look at
21:15:51 melwitt KeithMnemonic: I guess the sticking point on the osc one is that it's a change in behavior? does that mean that marker by name works with non-deleted servers?
21:16:48 KeithMnemonic yes it does
21:17:07 melwitt ahhhh dammit
21:17:16 KeithMnemonic so maybe some logic needs to go around the change to only do it if -deleted is passed
21:18:06 melwitt yeah like, do some extra stuff (client gymnastics) to get the server by name first then call with marker if --deleted is passed
21:18:14 KeithMnemonic that way it does not break anything but makes -deleted work in once case at least
21:18:23 melwitt *with marker as ID if --deleted is passed
21:18:27 KeithMnemonic yup
21:18:39 melwitt yeah ok. I get it now
21:19:32 KeithMnemonic let me spin up a fresh devstack and start hacking on it again
21:19:47 melwitt yeah so I rewind from what I said earlier and I'd do the extra step if --deleted is passed. grab the server id and then pass marker as id under the covers
21:21:07 openstackgerrit Merged openstack/nova master: Remove 'os-consoles' API https://review.opendev.org/687907
21:26:34 mriedem heh, this is a bit old https://docs.openstack.org/nova/latest/reference/vm-states.html#create-instance-states
21:26:42 mriedem api -> compute done!
21:37:05 openstackgerrit Matt Riedemann proposed openstack/nova master: api-guide: flesh out BUILD and ACTIVE server create transitions https://review.opendev.org/695771
21:43:15 openstackgerrit Matt Riedemann proposed openstack/nova master: api-guide: fix the file injection considerations drift https://review.opendev.org/695773
21:48:42 openstackgerrit Merged openstack/nova master: Avoid raise InstanceNotRunning exception https://review.opendev.org/541152
21:48:48 openstackgerrit Matt Riedemann proposed openstack/nova master: api-guide: remove empty sections about inter-service interactions https://review.opendev.org/695774
21:48:51 openstackgerrit Merged openstack/nova master: Start README.rst with a better title https://review.opendev.org/695025
22:16:53 openstackgerrit Matt Riedemann proposed openstack/nova master: api-guide: flesh out flavor extra specs and image properties https://review.opendev.org/695776
22:33:37 openstackgerrit Matt Riedemann proposed openstack/nova master: api-guide: flesh out networking concepts https://review.opendev.org/695777
22:33:44 melwitt efried: question on test cleanup https://review.opendev.org/685399
22:33:52 efried ...
22:35:01 efried I think you're probably right. Lemme check one thing quick...
22:36:05 melwitt ok. I wasn't sure how this is supposed to be
22:37:10 efried Yup, I think that was just a miss melwitt, good spot, will remove.
22:38:24 openstackgerrit Eric Fried proposed openstack/nova master: test cleanup: Make base TestCase subclass oslotest https://review.opendev.org/685399
22:38:30 efried melwitt: done, thanks.
22:38:46 melwitt kewl
22:39:30 efried thanks for those reviews melwitt
22:39:54 efried a day when my dashboard shrinks is a good day :)
22:40:32 efried and johnthetubaguy ^
22:41:14 melwitt np, nice cleanups
22:43:01 openstackgerrit Merged openstack/nova master: Remove 'nova-console' service, 'console' RPC API https://review.opendev.org/687908

Earlier   Later