mirror of
https://github.com/openstf/stf
synced 2025-10-04 18:29:17 +02:00
In-memory reaper. TtlSet needs tests.
This commit is contained in:
parent
89aedcef06
commit
25544d1a1a
10 changed files with 231 additions and 87 deletions
|
@ -53,10 +53,6 @@ module.exports = function(options) {
|
|||
})
|
||||
|
||||
devDealer.on('message', wirerouter()
|
||||
// Provider messages
|
||||
.on(wire.ProviderHeartbeatMessage, function(channel, message) {
|
||||
dbapi.updateProviderHeartbeat(message.channel)
|
||||
})
|
||||
// Initial device message
|
||||
.on(wire.DevicePresentMessage, function(channel, message, data) {
|
||||
dbapi.saveDevice(message.serial, message)
|
||||
|
@ -79,6 +75,9 @@ module.exports = function(options) {
|
|||
dbapi.saveDeviceStatus(message.serial, message.status)
|
||||
appDealer.send([channel, data])
|
||||
})
|
||||
.on(wire.DeviceHeartbeatMessage, function(channel, message, data) {
|
||||
appDealer.send([channel, data])
|
||||
})
|
||||
// Worker initialized
|
||||
.on(wire.DevicePokeMessage, function(channel, message) {
|
||||
dbapi.setDeviceChannel(message.serial, message.channel)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue