12:00:03 #startmeeting nova api 12:00:04 Meeting started Tue Mar 8 12:00:03 2016 UTC and is due to finish in 60 minutes. The chair is alex_xu. Information about MeetBot at http://wiki.debian.org/MeetBot. 12:00:05 Useful Commands: #action #agreed #help #info #idea #link #topic #startvote. 12:00:07 The meeting name has been set to 'nova_api' 12:00:13 who is here today? 12:00:24 o/ 12:00:35 o/ 12:00:39 hi 12:00:45 * johnthetubaguy lurking 12:01:33 o/ 12:01:36 sorry, I didn't cleanup the agenda 12:01:50 I think we can go to the open direct today 12:01:54 #topic open 12:02:17 #link https://bugs.launchpad.net/nova/+bug/1554440 12:02:17 Launchpad bug 1554440 in OpenStack Compute (nova) "Show volume attachment exception does not looks good if server is in shelved_offloaded state" [Undecided,New] - Assigned to Ghanshyam Mann (ghanshyammann) 12:02:22 gmann_: I think this is yours 12:02:25 ok 12:02:46 alex_xu: yea actually while implementing microversion tests 2.20 in tempest i saw this issue 12:03:13 gmann_: so good we have microversion test in tempest now 12:03:19 I wanted to confirm 2 thing- 1. 'device' in volume attachments can be null any time? 12:03:36 alex_xu: sdague yea i updated patch https://review.openstack.org/#/c/258391/24 12:03:56 so device has lots of issues, as its only really a guess 12:03:57 gmann_: I'll put that on my review list 12:04:14 sdague: Thanks 12:04:28 sdague: also bases patches, hanging long 12:04:39 those are for putting all microversion stuff in /lib 12:05:03 sdague: would you look at this ? https://review.openstack.org/#/c/289822/ 12:05:15 sdague: alex_xu any time mountppoint can be null - https://github.com/openstack/nova/blob/master/nova/api/openstack/compute/volumes.py#L223 12:05:44 allen_gao: would you mind wait a minutes, let's finish gmann_'s agenda first 12:05:47 sdague: alex_xu because in tempest, we expect 'device' to be always present in response 12:06:11 alex_xu: sorry 12:06:11 so honestly, I think both are wrong 12:06:13 kinda 12:06:17 sdague: I saw those for shelved offload case 12:06:26 allen_gao: no worries :) 12:06:32 the API should really have some sort of "empty" value 12:06:38 but that is a new microversion 12:06:51 so the tempest test should make that optional, in the mean time 12:06:57 ... I think 12:07:13 johnthetubaguy: but other than shelved offload state, can it be for any other state? 12:07:46 for v2.1 tempest expect it as mandatory and non none 12:07:48 hi, I am here. as of compute API docs 12:08:04 while doing for v2.20 testing i got doubt on those 12:08:19 gmann_: I suspect also during the attach, but I am not sure 12:08:22 from nova code those can be absent or None but do not know scenario 12:09:35 #link https://github.com/openstack/tempest/blob/master/tempest/lib/api_schema/response/compute/v2_1/servers.py#L270-L275 12:09:52 seems like device is optional: https://github.com/openstack/nova/blob/master/nova/compute/api.py#L3132 12:10:32 yeah, device is optional in the API 12:10:32 http://developer.openstack.org/api-ref-compute-v2.1.html#attachVolume 12:10:39 when you do attach 12:11:09 johnthetubaguy: yea and for virt nova does not honor eve if that is passed 12:11:32 johnthetubaguy: but will it be optional in response too, i think while booting instance it gets mounted 12:11:41 yeah, that 12:12:25 so I think its optional in the API, how we display that, is probably bad 12:12:35 not sure if that helps 12:12:50 humm 12:13:25 sdague: johnthetubaguy in that case, we might need to make this optional in tempest schema validation too 12:13:28 sounds like the tempest tests are wrong here, and the API is badly designed, as it shouldn't really hide the device like that 12:13:42 yea 12:13:46 yep, I think thats what I am saying here, needs to be optional 12:14:06 johnthetubaguy: ok, Thanks i will change that 12:14:06 gmann_: sure, the schemas in tempest were best effort by oomichi, they weren't official from nova 12:14:15 they very well could be wrong 12:14:22 sdague: yea 12:14:34 sdague: johnthetubaguy alex_xu second issue is - https://bugs.launchpad.net/nova/+bug/1554440 12:14:34 Launchpad bug 1554440 in OpenStack Compute (nova) "Show volume attachment exception does not looks good if server is in shelved_offloaded state" [High,Triaged] - Assigned to Ghanshyam Mann (ghanshyammann) 12:14:40 not sure though bug or ok 12:15:15 for shelved offload state, mount point will always be none and show attachment trow exception Not Found 12:15:32 #link https://github.com/openstack/nova/blob/master/nova/api/openstack/compute/volumes.py#L289 12:15:52 I think we should return the attachment 12:15:57 at least for shelved offload it should just ignore mount point and show response 12:16:13 logically the volume is "attached", just the device is missing as its not yet been physically attached 12:16:35 its bad to have list inconsistent 12:16:55 so let return None for no mount point? 12:16:55 yea, on unselve that will be attached 12:17:17 alex_xu: yea None or just not add like list 12:17:20 you want it to appear, to check your API call to attach "happened" I think 12:17:41 yeah, it should match the list operation, for now, I think 12:17:51 +1 12:18:01 this feels like a bug fix, rather than a microversion, but it feels a little boarderline 12:18:18 I'm ok without microversion 12:18:24 johnthetubaguy: +1 for as bug fix 12:18:55 and that fix for all version i mean not just for v2.20 right? 12:19:25 i mean like list, if no mount point then just do not include 'Device' 12:19:35 I'm also think of only fix for v2.20, that sounds like more safe, if we think this is borderline 12:20:22 include device? I thought we were talking about stopping the 404? 12:20:46 ah, sorry, missread I think 12:20:58 johnthetubaguy: yea, stop the 404 in 2.20 12:21:03 johnthetubaguy: not include if None same as list 12:21:20 alex_xu: but for older version also it is bit inconsistent 12:21:39 it is 404 -> 200, should not be issue 12:22:26 that sounds reasonable to me, easier once we have the change up, and think through it 12:23:03 johnthetubaguy: you mean fix it in all versions? 12:23:04 johnthetubaguy: sounds good. I will put patch up early tomorrow. then we can discuss more 12:24:38 possibly fix in all versions, I think its easier to get the code up so we can see the impact 12:24:52 johnthetubaguy: ok, cool 12:24:58 so let's move on 12:25:03 yea 12:25:17 allen_gao: I think your problem resolved, sdague already +2 your patch 12:26:11 tojuvone: your turn 12:26:26 #link https://bugs.launchpad.net/openstack-api-site/+bug/1554052 12:26:26 Launchpad bug 1554052 in openstack-api-site "os-services missing from compute API v2.1" [Medium,Confirmed] - Assigned to Tomi Juvonen (tomi-juvonen-q) 12:27:13 So, os-services missing and also was wondering how it is with microversions. Should those api changes also be there? 12:27:39 so right now, that doc is only documenting v2.1 (the base version), I think 12:27:39 tojuvone: sorry, we don't support microversion in the api-site yet 12:27:50 yeah, what alex_xu said 12:28:07 yea, I think we try to figure out in newton, maybe we will have swagger support 12:28:14 now, os-services, was that there before 12:28:21 ok, hope there is nothing else then missing than this os-services, I can continue to look this 12:28:22 alex_xu: we really, really have to fix that next cycle 12:28:46 tojuvone: I though we added a load back in there, did this get dropped somehow? 12:28:52 johnthetubaguy: yea, otherwise we got another big gap between doc and api 12:28:52 thought^ 12:29:22 yea, for now, I think we just need load it back 12:29:49 I found some work from jichenjc, maybe I can contact him (where I think this was removed) 12:30:08 yea, may be misplaced during some updates :) 12:30:40 ok, well I look it and good to know the microversion stuff 12:30:43 I think annegentle pinged my about some removals 12:30:45 tojuvone: yea, jichen help a lot of on that 12:30:46 tojuvone:I am here 12:30:59 we should really make sure there are no removals vs v2.0 12:31:19 I did go back a few months back and double check everything, and added a few back in 12:31:25 seems we somehow lost some 12:31:39 tojuvone: I didn't remove service related , as far as I remember .. 12:32:30 alex_xu: yea, thank you ;) 12:32:30 so I seem some stuff in here: 12:32:31 https://github.com/openstack/api-site/commit/2daa7d811b59020c0c5e16137a1f65ec5fa26b73 12:32:57 this one totally makes sense: https://github.com/openstack/api-site/commit/5feaeccde67655db32e64ab408b2a108fbfe5824 12:33:05 so I guess its where we had added microversion stuff in? 12:33:18 those removals seem correct 12:33:40 johnthetubaguy: yes, that is microversion 12:33:47 oops, yes, that's made by me 12:33:52 sorry, I forgot this 12:34:04 that won't remove all the os-service doc I guess? 12:34:05 jichen: no worries, you have been very busy :) 12:34:25 alex_xu: it looks like the existing things are still there, but I am not 100% sure 12:34:25 but then there was change on ch_compute-v2.1.xml 12:34:32 ah... 12:34:36 so that sounds bad 12:35:09 yes, I think os-services-v2.1.wadl is good 12:35:20 emm...ok 12:35:29 anyway let's add os-services back 12:35:35 yea 12:35:39 then some api sample was missing after I tried to fix ch_compute-v2.1.xml 12:35:51 yep, no need to go further here ;) 12:35:52 tojuvone: if you still have trouble, free to ping me 12:36:12 so I think we can move on 12:36:17 * gmann_ curious about api sample missing 12:36:43 Kevin_Zheng: you have think want to discuss right? 12:36:49 yes 12:36:59 I want to raise a topic 12:37:03 * alex_xu is typing slow by unstable network 12:37:11 http://developer.openstack.org/api-ref-compute-v2.1.html#createServer 12:37:19 tojuvone: alex_xu: sounds like we all agree on the direction for the docs, so thats the main bits, I guess 12:37:31 johnthetubaguy: yup 12:37:39 johnthetubaguy: yep 12:37:47 here, we clarified twice about the length limit of injected file content 12:38:02 The maximum limit refers to the number of bytes in the decoded data and not to the number of characters in the encoded data. 12:38:27 and The file path and contents, text only, to inject into the server at launch. The maximum size of the file path data is 255 bytes. The maximum limit is The number of allowed bytes in the decoded, rather than encoded, data. 12:38:46 the second one is in the chart of create instance parameters 12:39:03 but in the code: http://git.openstack.org/cgit/openstack/nova/tree/nova/compute/api.py#n270 12:39:19 we are actually checking the base64 encoded data directly 12:39:43 data length will grow after base64 encode 12:40:09 for example 7680 bytes will grow to 10240 12:40:44 user will have to determain the length of data after encode 12:40:51 and it is inconstant 12:41:00 What should we do? 12:41:11 I think the max has to be on what is input to the API, I think, isn't that correct here? 12:41:14 sorry inconsistant 12:41:55 yes it is, but the doc writes it should be decoded data 12:42:25 and it will be harder for user to determain the data length after encode 12:43:18 so what does the user pass to the API, its the encoded data, I thought? 12:43:22 or is that wrong? 12:43:35 yes user should pass encoded data 12:43:38 yes, user padd to the API with encoded data 12:43:45 s/padd/pass... 12:43:53 but for example, using novaclient, 12:44:05 user pass a file to client 12:44:12 client will encode the content 12:44:33 yes, agreed 12:44:40 user will not know the length after encode 12:44:40 I guess Kevin_Zheng's point is from end-user which use UI or CLI 12:44:55 its the rest API point of view that should be taken here 12:45:08 although I am wondering how this has been "wrong" for so long 12:45:51 I think it is not user friendly to let them calculate the encoded length 12:46:09 so, the question here is what does the API actually do today 12:46:11 as show the file size will be pretty simple 12:46:27 now, we might want to change that, but that is a breaking API change 12:46:33 it checkes the content directly 12:46:53 johnthetubaguy: agree 12:47:06 yes, as the current allowed size is smaller than the actual limit 12:47:33 the current existed users will not be affected 12:48:05 no, if user talk with two clouds with fix or without fix, this is breaking without microversion 12:48:15 right 12:48:32 yea, interoperability can be issue 12:48:37 well, actually, its a bit more odd 12:48:43 so, should we fix this? 12:48:45 you need to list your quotas to work out what is allowed 12:48:55 Kevin_Zheng: we should fix the docs, so they are correct, for sure 12:48:57 adding microversion 12:49:16 so we fix doc, not the code? 12:49:27 step 1: fix docs 12:49:28 but it will be less user friendly 12:49:48 step 2: decide if we want to change newer microversions to be more friendly 12:49:57 noting the old behaviour can't chnage 12:49:57 +1 12:50:26 so change the doc to encoded data? 12:50:29 we can have a newton spec to discuss this 12:50:42 Kevin_Zheng: make sure the docs match the current/existing behaviour, yes 12:50:48 OK, I will do that 12:50:55 we should really be sure to add some tests around this 12:51:11 Hmm 12:51:12 I do worry if we changed this behaviour by accident at some point 12:51:37 yes 12:51:55 Kevin_Zheng: is this ok for you? 12:52:06 yes, I will do it 12:52:12 Kevin_Zheng: cool, thanks 12:52:42 Another question, can we add the support for "locked" filter when list servers? 12:53:03 currently we can only got the information using show API 12:53:23 it will take forever to check all instances 12:53:42 Kevin_Zheng: sounds ok, but I think we can decided that by spec 12:53:55 Hm, sure 12:54:01 don't you get that with the show details api? 12:54:19 Kevin_Zheng: show detail shows that in v2.9 12:54:27 I am wondering why we need it int the regular list 12:54:41 gmann_: ah... 12:54:41 I will check that 12:54:59 yeah, it feels like being in the detail list is the correct thing for locked 12:55:01 i feel list should not show all 12:55:17 I mean we add a filter 12:55:19 johnthetubaguy: yea it is in show and detail list both 12:55:28 to filter out all the locked instances 12:55:32 gmann_: yeah, that seems correct 12:55:36 like deleted 12:55:53 I will check that 12:56:10 Kevin_Zheng: a filter seems OK, its worth a spec to add that in a microversion 12:56:16 cannot that be done with regex, not sure though how exact that will be 12:56:52 johnthetubaguy: hm, I will do that 12:56:58 Thanks all 12:57:01 emm...sorry guys, 4 mins left. actually I want to talk about meeting time change 12:57:26 just oomichi can't make this meeting, due to the meeting is 4:00 am for him 12:57:37 alex_xu: ohh 12:58:03 it does feel like we should alternate meeting times 12:58:04 so is there any propose for the time, I check the date, I founds really hard find one to propose 12:58:13 maybe its worth a quick doodle poll, or similar? 12:58:18 johnthetubaguy: emm...that also good idea 12:58:22 doodle++ 12:58:23 yea 12:58:45 johnthetubaguy: yea, just found really hard find out a initial propose time :) 12:58:45 maybe pick four times (possibly just think about mirroring the nova meeting times on a different day) 12:59:23 ok, let me try again, I will take care of this. 12:59:30 alex_xu: if it helps its 1pm for me right now 12:59:52 alex_xu: I can try help with ideas, ping me if I can help 13:00:14 johnthetubaguy: not sure it is ok for gmann_ 13:00:18 johnthetubaguy: thanks :) 13:00:24 soorry, it's time to close the meeting 13:00:26 alex_xu: need to check JST 13:00:50 anyway, thanks all! 13:00:52 #endmeeting