Fix DI bugs; implement general logging service

This commit is contained in:
garrettmills
2020-06-17 09:48:01 -05:00
parent 6c4696227b
commit eddb4f1fbe
13 changed files with 258 additions and 5 deletions

15
lib/src/const/status.ts Normal file
View File

@@ -0,0 +1,15 @@
const STATUS_STOPPED = Symbol('status stopped')
const STATUS_STARTING = Symbol('status starting')
const STATUS_RUNNING = Symbol('status running')
const STATUS_STOPPING = Symbol('status stopping')
const STATUS_ERROR = Symbol('status error')
const isStatus = (something: any) => [
STATUS_STOPPED,
STATUS_STARTING,
STATUS_RUNNING,
STATUS_STOPPING,
STATUS_ERROR,
].includes(something)
export { STATUS_STOPPED, STATUS_STARTING, STATUS_RUNNING, STATUS_STOPPING, STATUS_ERROR, isStatus }