parent
72b85fc09f
commit
5e0eda9526
7 changed files with 65 additions and 11 deletions
|
@ -17,7 +17,9 @@ export default async (job: bq.Job, done: any): Promise<void> => {
|
|||
Instance.update({ _id: i._id }, {
|
||||
$set: {
|
||||
latestRequestSentAt: new Date(),
|
||||
latestStatus: 200
|
||||
latestStatus: 200,
|
||||
lastCommunicatedAt: new Date(),
|
||||
isNotResponding: false
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -31,7 +33,8 @@ export default async (job: bq.Job, done: any): Promise<void> => {
|
|||
Instance.update({ _id: i._id }, {
|
||||
$set: {
|
||||
latestRequestSentAt: new Date(),
|
||||
latestStatus: res != null && res.hasOwnProperty('statusCode') ? res.statusCode : null
|
||||
latestStatus: res != null && res.hasOwnProperty('statusCode') ? res.statusCode : null,
|
||||
isNotResponding: true
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
@ -126,7 +126,9 @@ export default async (job: bq.Job, done: any): Promise<void> => {
|
|||
registerOrFetchInstanceDoc(user.host).then(i => {
|
||||
Instance.update({ _id: i._id }, {
|
||||
$set: {
|
||||
latestRequestReceivedAt: new Date()
|
||||
latestRequestReceivedAt: new Date(),
|
||||
lastCommunicatedAt: new Date(),
|
||||
isNotResponding: false
|
||||
}
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue