{"comment":{"url":"https://api.github.com/repos/Symmetric/mesos-dns/comments/14371731","html_url":"https://github.com/Symmetric/mesos-dns/commit/d66fa869e4bfe31fe941dd6c9a7b69eb3a70e7de#commitcomment-14371731","id":14371731,"user":{"login":"Symmetric","id":1524910,"avatar_url":"https://avatars.githubusercontent.com/u/1524910?v=3","gravatar_id":"","url":"https://api.github.com/users/Symmetric","html_url":"https://github.com/Symmetric","followers_url":"https://api.github.com/users/Symmetric/followers","following_url":"https://api.github.com/users/Symmetric/following{/other_user}","gists_url":"https://api.github.com/users/Symmetric/gists{/gist_id}","starred_url":"https://api.github.com/users/Symmetric/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Symmetric/subscriptions","organizations_url":"https://api.github.com/users/Symmetric/orgs","repos_url":"https://api.github.com/users/Symmetric/repos","events_url":"https://api.github.com/users/Symmetric/events{/privacy}","received_events_url":"https://api.github.com/users/Symmetric/received_events","type":"User","site_admin":false},"position":4,"line":65,"path":"records/state/state.go","commit_id":"d66fa869e4bfe31fe941dd6c9a7b69eb3a70e7de","created_at":"2015-11-13T01:05:28Z","updated_at":"2015-11-13T01:05:28Z","body":"@jdef I believe this code is fine as-is, though I'm not deeply familiar with the surrounding code, so please check my logic :)\r\n\r\nWith this code, for versions <0.26, the IPAddresses array will be empty for the struct that's decoded from the Task Status JSON. The `networkInfoIPs` IPSource will therefore return an empty list of IPs, and we'll pick up the Task's IP from the `hostIPs` IPSource (i.e. the Task's `SlaveIP`).\r\n\r\nWe're removing the ability to extract the `IPAddress` field in 0.25, but as Spike mentions above, nobody is using Network modules, so I think all we need to preserve is the pre-0.25 default behaviour of using the Slave's IP.\r\n\r\nIt is perhaps slightly confusing in that if you manually changed the IPAddress field in state.json, we'd not pick up the change, and would just use the SlaveIP. But that feels like is an edge case, and this approach keeps the code simpler.\r\n\r\nHappy to add support for `IPAddress` back in if you do feel that we should support it that way though.\r\n\r\nThoughts?"}}