16:00:01 #startmeeting api wg 16:00:01 Meeting started Thu Feb 26 16:00:01 2015 UTC and is due to finish in 60 minutes. The chair is sigmavirus24. Information about MeetBot at http://wiki.debian.org/MeetBot. 16:00:02 Useful Commands: #action #agreed #help #info #idea #link #topic #startvote. 16:00:03 Api-wg ? 16:00:05 The meeting name has been set to 'api_wg' 16:00:08 gilliard_: :D 16:00:13 Ah, yes. Hello. 16:00:24 Hello everyone! 16:00:28 o/ 16:00:29 #topic agenda 16:00:30 yo/ 16:00:37 #link https://wiki.openstack.org/wiki/Meetings/API-WG#Agenda 16:00:50 o/ 16:00:57 hello 16:01:09 hi 16:01:33 Moving along 16:01:41 #topic versioning 16:02:12 I think that's etoews' topic, but I wonder if cyeoh is around to talk about it too (seeing as how I think this is related to Nova's versioning) 16:02:37 there is no proposed guideline on this yet, correct? 16:02:42 I think it's 4am in Australia 16:03:05 gilliard_: You mean people don't stay up that late for openstack? =P 16:03:14 Slackers 16:03:21 * sigmavirus24 doesn't know everyone's tz 16:03:27 miguelgrinberg: I don't believe there's one, no 16:04:15 no, I don't see anything in https://review.openstack.org/#/q/status:open+project:openstack/api-wg,n,z 16:04:22 Should we circle back to this if etoews shows up? 16:04:46 * sigmavirus24 is fairly certain it has to do with microversions in Nova but doesn't know what etoews wanted to say 16:04:54 No dissent so, moving on 16:04:55 #topic previous meeting action items 16:05:01 #link http://eavesdrop.openstack.org/meetings/api_wg/2015/api_wg.2015-02-12-16.00.log.html 16:05:08 #link http://eavesdrop.openstack.org/meetings/api_wg/2015/api_wg.2015-02-19-00.00.html 16:05:27 (Since the last meeting was 90% glance, there are action items from the last two meetings there) 16:05:36 no action items, wow 16:05:53 I had an action to get more input on https://review.openstack.org/#/c/147684/ 16:06:12 However, I was hoping to get more consunsus from those in this WG before asking others 16:06:14 kaufer: you got cyeoh's input 16:06:18 ;) 16:06:30 Specifically jaypipes 16:06:42 And you sigmavirus24 :) 16:06:46 Jay isn't around 16:06:51 Uhoh, what'd I do now? =P 16:07:40 I think it's nice and simple, +1 16:08:10 I haven't read it in a while 16:08:19 * sigmavirus24 will read it after the meeting 16:08:24 I'll send out a note to the ML and then start PM'ing folks on this one 16:08:31 Thanks sigmavirus24 16:08:56 kaufer: sounds good 16:09:03 Other action items people want to update? 16:09:24 #action kaufer to gather more API-WG consensus on https://review.openstack.org/#/c/147684/5 before bringing it to the ML 16:09:54 Onwards then 16:09:58 #topic guidelines 16:10:05 #link https://review.openstack.org/#/q/status:open+project:openstack/api-wg,n,z 16:10:12 #link https://review.openstack.org/#/q/status:open+project:openstack/api-wg,n,z 16:10:24 (in case meetingbot decides to not parse it without stripping the whitespace) 16:10:44 https://review.openstack.org/#/c/155911/ seems to have consensus 16:11:20 https://review.openstack.org/#/c/141229/ needs more input because there's a serious discussion of how to accommodate Swift 16:11:40 (and that won't be easy) 16:12:24 Well it may not be that we need to accommodate Swift, any more than Swift needs to realize why their current design is ill-considered and why they're currently breaking RFCs and should strive to be incompliance with them 16:12:28 s/incompliance/in compliance/ 16:13:03 sure, or they can opt to not follow the guideline. Nothing will die of it. 16:13:22 sigmavirus24: but tell us what you really think ;) 16:13:27 they have their reasons, I can understand that 16:13:35 elmiko: heh 16:13:53 we seem to keep running in to the notion that these guidelines are binding and retroactive 16:14:12 agreed with miguelgrinberg at some level, if swift chooses not to follow the guideline then that is their perogative 16:14:38 but I think it is a too contrived use case to have influence on this doc 16:15:31 Also if I recall correctly, they're arguing that this would affect object creation for them too, which I don't see how that is the case as this purely affects endpoints for metadata only 16:15:39 Not for creation with metadata 16:15:55 But yes, this is another case of people not understanding that these aren't retroactive guidelines 16:15:59 yes, this is all about their endpoints, which are too vaguely defined 16:16:07 there is ambiguity 16:16:23 They're also designed around an API design that iirc Amazon no longer uses 16:16:24 so a /metadata can be metadata or can be a swift object called metadata 16:16:46 I have ideas on how to disambiguate, but not sure they want to listen 16:17:08 So discussion should be further focused on that review 16:17:19 Because it appears John and Samuel aren't here 16:17:33 We should probably also involve the ML 16:17:53 okay, I'll take the action to ask for feedback on the ML 16:18:16 #action miguelgrinberg to get ML feedback on https://review.openstack.org/#/c/141229/ 16:18:30 (You can't say I volunteered you for that one miguelgrinberg) 16:18:41 I did it to myself :) 16:18:54 We also seem to have consensus on https://review.openstack.org/#/c/158179/ 16:19:18 But that's less than a week old so we have to wait for more discussion per our own guidelines around merging guidelines 16:19:21 ;) 16:19:33 that one seemed must less controversial too 16:19:38 *much 16:19:44 apologies for lateness, had another meeting 16:19:44 elmiko: right 16:19:49 cdent: No worries. 16:21:38 cdent: agenda is https://wiki.openstack.org/wiki/Meetings/API-WG 16:21:44 We're discussing guidelines 16:21:47 I'm also going to ask for ML feedback on the tagging doc https://review.openstack.org/#/c/155620/ 16:22:12 #action miguelgrinberg to bring tagging guideline to the ML https://review.openstack.org/#/c/155620/ 16:22:18 Happy that Heat is implementing this spec :) 16:22:51 miguelgrinberg: Any thoughts on if we need to revisit the repeated query string parameter vs. comma separated that came back up in the tagging guideline? 16:23:09 miguelgrinberg: I thougt that we had closed that issue but it crept back in in that review 16:23:18 kaufer: don't know. I thought we beat that horse to death, but seems we didn't 16:23:20 on the tagging thing: In case it's not clear from the chest inflating going on in the comments there: I'm fine with the spec as is, but we _could_ use tag=foo&tag=bar if we really wanted to 16:23:59 this is also similar to a question i have about filtering 16:24:12 I think the reason it came back into play is that there is a large discussion still unresolved about the extent to which we want to be driving global improvement, as opposed to local okayness 16:24:32 cdent: you could, but it would not be in agreement with the current rev of the guideline 16:24:36 cdent: there's a similar design for sorting that's already been approved and is already being implemented 16:24:50 cdent: conflating what the WG wants and what the community can do? 16:25:19 cdent: the WG can write all the guidelines it wants, the community can do whatever it pleases since we have no real authority 16:25:27 my view on this is that both options are valid, we have to pick one. We picked single args for sorting, so I think we should stay with single args for everything else. 16:25:42 miguelgrinberg: that's reasonable enough 16:25:44 miguelgrinberg: +1 16:26:28 miguelgrinberg: just to be clear, that would be the "tag=foo&tag=bar" foramt? 16:26:31 elmiko: so that would apply to filtering when we get to it 16:26:48 elmiko: no, the other one: "tags=foo,bar" 16:27:19 miguelgrinberg: ok, how would filtering look given that approach? 16:27:53 I haven't look at any implementations of filtering, do you have an example? 16:28:09 https://review.openstack.org/#/c/157563/ 16:28:16 that's a spec we're working through in sahara currently 16:28:25 So this has drifted from discussion of the current specs 16:28:29 Should we save this for the end? 16:28:35 i'm cool with that 16:28:39 yeah, sure 16:28:42 #topic APIImpact 16:28:49 #link https://review.openstack.org/#/q/status:open+AND+(message:ApiImpact+OR+message:APIImpact),n,z 16:28:58 OpenStack has a mess of different filtering models already. I can get a summary that was cooked up in the py SDK project 16:29:07 There should be a cinder review there that DuncanT was supposed to address here 16:29:13 stevelle: that would be awesome! 16:29:32 stevelle: https://etherpad.openstack.org/p/find_filters 16:29:37 Oh wait, yuriy_n17 has it at the end of the discussion 16:29:39 stevelle: +1 16:29:46 What am I supposed to be addressing, sorry? 16:29:56 DuncanT: https://review.openstack.org/#/c/156552/ 16:30:06 briancurtin: thanks 16:30:15 briancurtin: thanks 16:30:15 You and yuriy_n17 were to bring that up during this part of the meeting :) 16:31:04 Ah, ok. So we discovered today that cinder always uses UTC, except for a couple of migrations 16:31:07 (I'll save my comments till the end) 16:31:16 sigmavirus24: yes. we want to decide to timezone should be shown in API 16:31:47 as DuncanT mentioned, it isn't big issue for cinder now 16:32:21 I also don't see a blueprint for this in cinder (which would seem to be a good idea) 16:32:42 sigmavirus24: we've got bur reported for it 16:33:06 That would also make it easier for us to discuss because it would more succinctly describe the change being made there 16:33:23 does this topic deserve a guideline doc? I thought it is pretty standard to use UTC on any public representations 16:33:50 sigmavirus24: do we have any guidelines for it? 16:34:12 e0ne: no there aren't. I mentioned that yesterday during cinder's meeting 16:34:17 sigmavirus24: afaik, nova shows timezone in api, but i could be wrong 16:34:37 My personal taste is to include the timezone information using ISO8601 but I understand that will break current clients 16:34:55 Also any guideline we propose is for future versions of the API, not necessarily for additions to existing versions 16:35:05 if all openstack projects will use utc time in api - it won't be issue at all 16:35:12 ++ 16:35:41 e0ne: agreed. That's basically a de facto best practice for any and all APIs 16:36:07 sigmavirus24: agree. but we must have to document it 16:36:39 e0ne: no doubt. Would you like to write that guideline? 16:36:48 because time to time will got new users and/or developers which rise this question again 16:37:39 sigmavirus24: ok. i'll do it with yuriy_n17. he was an initiator of this topic:) 16:38:30 e0ne: thanks 16:38:44 #action e0ne and yuriy_n17 to write a guideline about datetime representation in APIs 16:38:58 :) 16:38:58 Any other APIImpact reviews people want to highlight? 16:39:00 should be pretty non-controversial 16:39:04 stevelle: I agree 16:39:46 https://review.openstack.org/#/c/157563/ 16:39:59 so, we are talking about filtering in our review 16:40:05 and were curious about the most proper methods 16:40:39 the path we are investigating is something like "?filterkey=value&filterkey2=value" 16:41:02 elmiko: I think that style makes it hard to use negative filtering 16:41:03 or "filterkey=value1&filterkey=value2" 16:41:18 miguelgrinberg: could you elaborate? 16:41:37 how do you specify that you want anything but a given value for a field? 16:41:40 miguelgrinberg: excluding keys with certain values 16:41:47 we hadn't considered that option 16:41:54 we were only looking at positive filtering 16:41:57 say you like all servers that are not named "foo" 16:42:17 right, i'm curious what would be a better approach? 16:42:18 ...or all jobs that do not have a tag "foo" 16:42:53 miguelgrinberg: Do you know of any projects that implement negative filtering like that? 16:42:56 I haven't given a lot of thought, but one possibility is to define a simple query language, and just stuff an expression in a "q" argument 16:43:15 kaufer: not in openstack afaik 16:43:33 I've done things like: select=tag:!foo 16:43:49 cdent: yeah, I think something like that is what miguelgrinberg is proposing 16:44:18 It wouldn't hurt to see if choosing a subset of something people are familiar with (e.g., elasticsearch's query language) would be a good idea *If we need it* 16:44:29 and then there is the issue of specifying ORs and ANDs 16:44:32 in this case, we mainly need to prune results. i'd really love to look at something i could suggest to the team regarding a query language. 16:45:15 also, there are some projects (ie, nova) where one filter key is filtering using an exact match and another is used using a regular expression 16:45:15 the gerrit search is an example of a query language, though I'm not sure it has negative filtering 16:45:52 it would be nice if we had a uniform mechanism to define if a filter is an exact match, a regex, a negative filter, etc. 16:45:55 miguelgrinberg: it does 16:45:58 miguelgrinberg: -owner:me 16:46:04 or something like that 16:46:19 it's very similar to elasticsearch's ql 16:46:26 sigmavirus24: nice, so that's a good model, though it may be too complex for projects that want a simple search 16:46:50 maybe a guideline should include simple searches as well 16:46:52 right 16:46:55 would there be an issue with something like "?filterkey1=value&filterkey1=-value2" 16:46:58 ? 16:47:10 elmiko: what about val-ue2? 16:47:11 there's a lot of overlap between searching, filtering, sorting and limiting 16:47:22 but they are also distinct 16:47:24 I would assume it could be done intelligently enough but it might get tricky 16:47:25 elmiko: I don't remember who didn't like me proposing the "-" as negative filtering 16:47:43 miguelgrinberg: that was on sort though and was kind of an awkward way of defining asc/desc though 16:47:45 to be fair 16:47:50 hmm, i could see some corner case issues 16:47:55 miguelgrinberg: I think cdent and I were opposed 16:47:55 also, on the topic of filtering ... anyone know if the valid filters for a given project are discoverable? 16:48:13 I do not recall that senator. 16:48:15 kaufer: if the project is properly implementing JSON Home it should be 16:48:27 kaufer: also a schema for an endpoint should tell you 16:48:37 I don't expect a project to have globally defined filters for all endpoints 16:48:42 kaufer: the filters should be the fields in the representation ideally, no need to call them out 16:49:00 so, to align with how we did sort, maybe something like "?filterkey1=value&filterkey1=value2:negative" 16:49:11 kaufer: that's not bad 16:49:21 kaufer: still no way to specify AND/OR 16:49:31 AND is implicit 16:49:37 but agree, there is no OR 16:49:54 want OR, just ask again? 16:50:03 cdent: good point 16:50:05 I think I'm leaning towards only positive filtering with filterkey=value, and if you want more then define a query language 16:50:19 cdent: costs twice as much to service that way sadly 16:50:29 yea, positive filtering is bog easy with the filterkey=value methodology 16:50:38 I wasn't supporting it, just stating the option. 16:50:53 cdent: that doesn't scale unfortunately 16:51:30 if explicit booleans are desired then a quoted query string is probably needed 16:51:49 cdent: yes, a q= style argument 16:51:53 should we attempt to come up with a standardized query language for the guidelines in addition to the default positive filtering idea? 16:51:53 you can have both: simple implict and style queries, plus complex q="some long string of stuff with OR and AND and (* )" 16:51:54 seems like there are a lot of ideas around filtering, should we start an etherpad and use that as a starting point to hash this out? 16:51:56 jinx 16:52:01 yeah 16:52:06 We're running close to the end of meeting 16:52:09 * cdent nods 16:52:15 Should we move on? 16:52:18 kaufer: +1 16:52:38 cdent: yea i like the idea of dual approach 16:52:45 Are there other API Impact topics? 16:52:49 It seems gilliard has left 16:53:12 I have a what should have been API Impact but couldn't get the commit message changed question/comment: 16:53:24 cdent: shoot 16:54:13 Given uri /foo/bar/baz is it legit for /foo/bar to return 404 or should it return _something_ (what?) to indicate that baz (and siblings) might be there. 16:54:25 this issue is coming up in: 16:54:45 https://review.openstack.org/#/c/159204/ 16:55:02 (but that's not the place where the lack of APIImpact is, as that's my commit) 16:55:11 cdent: imo you can return 404 16:55:48 certainly from a strictness standpoint 404 is correct, but from a friendliness standpoint, less so 16:56:09 if you want to return something, then you are getting into the idea of sub-resources 16:56:12 It assumes a non human client that already knows the api, rather than a human digging around for kicks and giggles. 16:56:33 so for example /resource returns a big representation, then /resource/field-name returns a subset of the big resource 16:57:21 so, in the example of /foo/bar/baz, /foo/bar would return all bazs? 16:57:25 I know people roll their eyes when I say this (I know you are sigmavirus24), but URLs should be opaque, should be discovered, so there is no obligation to have them nicely structured 16:58:06 I mostly agree with you miguelgrinberg, if discovery mechanism is present, but when it is not... 16:58:24 elmiko: that's what miguelgrinberg is saying but it may not always be true 16:58:25 when it is not, you document the valid endpoints, so still not a problem 16:58:37 I'm also not rolling my eyes at you miguelgrinberg, that's a waste without you being able to see it 16:58:42 elmiko: baz is one of the bars, /foo/bar would return all the bars 16:58:49 sigmavirus24: save it for next month :) 16:58:54 (or somethign like that) 16:59:06 ok, so the bars might include bazs, amongst other things? 16:59:28 or are bars and bazs unrelated? 17:00:00 we're almost out of time 17:00:07 #endmeeting