janelia-flyem / dvid

Distributed, Versioned, Image-oriented Dataservice
http://dvid.io
Other
197 stars 33 forks source link

change startup webhook to be compatible with configuration server #263

Closed olbris closed 6 years ago

olbris commented 6 years ago

We'd like to have DVID's startup webhook hit the department's configuration server (Swagger here: config.int.janelia.org; note especially the /importjson/{configtype}/{entry} endpoint). Currently the webhook posts bare json to the given address. The configuration server, though, expects the body of the post to contain a parameter "config" whose value is the json string containing the data.

Although it's not necessary to know for this request, we expect that "configtype" in the endpoint path will be set to "dvid_servers" or maybe just "dvid". "entry" will vary for each individual DVID server, and I propose to use "server_port" (ie, something like "emdata3_8900"), as that should be unique. However, these are decisions we can make later, as well as the final contents of the json payload. Currently host, note, and http address seem like they will be enough.