                 _server_stats_cache = stats
 
 
-
+database_is_working = false
 register_hub = (cb) ->
     database.update
         table : 'hub_servers'

                            winston.debug("possible issue -- requested to set cookie #{query.set}, but cookie not defined")
                res.end('')
            when "alive"
                res.end('')
            when "proxy"
                res.end("testing the proxy server -- #{pathname}")

        ttl   : 2*REGISTER_INTERVAL_S
        cb    : (err) ->
            if err
                database_is_working = false
                winston.debug("Error registering with database - #{err}")
            else
                database_is_working = true
                winston.debug("Successfully registered with database.")
            cb?(err)

