[Pulp-list] Simple ping service

Lukas Zapletal lzap+fed at redhat.com
Fri Feb 18 10:12:05 UTC 2011


On 02/17/2011 03:39 PM, Mark Wagner wrote:
>
> Hmmm, seems like that would say that the server is up but gives no
> indication that the connection to the database is still alive, etc.
> Perhaps storing the version or even updating a counter in the DB
> would ensure that the entire path is alive.  You could also expand
> the scope and measure the latency for a db write to get an idea of
> the load / response times.
>
> Disclaimer, not sure of the initial scope of your work so this may
> be a bit off...

Before I start working I would like to discuss the possibilities.

I would create new document in Mongo called "properties" (?) with a 
key-value structure. And two initial values, something like:

{ key: "version", value: "0.138" }
{ key: "ping_count", value: "0" }

The ping service would return this (increasing the counter every time):

{ result: "ok", version: "0.138" }

During the database migration the version number would be set.

Is this acceptable?

Thanks

-- 
Later,
   Lukas "lzap" Zapletal




More information about the Pulp-list mailing list