Earlier  
Posted Nick Remark
#openstack-nova - 2022-05-19
11:57:51 gibi but that is fine
11:58:34 sean-k-mooney im going to get coffee quickly brb
12:00:56 gibi sean-k-mooney: about the unbind, stephenfin's patch just shows that unbind removes the device_id from the port so we cannot bindly unbind at offload
12:05:41 sean-k-mooney gibi: that is not an unbind then
12:05:58 gibi the function is called unbind :)
12:06:00 sean-k-mooney at least not at the nutron api level
12:06:06 sean-k-mooney right its miss named
12:06:17 sean-k-mooney that is unbind_and_detach
12:06:18 gibi https://review.opendev.org/c/openstack/nova/+/842528/2/nova/network/neutron.py#616
12:06:49 sean-k-mooney ya that function should be renamed
12:06:58 sean-k-mooney that is actully a detach
12:07:18 sean-k-mooney its a detach and clearing of dns_name
12:08:19 sean-k-mooney actully does this even do an unbind
12:08:52 sean-k-mooney ah i t does line644
12:09:20 sean-k-mooney constants.BINDING_HOST_ID: None,
12:09:43 sean-k-mooney is the actual unbind
12:10:26 sean-k-mooney gibi: this is being used as part of instance delete which is why its doing all the other stuff
12:10:54 gibi yeah, this is correct during delete but it would not be corrrect during offload
12:10:57 sean-k-mooney its just combining the unbind with teh other operations needed to reset the port
12:11:14 sean-k-mooney right but that function is not only doing an unbind
12:11:24 sean-k-mooney i never said we shoudl use that funciton
12:12:38 gibi sure
12:12:52 gibi it is about terminology
12:12:53 sean-k-mooney we shoudl proably rename that "release_ports" or "reset_ports"
12:13:00 gibi yeah I agree
12:13:15 sean-k-mooney right terminology wise that function is missnamed
12:13:42 sean-k-mooney if i propose a patch for unshelve
12:13:50 sean-k-mooney ill porpsoe a clean up patch to rename this
12:14:07 gibi ack
12:15:02 sean-k-mooney speaking of patchs my spawn_n patch actully passed ci this time
12:15:07 sean-k-mooney well ignoreing pep8
12:15:23 sean-k-mooney but it did not seam to really decrease the number of greenlets
12:15:34 sean-k-mooney i guess becasue when we are counting them
12:15:41 sean-k-mooney we count the wrapped greenlets
12:15:48 sean-k-mooney and the freestanding ones
12:16:03 sean-k-mooney so as you predicted it has no visabel effect
12:18:52 gibi the code should only count naked greenlets that are not wrapped
12:19:00 gibi in a GreenThred
12:19:14 sean-k-mooney hum well the number looked identical
12:19:32 gibi https://review.opendev.org/c/openstack/nova/+/841040/6/nova/compute/manager.py#10150
12:19:33 sean-k-mooney its possible it did not work i coudl add a func test to check
12:19:59 gibi greenlets might be special from the GC perspective as they are implemented in a C extension
12:20:10 gibi so this can be a side effect of my hack to looking at the GC
12:20:50 sean-k-mooney maybe
12:20:53 sean-k-mooney not really sure
12:20:57 gibi me neither
12:21:06 sean-k-mooney will isinstance look at inheritance
12:21:11 gibi yepp
12:21:15 gibi it does
12:21:40 sean-k-mooney and GreenThread contains but is not a greenlet
12:22:09 Uggla gibi, looking at the table, line 3 we came back to the original behavior right ? Which is something we wanted to avoid. (Not break user choice to keep the instance floating.)
12:22:22 sean-k-mooney gibi: https://github.com/eventlet/eventlet/blob/master/eventlet/greenthread.py#L163=
12:22:30 Uggla gibi, although I think it is a better choice.
12:23:07 gibi GreenThread derives from greenlet https://github.com/eventlet/eventlet/blob/master/eventlet/greenthread.py#L163
12:23:28 gibi sean-k-mooney: you were faster
12:23:42 sean-k-mooney gibi: yep so greenlet includes all the greenthread too
12:23:43 gibi so isinstance(GreenThread(), greenlet) is True
12:23:50 sean-k-mooney ya
12:23:50 gibi the count does not
12:23:55 gibi as I have an if
12:24:09 gibi naked = [g for g in greenlets if g not in greenthreads]
12:24:22 sean-k-mooney oh ya
12:24:23 gibi so only count those greenlets that are not counted for greenthread
12:24:23 gibi s
12:24:34 sean-k-mooney did see that look was lookign jsut at greenlets and ghreenthreads
12:25:00 gibi ah jeah I forgot to log _naked_ greenlet
12:25:05 gibi hm
12:25:06 gibi I idd
12:25:07 gibi did
12:25:16 sean-k-mooney you jsut didnt log total
12:25:17 gibi so naked here means not wrapped in a GreenThread
12:25:26 gibi yeah I did not log total as that would count things twice
12:26:00 gibi i.e. a GreenThread would also be counted as greenlet too
12:26:23 sean-k-mooney Uggla: no we are redefiening what the qeust means
12:26:44 sean-k-mooney we are defien that if you pass an AZ you are requesting for it to be pinned to that az
12:26:57 sean-k-mooney which is the current unshelve to az beahvior
12:27:03 gibi yepp
12:27:22 Uggla sean-k-mooney, gibi , I'have just got it. Seems ok for me.
12:27:54 sean-k-mooney Uggla: so we found that odd in the previous case beacue of the implict magic of updating az somethimes but nota always
12:28:09 sean-k-mooney but now that its only ever updated explcitly in this table
12:28:14 sean-k-mooney its consistent
12:28:50 Uggla sean-k-mooney, I agree it is better now and unpin/pin is possible which is cool.
12:30:00 sean-k-mooney Uggla: for better or worse this is why we have specs for api changes
12:30:24 sean-k-mooney Uggla: something that seams simple like "just unshalve to this host" can have subtel issues with considtency
12:30:33 sean-k-mooney so hopefully this has not put you off specs
12:31:34 Uggla sean-k-mooney, completely understand, I was worried by the fact that unpin was not possible. Now the spec is better.
12:31:42 sean-k-mooney gibi: ill proably respin my monkey_patch change and add a release note then bring it up in the next team meeting
12:32:01 sean-k-mooney gibi: basiclly so we want to proceed with it to get operator feedback or abandon it
12:32:21 sean-k-mooney defaulting to False of cource so its opt in not opt out
12:33:24 Uggla sean-k-mooney, I have also learn to take time to mature the spec before doing the code.... ;)
12:34:17 sean-k-mooney hehe well there are pros and cons to that technially you are ment to wait for the spec to be approve to start on the code however doing a quick poc can help with writing the spec in some cases
12:35:03 sean-k-mooney often it can be helpfull to get something mostly working but defer the docs and test code till after the spec is approved
12:35:12 sean-k-mooney but only for small changes
12:35:34 Uggla sean-k-mooney, I agree, for the unshelve one I would have wait before redoing it. On the virtiofs, doing it in // helps me to better understand and to have questions.
12:38:44 Uggla gibi, fyi I have removed the point for today's call.
12:39:33 Uggla sean-k-mooney, gibi I'm gonna update the spec with these new data. If you are ok ?
12:39:35 sean-k-mooney for spec design stuff we try to keep as much of it public as we can anyway
12:40:10 sean-k-mooney Uggla: am sure you could
12:41:31 sean-k-mooney Uggla: when we bring up topic in internal calls it generally for high level brain stroming and we dig into the detail in specs,mailing list or public irc
12:42:37 Uggla sean-k-mooney, ok

Earlier   Later