Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require_relative 'my_db.rb'
- SCHEDULER.every '30s', :first_in => 0 do |job|
- db = MyDb.conn
- sql = "SELECT COUNT(locationid) from locations"
- results = db.query(sql)
- send_event('locationcount', { value: object.each } )
- db.close
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement