discovery icon indicating copy to clipboard operation
discovery copied to clipboard

Discovery should monitor the Weave container

Open inercia opened this issue 10 years ago • 2 comments

When using the local Weave router, Discovery should listen for events on the weave container. If the container disappears, it should remove the router's IP from the discovery backend.

inercia avatar Sep 07 '15 11:09 inercia

We could implement this in two different ways:

  • listening for Docker events (this would probably require some privileges)
  • we must periodically refresh the registration in the backend, so we could do a GET /status from the router we are advertising before the refresh. Tthis would also work for remote routers...

Any sugestion on how to tackle this @rade?

What should we do if the router is dead? Discovery should probably exit...

inercia avatar Sep 07 '15 11:09 inercia

Any sugestion on how to tackle this

Depends on how promptly you want the removal to happen. With events it will happen very quickly. But if you don't care then a 'healthcheck' is fine and, as you say, is more flexible.

rade avatar Sep 09 '15 11:09 rade