13:00:04 #startmeeting nova api 13:00:05 Meeting started Wed Sep 21 13:00:04 2016 UTC and is due to finish in 60 minutes. The chair is alex_xu. Information about MeetBot at http://wiki.debian.org/MeetBot. 13:00:06 Useful Commands: #action #agreed #help #info #idea #link #topic #startvote. 13:00:08 The meeting name has been set to 'nova_api' 13:00:13 who is here today? 13:00:15 o/ 13:00:24 o/ 13:00:27 \o 13:00:47 i know sdague is around 13:00:53 o/ 13:00:57 yea, I guess so :) 13:01:08 o/ 13:01:08 is gmann here? 13:01:14 o/ 13:01:25 gmann is in germany I think for the infra/qa sprint 13:01:30 ah 13:01:44 no wonder mtreinish has avoided me all week 13:01:59 so I didn't have specfic thing in the list, but there are have some of items from mriedem, so just let us go through your items? 13:02:08 sure 13:02:29 #link https://review.openstack.org/#/c/301372/ 13:02:35 mriedem: ^ the first one 13:02:48 yeah so i need help with that one 13:03:16 like, i need some direction from sdague and/or ken'ichi 13:03:20 on what they wanted to see there 13:03:36 but this is the thing where the security_groups in a server create response are possibly wrong when using neutron 13:03:49 so we want to return a link instead for security_groups 13:03:57 shouldn't we just drop that feature in a new API version 13:04:13 so don't add any security_groups be default? or does that break something else? 13:04:29 mriedem: ok, this actually relates to a thing we were just talking about in #openstack-nova 13:04:50 johnthetubaguy: i thought about that too 13:04:52 what would a real security_groups representation look like? 13:05:12 it would look like a full proxy of neutron's APIs? 13:05:46 looks like just a wrap from per port to per instance 13:05:47 what I mean is, each port can have its own security group 13:05:53 do we have some examples of neutron vs nova? 13:06:27 examples of the current API response? 13:06:35 ok, personally I'd like to stare at the data comparisons a little bit before deciding what a best path forward is 13:06:56 because we've got a related issue that a server get, with neutron service down, causes a 500, because of security group listing 13:07:14 oh, good point 13:07:28 and I think the eventual approach should cover both cases 13:07:33 honestly, it feels like security groups and floating ips should be removed from the get server response 13:07:44 http://developer.openstack.org/api-ref/networking/v2/#security-groups-security-groups 13:07:47 now that doesn't fix the older versions 13:08:09 i feel like we're talking about different problems here, 13:08:16 ah, possibly 13:08:17 mriedem: we are 13:08:26 but I think they are related 13:08:35 the point of the spec, and the bug, is that when creating the server, we're returning the default secgroup b/c nova adds that by default, but neutron may not actually set that up 13:08:40 if the network doesn't have port security enabled 13:08:47 mriedem: right 13:09:02 so the spec was suggesting returning a link to the secgroup api for nova 13:09:15 I guess I am questioning why nova sets the default security group any more 13:09:19 before 2.36 that was a proxy to neutron 13:09:23 but the case in both of these is that we're building a server document with information where the source of truth is from neutron 13:09:35 and that goes wrong a few different ways 13:09:49 because of timing, defaults, and service outages 13:09:57 I thought the security-group is really for nova-network 13:10:14 alex_xu: neutron also has them, they act a little differently 13:10:26 neutron applies a default secgroup by default i think 13:10:31 if you have port security enabled on the network 13:10:55 sdague: i'm curious what nova api show when we have two different security-groups for two ports which belong to one instance 13:10:58 iff you don't provide a non-default secgroup 13:11:41 ah, that used to be us setting that, but I think we stopped doing that at some point 13:11:55 johnthetubaguy, regarding your comments on https://review.openstack.org/#/c/294513/18/nova/compute/api.py, what you wrote is definitely more elegant than what I did, but both excpetions had different attr when raising the exception, did that just slip by you or am I missing something 13:12:23 prateek: we're not talking about that right now 13:12:27 prateek: please ask questions in the nova channel, happily answer in there 13:12:35 ohkk sorry 13:12:47 i didnt look at that channel 13:13:12 so is the question if the server create response should even return security_groups at all? 13:13:28 thats where I am at, leave them out 13:13:39 and don't allow users to pass them in, either 13:13:41 prefer to remove them 13:14:16 why wouldn't we allow users to pass them in? 13:14:19 that seems odd 13:14:24 we allow you to pass in specific nics 13:14:36 so it should be a per nic thing, if we wanted it 13:14:46 really I would want folks to set it on the port, and pass us the port_uuid 13:14:47 johnthetubaguy: it seems like we need to redo the expected way to pass things around 13:15:15 can we decouple the two issues for now? 13:15:17 I feel like what we have is a flow from nova-network 13:15:28 sdague: yeah, +1 13:15:34 b/c my spec is not about redoing the entire server create api for how secgroups are passed in 13:15:35 and at least 2 (probably more) issues with that flow 13:15:55 I know, it just feels odd to allow people to pass things in, and not return them in any way 13:15:56 and I think we should walk through what the flow should look like in the neutron world 13:16:26 mriedem: honestly, I'm kind of -1 on doing that, because I think we're going to need to change a bunch of other stuff and there will end up being 4 microversions of fixing security groups 13:17:05 johnthetubaguy: do you have a more ideal flow in your head you could sketch out in an etherpad? 13:17:30 honestly, it feels like folks should just set this on their port outside of nova 13:18:00 or we expand --nic to include a security group thingy, referencing the one in neutron 13:18:01 johnthetubaguy: ok, that's fine, can you write that up, and the point to all the ways we would change the API to enforce that? 13:18:11 yeah, I should do that thing in some etherpad 13:18:30 because this is going to unwind like the proxy deprecation did, I think there are second order impacts that will only be clear once we write the whole thing out 13:18:42 #link https://etherpad.openstack.org/p/ocata-nova-security-groups 13:19:44 can you use nova-network after 2.36? i can't remember 13:19:49 ok, lets let that churn for a couple of days 13:19:50 how the proxy api breaks using nova-net 13:20:01 mriedem: you can't use nova-net after that 13:20:13 even on server create? 13:20:23 because the server api isn't deprecated 13:20:37 we didn't change the server representation 13:20:48 but the server representation never said "use_neutron" 13:21:21 right so i can create a server with nova-network and 2.latest 13:21:24 I think you can boot an instance with default setting using nova-net, but the good stuff breaks, but I could be remembering that wrongly 13:21:39 but if i try to list ips from that server at 2.latest with nova-network it should fail 13:21:47 right 13:22:29 mriedem: but server show still has them 13:22:32 i would just like to be clear about what breaks if we change the server create api wrt secgroups 13:22:46 mriedem: yes, agreed 13:23:38 ok let's move on 13:23:57 #link https://review.openstack.org/#/c/350277/ 13:24:02 so... I think we should make security groups not be a lie with neutron, which they kind of are. I think a couple of days of johnthetubaguy and others trying to figure out where all the rough edges are will help get a handle on the problem. 13:24:23 yeah, thats a fair summary I feel. 13:24:29 We have to think through this a bit since we should get it done in Ocata: https://review.openstack.org/#/c/350277/ - I like the suggestion from johnthetubaguy to model this like the volume attachments API. 13:24:40 "Deprecate os-interface proxy API" 13:24:46 this is the thing we missed in 2.36 13:24:55 where we have os-interface and os-virtual-interfaces 13:25:13 os-virtual-interfaces is purely nova-net today 13:25:19 b/c of the vifs in the nova db 13:25:37 os-interface is the proxy to neutron for listing ports 13:25:41 mriedem: I've been avoiding you? 13:25:46 and attach/detach ports 13:26:02 yeah, it feels like the cinder volume model is what we should model for VIFs, flow wise 13:26:03 mtreinish: yeah i've been driving by your house late at night and everything! 13:26:10 hah 13:26:13 johnthetubaguy: that seems reasonable 13:26:18 johnthetubaguy: yeah i like that too 13:26:31 so you'd have basically show, list, attach/detach 13:26:39 we should realistically probably pile up somewhere the rest of the things we were going to deprecate but never got around to 13:27:11 it was at least this and the image metadata proxy api 13:27:25 oh but os-cloudpipe too and things like that 13:28:09 also multi-nic which johnthetubaguy point out few days ago 13:28:38 so i think the path forward on https://review.openstack.org/#/c/350277/ is for me to rewrite it with this in mind: 13:28:46 1. make os-interface more like os-volume_attachments 13:28:49 yeah, there a few I keep finding when looking at the api-ref patches 13:28:54 2. deprecate os-virtual-interface 13:29:27 since os-virtual-interface only works for nova-net, deprecating that shouldn't be a big deal, it should have happened in 2.36 13:30:01 yeh, seems reasonable 13:30:13 we might also change os-interface GET/list to build that from the nova db model instead of a proxy to neutron 13:30:23 i'd have to think that through 13:30:34 we might have to proxy for anything that was created before the 2.32 microversion 13:31:32 anyway, i'll move forward with that and see what pits i fall into 13:32:10 next on the agenda: 13:32:10 We need someone to write a spec for supporting the standardized (formerly v3) instance diagnostics compute API from the REST API with a microversion, as a dependency for hyper-v to support that API: https://blueprints.launchpad.net/nova/+spec/hyperv-vm-diagnostics 13:32:32 claudiub was going to see if the person that was going to work on ^ was going to work on the api change 13:32:46 i'm throwing it out here in case someone wants to get a head start on the spec 13:33:21 this is the thing that garyk worked on to create the standard instance diagnostics object in the virt layer 13:33:33 but with the v3 api dropping out, we never ended up exposing that code from the REST API 13:33:36 yeah, so that needs an api change as well. my coleague can take care of the hyper-v bits, but he's pretty loaded with tasks, and won't have enough time for the api changes, especially since ocata is so sohort 13:34:12 #help need someone to write the spec for exposing the standardized instance diagnostics out of the REST API 13:34:17 i guess i could get a spec started 13:34:23 it's pretty straight-forward i think 13:34:26 mriedem: I can do that 13:34:31 ok 13:34:46 #action alex_xu to work on generic diagnostics spec 13:35:01 we should also probably mark actions from before as well 13:35:09 i think it's basically after microversion x you call nova.compute.api.API.get_instance_diagnostics 13:35:30 yea, i guess so 13:35:35 sdague: i'm not sure what that means 13:35:39 mark actions from before 13:35:39 #action johnthetubaguy to sketch out what an ideal security group workflow looks like in the nova api now with neutron as the presumed backend 13:35:57 oh 13:35:58 i see :) 13:36:07 #action mriedem to write up spec for os-virtual-interface deprecation 13:36:20 next topic 13:36:20 then they are recorded for revisit in next meeting 13:36:26 Does alex_xu have a spec for deprecating the proxy API for set/delete image metadata? 13:36:38 alex_xu: i know you reported a bug for that 13:37:02 mriedem: yea, I can begin to do that. so that need a separated microversion? 13:37:49 do we merge that with other thing we forget to deprecate? like multi-nic? 13:38:18 alex_xu: we could lump it in with others if that is easy 13:38:51 mriedem: ok, let me check how image metadata deprecation look like first 13:38:59 the novaclient changes are probably the worst part, but at least we know how to do those now 13:39:43 #action alex_xu to write a spec for deprecating the proxy api to set/delete image metadata 13:40:03 ok, last item, i swear :) 13:40:05 How can we test swap volume from Tempest? gmann was trying that at one point. 13:40:11 ^ is why i was looking for gmann 13:40:28 so apparently we regressed swap volume, which was already broken 13:40:33 ah bauzas was looking a some nasty bits around there recently 13:40:34 maybe mtreinish can take that back into the room there 13:40:36 it's just a terrible terrible api which isn't tested 13:41:03 does our default policy allow folks other than cinder to call it? I guess it does? 13:41:03 i know gmann was working on a test for swap volume at one point and ran into an issue but i can't remember what it was now 13:41:14 we changed the default policy to be admin-only back in i think mitaka 13:41:22 i thought gmann was running into policy issues 13:41:28 yeah, I didn't think calling it directly was meant to be a thing 13:41:32 mriedem: given the TZ delay, perhaps we stick it out on the mailing list? 13:41:34 johnthetubaguy: but it is 13:41:40 sdague: gmann isn't here, he couldn't make it 13:41:41 johnthetubaguy: nova volume-update :) 13:41:55 maybe i can just dig up his change in tempest 13:41:59 mriedem: yeah, that was a discovery for me 13:42:05 #action mriedem to follow up with gmann about testing swap-volume in tempest 13:42:27 the problem might have been he was using a non-admin to call nova, but then nova calls an admin api in cinder 13:42:29 and it blow up 13:42:30 *blew 13:42:39 ah 13:42:47 that should be fixed if you just use an admin throughout 13:43:13 mriedem: is http://developer.openstack.org/api-ref/compute/?expanded=update-a-volume-attachment-detail the thing we're talking about? 13:43:14 it would also be totally conditional on tempest since only libvirt supports the swap-volume method 13:43:18 was there a reason disconnect one then attach another is no good? 13:43:24 sdague: yes 13:44:19 johnthetubaguy: yeh, that's a question for me, this seems a bit too magical 13:44:40 I wonder if the answer is something about preserving device ordering, but I really have no idea 13:45:13 ok, well the action is out there 13:45:18 well, a new day, a new crazy API found 13:45:19 I have one thing 13:45:27 :) 13:45:34 johnthetubaguy: yeah https://review.openstack.org/#/c/373390/ 13:45:44 i think it has something to do with the blockRebase that's done https://github.com/openstack/nova/blob/master/nova/virt/libvirt/driver.py#L1181 13:45:45 I've been pondering API capabilities a bit, and am trying to figure out the best way to flesh out the approach 13:46:00 swap-volume is really about an api flow for libvirt and certain cinder backends for migration i think 13:46:30 it's not clear to me that there is time in ocata to do it, but we probably need a pretty detailed spec (and discussions) before we move forward 13:46:37 mriedem: its live-migration for the volume backend, for non-clustered storage, as I understood it 13:46:39 so my thinking is an ocata spec 13:46:41 but I remember swap-volume works for normal-user, user can just pass a new volume, and that swap works. 13:46:43 sdague: +1 for moving forward on that 13:47:07 sdague: I think my problem is matching capabilities with the actual REST calls 13:47:14 and we can figure out if there is ground work that falls out 13:47:40 I think there is a task to go back and add docs into our policy rules? maybe? 13:48:02 there is a task to build the default policy into the nova devref 13:48:05 like we have for the sample config 13:48:09 mriedem: +1 13:48:31 the keystone guys showed up yesterday asking about putting comments in the policy.json with instructions on how to generate it, 13:48:43 i'd prefer to just have a readme like we do for the nova.conf.sample that has those instructions 13:48:49 so we're consistent 13:48:55 mriedem: yeh, given json doesn't support comments, I agree 13:48:58 mriedem: +1 13:49:20 maybe there is enough of "policy tidy ups" to be done 13:49:47 sdague: I don't remember spotting anything around that in the operator feedback, I guess its a release or two early for that? 13:50:07 johnthetubaguy: on policy, they liked our new approach, they were just concerned about docs 13:50:09 it's in there 13:50:14 sdague: might want to keep claudiub in the loop on any policy discoverability / capability stuff since i think he's also looking at that 13:50:21 sdague: right, thats fair 13:50:33 o/ 13:50:38 i'll follow up on the readme for generating the default policy if ayoung didn't push that yet 13:50:39 mriedem: sure, well, a spec will be a reasonable place to keep all that public and iterable 13:50:47 ah, so at the midcycle, we said we would try add two things for policy discovery 13:51:00 I guess, we need a spec up with that, so we can discuss something concrete 13:51:53 #action sdague to start in on a capabilities spec 13:51:59 sorry, a bit out of the loop here. so, I have a WIP patch for matching policy rules and capabilities and different api endpoints. 13:52:16 also trying to take into account the given api microversion 13:53:17 claudiub: where is that patch? 13:53:19 it's a bit slow, but i have something that outputs what the nova-api docs have in about 75-80% 13:54:21 https://review.openstack.org/#/c/280539/ 13:54:40 still have to upload what i have in my work env 13:55:07 i've changed things since then 13:55:14 ok, that's probably a bit different granularity than I was thinking 13:55:19 4 mins left 13:56:03 i was planning to include the post method, api endpoint and request body in the output 13:56:19 api method * 13:56:24 alex_xu: Hi, https://blueprints.launchpad.net/nova/+spec/display-host-hypervisor-numa-topology can I submit the spec for this BP for ocata-1 13:56:44 or more like, the request body schema 13:56:52 diga_: yea, sure, i think it is time to submit spec 13:57:02 alex_xu: Sure, thx! 13:57:31 diga_: np 13:58:06 :) 13:58:18 ok, 2 mins left 13:58:43 so let us back to the nova channel? 13:59:11 sounds good 13:59:20 ok, thanks all! 13:59:21 #endmeeting