OLD | NEW |
1 // Copyright 2013 Canonical Ltd. | 1 // Copyright 2013 Canonical Ltd. |
2 // Licensed under the AGPLv3, see LICENCE file for details. | 2 // Licensed under the AGPLv3, see LICENCE file for details. |
3 | 3 |
4 package instancepoller | 4 package instancepoller |
5 | 5 |
6 import ( | 6 import ( |
7 "fmt" | 7 "fmt" |
8 "time" | 8 "time" |
9 | 9 |
| 10 "github.com/juju/errors" |
10 "github.com/juju/loggo" | 11 "github.com/juju/loggo" |
11 | 12 |
12 "launchpad.net/juju-core/errors" | |
13 "launchpad.net/juju-core/instance" | 13 "launchpad.net/juju-core/instance" |
14 "launchpad.net/juju-core/state" | 14 "launchpad.net/juju-core/state" |
15 "launchpad.net/juju-core/state/api/params" | 15 "launchpad.net/juju-core/state/api/params" |
16 "launchpad.net/juju-core/state/watcher" | 16 "launchpad.net/juju-core/state/watcher" |
17 ) | 17 ) |
18 | 18 |
19 var logger = loggo.GetLogger("juju.worker.instanceupdater") | 19 var logger = loggo.GetLogger("juju.worker.instanceupdater") |
20 | 20 |
21 // ShortPoll and LongPoll hold the polling intervals for the instance | 21 // ShortPoll and LongPoll hold the polling intervals for the instance |
22 // updater. When a machine has no address or is not started, it will be | 22 // updater. When a machine has no address or is not started, it will be |
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
273 if len(a0) != len(a1) { | 273 if len(a0) != len(a1) { |
274 return false | 274 return false |
275 } | 275 } |
276 for i := range a0 { | 276 for i := range a0 { |
277 if a0[i] != a1[i] { | 277 if a0[i] != a1[i] { |
278 return false | 278 return false |
279 } | 279 } |
280 } | 280 } |
281 return true | 281 return true |
282 } | 282 } |
OLD | NEW |