20:12:31 #startmeeting better host tracker interns 20:12:31 Meeting started Tue Jul 1 20:12:31 2014 UTC. The chair is colindixon. Information about MeetBot at http://ci.openstack.org/meetbot.html. 20:12:31 Useful Commands: #action #agreed #help #info #idea #link #topic #startvote. 20:12:31 The meeting name has been set to 'better_host_tracker_interns' 20:14:47 djx: good question 20:15:32 I don't know if the InstanceIdentifier is that one 20:15:42 on line 48 20:19:31 let me see if I understand this 20:20:16 InstanceIdentifier does what? 20:20:32 builds up the type for AddressCapableNodeConnector? 20:20:41 yup 20:20:55 It's what I think.. 20:22:11 and then tells the databroker to listen to changes 20:22:25 yup 20:22:37 can I run this somehow? 20:22:43 I didn't try it 20:22:56 But I think it's runnable 20:24:40 sorry, give me two secs 20:38:52 djx: gonna try to import into eclipse 20:39:18 I thought we were gonna move the model into opendaylight/betterhosttracker/model 20:40:04 Oh I didn't remember that 20:40:33 that's not a big deal for the moment but I can change that after this meeting 20:40:46 ok 20:42:00 I think we just wanted a subdir of opendaylight, since we're not really part of md-sal 20:42:08 colindixon can correct me if I'm wrong 20:42:51 there's a northbound/hosttracker inside the controller 20:55:31 evanz does it work? 20:56:33 I was able to import now I have betterhosttracker-impl project 20:56:51 complaining about the pom though 20:56:55 maybe I should import fresh 20:59:48 I never get errors from poms on netbean, only when trying to compile 21:00:02 imported it by itself 21:00:07 no problems 21:00:28 maybe we should try writing a unit test or something 21:04:58 that's a good idea 21:05:07 colindixon, where are you? 21:07:28 sorry 21:07:31 back 21:07:35 wound up having to take a phone call 21:07:41 oh ok 21:07:51 no problem 21:08:36 so, do you still have time? or should we punt ’til tomorrow? 21:08:44 I've ime 21:08:55 it's earlier :-) 21:09:01 ya no problems here 21:09:28 lol 21:09:30 ok 21:09:49 #topic status update 21:09:56 so, I’m going to look at the github now 21:09:59 #info some impl is up on the github 21:10:06 ok 21:10:17 #link https://github.com/nilok/betterhosttracker/tree/master/opendaylight/md-sal/betterhosttracker/plugin/src/main/java/org/opendaylight/controller/betterhosttracker/plugin/internal 21:11:07 cool 21:11:23 this looks good 21:11:31 djx had a question 21:11:36 colindixon line 40 21:11:39 line 40 21:11:51 of Impl 21:11:55 ok 21:12:02 looking at it right now 21:12:21 and there was the question of the directory structure, right now things are still in odl/md-sal 21:12:30 so, I think we really want to listen for AddressCapabaleNodeConnectors 21:13:02 colindixon I think that's what is done right now on registerAsDataChangeListener method 21:13:38 ok 21:14:43 then you should get back AddressCapableNodeConnectors, which you can check for with instanceof 21:15:24 the data objects you get 21:15:34 should be AddressCapableNodeConnectors 21:15:55 although, frustratingly, we’re going to need to see if the l2switch address tracker is implemented yet 21:16:17 colindixon the key of the giving map? 21:16:24 on the onDataChanged method? 21:16:25 which is not 21:16:38 the map Map, DataObject> 21:16:47 but like evanz said, we can create a unit test, no? 21:17:04 yeah 21:17:09 you could create a unit test 21:17:21 although you’d need to figure out what you expect to come back 21:17:28 right 21:18:07 which in and of itself is painful 21:18:56 But I don't understand one thing what are the values from the Map, DataObject> ? 21:19:29 so, InstanceIdentifier is actually going to be a path 21:20:02 let me see if I can get an example 21:21:11 https://wiki.opendaylight.org/view/OpenDaylight_OpenFlow_Plugin::End_to_End_Inventory 21:21:34 so, the instance identifier is going to be something like “opendaylight-inventory:nodes/node/openflow:1” 21:21:48 except it’s going to keep going 21:22:18 right, the keep going until reaches AddressCapabaleNodeConnectors right? 21:22:39 yes 21:22:44 so that’s what you’re going to get back 21:22:47 a path 21:22:51 and then the DataObject 21:23:00 right, what is that DataObject? 21:23:01 AddressCapabaleNodeConnector 21:23:09 it should be that 21:23:09 really? 21:23:19 yes 21:23:43 that should be it 21:23:55 why a Map? 21:24:04 because there could be multiple changes 21:24:13 well, two reasons: 21:24:13 ah 21:24:24 first, you need a list because there could be multiple changes 21:24:24 because java doesn't support tuples 21:24:37 but that isn’t a map 21:24:48 you need map because you need both the path and the data 21:25:10 because the AddressCapabaleNodeConnector doesn’t actually tell you what Node it’s attached to 21:25:16 you need to infer that from the path 21:25:21 I think 21:25:22 right 21:25:45 what do I with that? 21:26:06 what can I do with that* 21:31:25 ok 21:31:38 so, with that, you should be able to extract addresses 21:34:36 AddressCapableNodeConnector extends AddressNodeConnector which has a method getAddresses() which returns a List of Addresses 21:34:54 Addresses have methods for getIp(), getMac(), etc. 21:35:29 #info the DataObject that comes back from the data changed notification should be an AddressCapableNodeConnector 21:35:32 Yes I'm seeing that 21:35:37 #info AddressCapableNodeConnector extends AddressNodeConnector which has a method getAddresses() which returns a List of Addresses 21:35:42 #info Addresses have methods for getIp(), getMac(), etc. 21:36:01 so, that’s how you get addresses from the data changed notification 21:36:08 ok this should be straightforward 21:36:17 and you could even subscribe for Addresses directly I tihnk 21:36:27 what do you mean? 21:37:03 instead of this: InstanceIdentifier addrCapableNodeConnectors = // 21:37:04 InstanceIdentifier.builder(Nodes.class) // 21:37:05 .child(Node.class).child(NodeConnector.class) // 21:37:05 .augmentation(AddressCapableNodeConnector.class).build(); 21:37:33 InstanceIdentifier addrCapableNodeConnectors = // 21:37:34 InstanceIdentifier.builder(Nodes.class) // 21:37:35 .child(Node.class).child(NodeConnector.class) // 21:37:35 .augmentation(AddressCapableNodeConnector.class).child(Addresses).build(); 21:37:37 I think 21:37:44 or something like it 21:37:57 on the registerAsDataChangeListener method? 21:38:05 yeah 21:38:20 why? 21:39:15 given that you don’t actually care about the AddressCapableNodeConnector and only actually care about the Addresses, that seem easier 21:39:34 but both work 21:39:48 it’s whatever’s easy 21:39:49 So hosttracker will be listening for address changes instead of node connector changes? 21:39:55 yeah 21:40:12 because you really only care if there are new Addresses under the node connector, right? 21:40:33 yeah but I care the node connector itself, no? 21:40:42 sure, but you get that from the path 21:40:46 in the instanceidentifier 21:40:58 right I was think that 21:41:13 I imagine you care more about the nodeconnector because if it goes down 21:41:17 everything behind it is gone 21:41:21 or something like that 21:42:09 not for the observations 21:42:10 should that be our problem? 21:42:26 I mean, we have the last time we saw an address on that port 21:43:57 well, lets get it to work just ingesting things for now 21:44:17 we can deal with what to do when/if a port goes down next 21:44:40 so, you may be able fake the data you need by making RESTCONF POST queries 21:44:42 okay 21:44:42 that’s the other thing 21:44:51 how to create Addresses so you can test stuff 21:44:57 given that the address tracker doesn’t exist 21:45:08 evanz: do you know anything about the status of the address tracker? 21:45:09 evanz, can you deal with the tests and that? 21:45:26 does this at least make sense now? 21:45:38 for me yes, I'm much clear now 21:45:41 ok 21:45:41 good 21:45:42 colindixon djx: sure 21:45:48 yes things are clearer now 21:45:49 sorry I was awol :p 21:46:05 before I had no idea about dataservice and InstanceIdentifier 21:46:24 colindixon: I just pulled latest from l2switch repo and no at impl yet 21:46:27 as far as I can tell 21:46:57 #action djx to work on setting things up to get the data changed notifications and pull out the the Addresses (or AddressCapableNodeConnector) and path to to generate an observation of a NodeConnector, IP and MAC 21:47:18 #action evanz to work on how to write test cases, either by faking the data with RESTCONF or just writing good unit tests 21:47:29 evanz: yeah 21:47:34 that’s what I saw 21:47:45 I’ll send an e-mail and ask 21:48:01 colindixon that observations will be saved on a Map? 21:48:15 If yes, what will be X, our yang model of host? 21:49:07 well, really the information should be List 21:49:13 where X is our model of a host right 21:49:20 ah okay 21:49:21 since it should also have a nodeconnector in it? 21:49:26 or actually a list of nodeconnectors 21:49:37 yes I think the yang have that 21:50:24 #info internally, we should track a list of our modeled hosts 21:50:39 #info and eventually publish them into the data store 21:50:42 ok 21:50:49 #action djx will change the path of yang model previously created 21:51:14 ok 21:51:17 that sounds good 21:51:26 so, if you guys are happy with what you know now 21:51:30 I’m happy to let you guys go 21:51:37 one more thing 21:51:45 sure 21:51:48 evanz and I were talking 21:51:51 djx: what do you mean by “change the path” 21:51:56 yes, that 21:52:06 the path of the project 21:52:11 of the yang model 21:52:12 ah 21:52:13 ok 21:52:17 colindixon we mentioned opendaylight/betterhosttracker/model 21:52:24 that sounds good to me 21:52:24 and opendaylight/betterhosttracker/implementation 21:52:27 if I remember correctly 21:52:32 instead of using odl/md-sal 21:52:37 yeah 21:52:43 ok, sounds great 21:52:43 I was just thinking we’d mirror what l2 switch was doing 21:52:46 ok 21:52:49 ttyl 21:52:54 thanks for staying 21:52:57 #endmeeting