Explorar el Código

add /health_check/redis route back in

Henry Oswald hace 7 años
padre
commit
b5564095f3
Se han modificado 1 ficheros con 9 adiciones y 0 borrados
  1. 9 0
      services/document-updater/app.coffee

+ 9 - 0
services/document-updater/app.coffee

@@ -71,7 +71,16 @@ app.get '/status', (req, res)->
 	else
 		res.send('document updater is alive')
 
+
 docUpdaterRedisClient = require("redis-sharelatex").createClient(Settings.redis.documentupdater)
+app.get "/health_check/redis", (req, res, next) ->
+	docUpdaterRedisClient.healthCheck (error) ->
+		if error?
+			logger.err {err: error}, "failed redis health check"
+			res.send 500
+		else
+			res.send 200
+
 app.get "/health_check/redis_cluster", (req, res, next) ->
 	docUpdaterRedisClient.healthCheck (error) ->
 		if error?