openstackgerrit | Hong Hui Xiao proposed openstack/dragonflow: Remove the legacy tunnel port code https://review.openstack.org/406573 | 01:12 |
---|---|---|
*** gongysh has joined #openstack-dragonflow | 01:15 | |
openstackgerrit | Merged openstack/dragonflow: add active detection app for allowed address pairs https://review.openstack.org/339975 | 02:10 |
openstackgerrit | Merged openstack/dragonflow: change security group lock based on sg_id https://review.openstack.org/413046 | 02:13 |
openstackgerrit | Merged openstack/dragonflow: Apply virtual tunnel port to l2 app https://review.openstack.org/406142 | 02:13 |
*** gongysh has quit IRC | 02:15 | |
openstackgerrit | Merged openstack/dragonflow: Apply unique_key to security group https://review.openstack.org/411167 | 02:17 |
*** gongysh has joined #openstack-dragonflow | 02:29 | |
openstackgerrit | Li Ma proposed openstack/dragonflow: Increase the number of retries for db-lock https://review.openstack.org/413352 | 02:36 |
openstackgerrit | Hong Hui Xiao proposed openstack/dragonflow: Remove the legacy tunnel port code https://review.openstack.org/406573 | 03:23 |
openstackgerrit | Hong Hui Xiao proposed openstack/dragonflow: Dynamic register nb db models https://review.openstack.org/410645 | 03:31 |
*** yamamot__ has joined #openstack-dragonflow | 03:40 | |
openstackgerrit | Li Ma proposed openstack/dragonflow: Cassandra Support https://review.openstack.org/396997 | 05:06 |
openstackgerrit | jingting proposed openstack/dragonflow: Support VM live migration https://review.openstack.org/394759 | 05:07 |
openstackgerrit | jingting proposed openstack/dragonflow: Support VM live migration https://review.openstack.org/394759 | 05:10 |
openstackgerrit | Li Ma proposed openstack/dragonflow: Temp workaround: fix zeromq binding error https://review.openstack.org/413419 | 05:49 |
*** irenab_ has joined #openstack-dragonflow | 06:21 | |
*** irenab has quit IRC | 06:23 | |
*** irenab_ is now known as irenab | 06:23 | |
openstackgerrit | jingting proposed openstack/dragonflow: Support VM live migration https://review.openstack.org/394759 | 06:42 |
*** oanson has joined #openstack-dragonflow | 06:57 | |
*** rajivk has quit IRC | 07:19 | |
*** rajivk has joined #openstack-dragonflow | 07:31 | |
*** openstackgerrit has quit IRC | 07:48 | |
*** lihi has joined #openstack-dragonflow | 08:20 | |
*** dimak has joined #openstack-dragonflow | 08:23 | |
*** dimak has quit IRC | 08:39 | |
*** dimak has joined #openstack-dragonflow | 08:41 | |
*** dimak has quit IRC | 08:41 | |
*** dimak has joined #openstack-dragonflow | 08:42 | |
*** dimak has quit IRC | 08:45 | |
*** dimak has joined #openstack-dragonflow | 08:46 | |
*** dimak has quit IRC | 08:46 | |
*** lihi has quit IRC | 08:52 | |
*** saggi has joined #openstack-dragonflow | 08:53 | |
*** dimak has joined #openstack-dragonflow | 08:54 | |
*** lihi- has joined #openstack-dragonflow | 08:58 | |
*** lihi has joined #openstack-dragonflow | 08:58 | |
*** oanson_ has joined #openstack-dragonflow | 09:04 | |
*** oanson has quit IRC | 09:05 | |
*** oanson_ is now known as oanson | 09:05 | |
*** yuval has joined #openstack-dragonflow | 09:07 | |
*** hshan has joined #openstack-dragonflow | 09:10 | |
*** lihi has quit IRC | 09:13 | |
*** lihi- is now known as lihi | 09:15 | |
*** zenoway has joined #openstack-dragonflow | 09:15 | |
dimak | oanson, | 09:15 |
oanson | dimak, | 09:15 |
dimak | and about the nb refactor bp | 09:16 |
oanson | Yes | 09:16 |
dimak | I was writing some model construction code | 09:16 |
oanson | Cool | 09:16 |
dimak | I'd like to merge nested and regular fields | 09:16 |
dimak | I think its too confusing to have both | 09:16 |
oanson | What did you have in mind? | 09:16 |
oanson | I wasn't able to think of an elegant solution for that | 09:17 |
oanson | What did you have in mind? | 09:17 |
dimak | have just one list of fields, and maybe for each field add the ability to specify whether its nested with a type or nor | 09:17 |
dimak | not * | 09:17 |
dimak | btw | 09:17 |
dimak | even if its nested (collection?) it shouldn't always have a type | 09:17 |
dimak | e.g. a list of IDs | 09:17 |
dimak | are just strings | 09:18 |
oanson | Something like: fields = [Field('field1'), Field('field2', nested=True), ...] ? | 09:18 |
dimak | yes, kind of reminds sqlalchemy | 09:18 |
oanson | Or: fields = ['field1', Field('field2', nested=True), ...] ? | 09:18 |
dimak | with type= for passing a type | 09:18 |
oanson | In sqlalchemy its: field1 = Field(...). field2 = Reference(...), ... | 09:19 |
dimak | I like the second version a bit less, mixing types ruins it for me :( | 09:19 |
oanson | I get that. | 09:19 |
oanson | But it will be the most common case | 09:19 |
oanson | And this way it will be easiest to read and write | 09:20 |
dimak | xiaohhui hujie irenab lihi nick-ma_ Have any ideas? | 09:20 |
oanson | (In the common case) | 09:20 |
dimak | oanson, I agree about the common case | 09:20 |
oanson | hshan, if you're here too | 09:20 |
irenab | dimak: let me get though the discussion | 09:20 |
dimak | irenab, we're talking about the model definition code in the nb api refactor | 09:21 |
*** hshan has quit IRC | 09:22 | |
oanson | I've started an etherpad to throw examples: https://etherpad.openstack.org/p/DF-model-definition-examples | 09:22 |
irenab | dimak: what is the dilema? | 09:22 |
*** hshan has joined #openstack-dragonflow | 09:23 | |
dimak | irenab, In the current version of the spec we define 2 attributes, fiels and nested fields | 09:23 |
irenab | dimak: nested filds, i.e. pointer to other table? | 09:24 |
oanson | Yes | 09:24 |
dimak | Not really | 09:24 |
dimak | like subnets, which reside inside lswitch | 09:24 |
dimak | but have their own model class | 09:24 |
irenab | dimak: model class == table, right? | 09:25 |
*** hshan has quit IRC | 09:25 | |
oanson | Not necessarily | 09:25 |
oanson | subnets and router ports don't have their own tables | 09:26 |
oanson | But they will be nested fields, since they have their own models | 09:26 |
dimak | they are serialized into their parent tables | 09:26 |
irenab | ok | 09:26 |
irenab | so nested, means just another model | 09:26 |
oanson | We may want to control that too in the future | 09:27 |
oanson | e.g. if we think putting subnets in a different table will boot performance | 09:27 |
oanson | xiaohhui, you can change colour in the menu in the top right corner | 09:27 |
irenab | oanson: from the API perspective, user will be able to manage models? | 09:28 |
oanson | Yes | 09:28 |
dimak | I also don't like nested as the name for a collection | 09:28 |
oanson | i.e. client will be able to add a subnet by an 'add subner' command, not a 'modify network' command | 09:28 |
irenab | dimak: +1 | 09:28 |
dimak | Nested can mean singular just as well | 09:29 |
oanson | dimak, then it's your responsibility to come up with a better name :) | 09:29 |
dimak | All the fields are nested anyway | 09:29 |
xiaohhui | oanson, thanks and done | 09:29 |
dimak | I think plural is a better name for starters | 09:29 |
oanson | dimak, not sure I understand | 09:30 |
dimak | oanson, ? | 09:30 |
oanson | Sorry, got it. Yes, plural is better | 09:30 |
oanson | But you didn't add a regular field to your example | 09:31 |
oanson | That was one of the pain points | 09:31 |
dimak | Done | 09:33 |
oanson | dimak, I still think detecting when a field object is a string and wrapping it automatically will be better | 09:33 |
oanson | It will be easier for developers | 09:33 |
dimak | Its not a problem at all | 09:33 |
*** hshan4 has joined #openstack-dragonflow | 09:34 | |
oanson | I know theoretically it's not a problem | 09:34 |
dimak | But I like reading the uniform type list better | 09:34 |
dimak | visually | 09:34 |
dimak | Dunno | 09:34 |
oanson | xiaohhui, irenab, your thoughts on this? | 09:34 |
xiaohhui | dimak, do you mean the _F class will do the job for both normal field and nested field? | 09:35 |
xiaohhui | By using nested param to distinguish them? | 09:35 |
dimak | Yes | 09:37 |
irenab | what are the basic types? | 09:37 |
irenab | maybe if the type is not basic, it should be assumed to be other model | 09:37 |
dimak | Anything json module produces | 09:37 |
dimak | irenab, ^^ | 09:38 |
oanson | The serialisation is to strings, lists, and dicts | 09:38 |
oanson | Anything more complex will be... comple :) | 09:38 |
oanson | complex* | 09:38 |
dimak | and integers/floats/booleans | 09:38 |
dimak | its a shame json doesnt do timestamps like jaml does | 09:39 |
dimak | yaml* | 09:39 |
oanson | Then let me rephrase: The serialisation is to python native types (ints, strings, floats), lists, and dicts. | 09:39 |
irenab | ok, so seems no way to avoid this special nested/plurals flag | 09:40 |
oanson | Either that, or assume that all nested are plural | 09:41 |
dimak | I don't like the term nested | 09:41 |
irenab | nested=‘ponter to other model’ | 09:42 |
oanson | dimak, you still didn't give me an alternative | 09:42 |
irenab | dimak, oanson should we go with ‘backref’ ? | 09:43 |
oanson | technically it's a forward ref. What about just 'Reference' ? | 09:43 |
dimak | I think type is a better term than reference | 09:44 |
dimak | it doesn't have to be a model | 09:44 |
lihi | dimak +1 | 09:44 |
dimak | e.g. for timestamps we can pass datetime.datetime | 09:44 |
irenab | dimak: we talked about type to be Ref | 09:44 |
dimak | Ref? | 09:44 |
irenab | like subnets in lwsitch | 09:45 |
dimak | yes | 09:45 |
irenab | subnets type is Reference | 09:45 |
irenab | Ref is shortcut | 09:45 |
dimak | But lswitch doesn't have references to subnets, it contains them | 09:46 |
dimak | lport references an lswitch | 09:46 |
oanson | dimak, that's implementation | 09:46 |
xiaohhui | what about SimpleField vs ComplexField | 09:46 |
oanson | API-wise, lswitch references subnets | 09:46 |
irenab | feeling like we are trying to invent what is already there … | 09:47 |
oanson | Yes | 09:47 |
irenab | at least terminology wise | 09:47 |
dimak | maybe we should do this on the spec review or in the weekly meeting so more people can participate | 09:48 |
irenab | dimak: good idea, but I better have alternatives as started in the ethepad | 09:49 |
oanson | I think we all agree to have one class field 'fields' | 09:49 |
dimak | I think we should isolate several issues | 09:50 |
oanson | Now we just need to decide how to add the additional parameters and names: do we support native strings? Different classes or different parameters? | 09:50 |
dimak | 1st is whether the field is singular or plural | 09:50 |
oanson | dimak, regular fields or references? | 09:50 |
oanson | And if you add C++-like templates, I *will* cry! | 09:51 |
xiaohhui | both fields can be plural, lport's ips can be plural | 09:51 |
dimak | 2nd is how to wrap the serialized data in the field (or its elements in case it is plural), e.g. type, which can be a simple python type (timestamp) or an model class | 09:51 |
dimak | 3rd is dealing with references | 09:51 |
irenab | dimak: can you please add the points to the etherpad? they can be addressed there one by one | 09:52 |
dimak | Which will be tricky because we implement different references differently | 09:52 |
oanson | 1st can be solved by 2nd - the field name is as its value is expected. It's type is list if plural | 09:52 |
dimak | oanson, What about the type of the elements? | 09:52 |
irenab | oanson: this makes sense | 09:52 |
dimak | Usually I'd want a references there (since there are objects/ids) | 09:53 |
oanson | dimak, for non-trivial types (e.g. models), then a plural=True parameter? | 09:53 |
oanson | dimak, but we don't want to automatically read it out of the db unless we have to | 09:53 |
irenab | not all plurals will be references, like list of ip addressed | 09:53 |
oanson | So either a lazy read implementation | 09:53 |
oanson | or different reference types | 09:54 |
oanson | irenab, yes, that's why I stressed for non-trivial types. | 09:54 |
irenab | oanson: meaning we define somewhere trivial type? | 09:54 |
oanson | irenab, theoretically, yes | 09:55 |
oanson | trivial type - native python types - strings, ints, floats, etc. | 09:55 |
irenab | IPAddress == String? | 09:55 |
dimak | While I don't think we NEED to specify those, it can come handy if we want to enforce the model format (which is something we should decide whether we want or not) | 09:56 |
dimak | irenab, there is a type for IPAddress in netaddr package | 09:56 |
oanson | irenab, yes, If it's netaddr.IPAddress, it is not trivial | 09:56 |
oanson | In other words, if it is represented as a string, it's trivial. If as a netaddr.IPAddress, then it's not | 09:57 |
oanson | Since IPAddress can be constructed from its string representation, the same representation fits both scenario | 09:57 |
oanson | scenarios* (Got the plural wrong (: ) | 09:57 |
oanson | All right, Let's tackle issue 1: The plurality of the field, is it an element, a list, or a dictionary | 09:59 |
irenab | anyway, its just more to add to te possible attributes that can be list but not referenceother model, we can figure out details later | 09:59 |
oanson | irenab, yes, that sounds right | 09:59 |
oanson | On the one hand, it would be easier to write if the plurality is auto detected. It is easy to differentiate an object from a list | 10:00 |
oanson | (although not a dictionary) | 10:00 |
oanson | On the other, it will be a headache to maintain later | 10:00 |
dimak | I think it should be explicit | 10:02 |
dimak | do we need dictionaries at the moment? | 10:02 |
oanson | Not that I know | 10:03 |
dimak | Maybe we shouldn't solve it at this point | 10:03 |
oanson | If we make it explicit, that would not be a problem | 10:03 |
oanson | So I added this option: Option 1: Defined explicitly in the Field class, e.g. Field('fieldname', plural='list'). If plural is None or not given, then singular | 10:05 |
dimak | This works with plural='mapping' as well? | 10:05 |
dimak | maybe plural is not a good name then? | 10:05 |
irenab | waht is ‘mapping’ ? | 10:06 |
dimak | a dictionary | 10:06 |
irenab | why not call it ‘dict’? | 10:06 |
oanson | dimak, 1. I think it would be plural='dict', to make things more readable | 10:06 |
oanson | irenab, you beat me to it :) | 10:06 |
oanson | dimak, 2. I challenge you again to find a better name :) | 10:06 |
irenab | oanson: great minds think alike :-) | 10:07 |
oanson | That's one interpretation :) | 10:07 |
irenab | dimak: oanson :xiaohhui : lets keep drafting on the etherpad | 10:11 |
dimak | irenab, oanson xiaohhui , drafted some solution in etherpad that combines 1 and 2 | 10:16 |
oanson | dimak, your suggestion for 1+2 means we need to detect the type of the value | 10:16 |
dimak | Why? | 10:17 |
oanson | Because you nee to find if it's a list, or a dict, or a name | 10:18 |
oanson | Or a class. | 10:18 |
oanson | Before you can start fiddling with it | 10:18 |
dimak | Just once in the class construction magic code | 10:19 |
oanson | I think explicit specification is best | 10:20 |
dimak | The thing is this is technically the type | 10:20 |
oanson | That's like saying it's a string by passing '' as the type | 10:22 |
dimak | nope | 10:22 |
oanson | This is the C++ templating magic I wanted to avoid | 10:22 |
dimak | well yes actually | 10:23 |
dimak | list<Model> :D | 10:23 |
irenab | dimak: do not make oanson cry, please | 10:23 |
oanson | Did I mention I'll cry? I'll bawl like a toddler! | 10:23 |
*** rajivk has quit IRC | 10:23 | |
irenab | oanson: short unrelated question on devstack settings | 10:23 |
dimak | We can do with by implementing __lt__ and __gt__ | 10:23 |
oanson | Sorry, what? | 10:24 |
irenab | do we need Q_ENABLE_DRAGONFLOW_LOCAL_CONTROLLER=True | 10:24 |
irenab | DF_RUNNING_IN_GATE=True in the local.conf? | 10:24 |
oanson | Q_ENABLE_DRAGONFLOW_LOCAL_CONTROLLER=True is needed. It tells the compute node to run the df-local-controller | 10:25 |
irenab | all_in_one installation | 10:25 |
oanson | DF_RUNNING_IN_GATE, IIRC, refers to how it saves the logs | 10:25 |
*** rajivk has joined #openstack-dragonflow | 10:25 | |
irenab | oanson: thanks | 10:25 |
oanson | irenab, DF_RUNNING_IN_GATE sets all quotas to -1 . Useful for testing | 10:26 |
oanson | dimak, I didn't understand your last comment | 10:26 |
dimak | oanson, was joking, just a way to implement list<str> | 10:32 |
oanson | Sorry. Missed it :) | 10:33 |
*** dimak has quit IRC | 10:38 | |
*** lihi has quit IRC | 10:38 | |
*** saggi has quit IRC | 10:38 | |
*** oanson has quit IRC | 10:38 | |
*** lihi has joined #openstack-dragonflow | 10:47 | |
*** dimak has joined #openstack-dragonflow | 10:47 | |
*** oanson has joined #openstack-dragonflow | 10:48 | |
*** saggi has joined #openstack-dragonflow | 10:48 | |
*** irenab_ has joined #openstack-dragonflow | 11:01 | |
*** hshan4 has quit IRC | 11:08 | |
*** gongysh has quit IRC | 11:13 | |
*** irenab has quit IRC | 11:21 | |
*** irenab_ is now known as irenab | 11:21 | |
*** irenab_ has joined #openstack-dragonflow | 11:23 | |
*** irenab has quit IRC | 11:26 | |
*** hshan4 has joined #openstack-dragonflow | 11:26 | |
*** irenab has joined #openstack-dragonflow | 11:26 | |
*** openstackgerrit has joined #openstack-dragonflow | 11:27 | |
openstackgerrit | hujie proposed openstack/dragonflow: check valid resource version for nb_api https://review.openstack.org/413120 | 11:27 |
*** irenab__ has joined #openstack-dragonflow | 11:27 | |
*** irenab_ has quit IRC | 11:28 | |
*** hshan5 has joined #openstack-dragonflow | 11:29 | |
*** hshan4 has quit IRC | 11:30 | |
dimak | oanson, ping, posted a comment on the review | 11:32 |
oanson | Great. Thanks | 11:33 |
oanson | Will look | 11:33 |
oanson | dimak: Responded | 11:48 |
openstackgerrit | hujie proposed openstack/dragonflow: check valid resource version for nb_api https://review.openstack.org/413120 | 11:51 |
*** yuval has quit IRC | 12:16 | |
*** hshan5 has quit IRC | 12:23 | |
openstackgerrit | WangJian proposed openstack/dragonflow: Refactor port-status-update NB API https://review.openstack.org/396915 | 13:02 |
*** hshan5 has joined #openstack-dragonflow | 13:07 | |
*** gongysh has joined #openstack-dragonflow | 13:29 | |
*** gongysh has quit IRC | 13:34 | |
openstackgerrit | Itamar Ofek proposed openstack/dragonflow: classifier application https://review.openstack.org/412337 | 13:46 |
*** hshan5 has quit IRC | 13:58 | |
*** saggi1 has joined #openstack-dragonflow | 14:09 | |
*** saggi1 has quit IRC | 14:09 | |
*** dimak has left #openstack-dragonflow | 14:31 | |
*** dimak has joined #openstack-dragonflow | 14:32 | |
*** irenab__ has quit IRC | 14:48 | |
openstackgerrit | hujie proposed openstack/dragonflow: change network/subnet lock based on network_id https://review.openstack.org/413669 | 14:56 |
openstackgerrit | hujie proposed openstack/dragonflow: change network/subnet/port lock range https://review.openstack.org/413669 | 15:06 |
openstackgerrit | Yuli proposed openstack/dragonflow: Optimize lock for create/delete/update net commans https://review.openstack.org/413674 | 15:10 |
*** irenab_ has joined #openstack-dragonflow | 15:11 | |
yuli_s | ops, | 15:13 |
yuli_s | i just notices similar patch submitted by hujie | 15:13 |
*** yamamot__ has quit IRC | 15:23 | |
openstackgerrit | Lihi Wishnitzer proposed openstack/dragonflow: Add IPv6 ND Neighbor Advertiser application https://review.openstack.org/412208 | 15:28 |
*** yamamoto has joined #openstack-dragonflow | 15:41 | |
*** openstackgerrit_ has joined #openstack-dragonflow | 15:48 | |
*** openstackgerrit_ has quit IRC | 15:49 | |
openstackgerrit | hujie proposed openstack/dragonflow: change router/qos lock range https://review.openstack.org/413701 | 16:11 |
*** zenoway has quit IRC | 16:17 | |
*** yamamoto has quit IRC | 16:41 | |
*** openstack has quit IRC | 17:02 | |
*** openstack has joined #openstack-dragonflow | 17:07 | |
*** yamamoto has joined #openstack-dragonflow | 17:12 | |
*** yamamoto has quit IRC | 17:21 | |
*** dkehn__ has joined #openstack-dragonflow | 17:33 | |
*** dkehn has quit IRC | 17:34 | |
*** dkehn_ has joined #openstack-dragonflow | 17:42 | |
*** dkehn__ has quit IRC | 17:43 | |
*** dkehn__ has joined #openstack-dragonflow | 18:08 | |
*** dkehn_ has quit IRC | 18:09 | |
*** dkehn__ has quit IRC | 18:36 | |
*** dkehn_ has joined #openstack-dragonflow | 18:37 | |
*** yamamoto has joined #openstack-dragonflow | 19:59 | |
*** yamamoto has quit IRC | 20:04 | |
*** rajivk has quit IRC | 20:31 | |
*** rajivk has joined #openstack-dragonflow | 20:43 | |
*** yamamoto has joined #openstack-dragonflow | 21:04 | |
*** irenab__ has joined #openstack-dragonflow | 21:11 | |
*** irenab_ has quit IRC | 21:13 | |
*** yamamoto has quit IRC | 21:13 | |
*** rajivk has quit IRC | 21:58 | |
*** rajivk has joined #openstack-dragonflow | 22:10 |
Generated by irclog2html.py 2.14.0 by Marius Gedminas - find it at mg.pov.lt!