Skip to content
This repository was archived by the owner on Aug 20, 2018. It is now read-only.

lgaches/TitanHealthz

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TitanHealthz

titan.addFunction(healthz) adds a healthcheck endpoint to your Titan app.

The health check can be customized through:

titan.addFunction(healthzWithCheck {
  try functionThatThrowsIfThereIsAProblem()
  let result = try someOtherCheck()
  return "functionThatThrows and someOtherCheck (\(result)) both operating normally."
})

Performing a GET /healthz against your Titan app will now report 200 OK if everything is ok, or a 500 plus a string dump of the error if there's a problem.

About

Add healthchecks to your Titan app, implementing the `healthz` pattern.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Swift 71.9%
  • Shell 28.1%