Skip to content
This repository has been archived by the owner on Jun 3, 2022. It is now read-only.

Commit

Permalink
/_actuator/probes to include details of alive probes (#279)
Browse files Browse the repository at this point in the history
* probes to include details if alive

* fixed e2e test
  • Loading branch information
fuxingloh authored Jul 29, 2021
1 parent 2f30989 commit 74fec5e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions src/module.api/actuator.e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,10 @@ describe('/_actuator/probes/readiness', () => {
status: 'down'
},
model: {
count: {
defid: expect.any(Number),
index: expect.any(Number)
},
status: 'up'
}
},
Expand All @@ -87,6 +91,10 @@ describe('/_actuator/probes/readiness', () => {
},
info: {
model: {
count: {
defid: expect.any(Number),
index: expect.any(Number)
},
status: 'up'
}
},
Expand Down
2 changes: 1 addition & 1 deletion src/module.defid/defid.probes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,6 @@ export class DeFiDProbeIndicator extends ProbeIndicator {
return this.withDead('defid', 'defid is not connected to any peer', details)
}

return this.withAlive('defid')
return this.withAlive('defid', details)
}
}
2 changes: 1 addition & 1 deletion src/module.model/_model.probes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,6 @@ export class ModelProbeIndicator extends ProbeIndicator {
return this.withDead('model', 'synced blocks are more than 5 blocks behind', details)
}

return this.withAlive('model')
return this.withAlive('model', details)
}
}

0 comments on commit 74fec5e

Please sign in to comment.