presidium-db-client-server 0.3.1 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -111,7 +111,12 @@ function DatabaseHandler(options) {
111
111
  request.pathSegments = request.path.slice(1).split("/")
112
112
  request.pathDepth = request.pathSegments.length
113
113
 
114
- if (request.pathDepth == 2) {
114
+ if (request.path == "/health") {
115
+ response.writeHead(200, {
116
+ "Content-Type": "text/plain",
117
+ })
118
+ response.end("OK")
119
+ } else if (request.pathDepth == 2) {
115
120
  const tableName = request.pathSegments[0]
116
121
  const fname = request.pathSegments[1]
117
122
  const ht = hts.get(tableName)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "presidium-db-client-server",
3
- "version": "0.3.1",
3
+ "version": "0.4.0",
4
4
  "description": "Presidium DB client and server library",
5
5
  "author": "Richard Tong",
6
6
  "license": "CFOSS",