| 1 | package registry |
| 2 | |
| 3 | type Backend interface { |
| 4 | // Register registers fabio as a service in the registry. |
| 5 | Register(services []string) error |
| 6 | |
| 7 | // Deregister removes all service registrations for fabio. |
| 8 | DeregisterAll() error |
| 9 | |
| 10 | // Deregister removes the given service registration for fabio. |
| 11 | Deregister(service string) error |
| 12 | |
| 13 | // ManualPaths returns the list of paths for which there |
| 14 | // are overrides. |
| 15 | ManualPaths() ([]string, error) |
| 16 | |
| 17 | // ReadManual returns the current manual overrides and |
| 18 | // their version as seen by the registry. |
| 19 | ReadManual(path string) (value string, version uint64, err error) |
| 20 | |
| 21 | // WriteManual writes the new value to the registry if the |
| 22 | // version of the stored document still matchhes version. |
| 23 | WriteManual(path string, value string, version uint64) (ok bool, err error) |
| 24 | |
| 25 | // WatchServices watches the registry for changes in service |
| 26 | // registration and health and pushes them if there is a difference. |
| 27 | WatchServices() chan string |
| 28 | |
| 29 | // WatchManual watches the registry for changes in the manual |
| 30 | // overrides and pushes them if there is a difference. |
| 31 | WatchManual() chan string |
| 32 | |
| 33 | // WatchNoRouteHTML watches the registry for changes in the html returned |
| 34 | // when a requested route is not found |
| 35 | WatchNoRouteHTML() chan string |
| 36 | } |
| 37 | |
| 38 | var Default Backend |
no outgoing calls
no test coverage detected