Project

General

Profile

Actions

Bug #4295

closed

[API] Improve websocket efficiency

Added by Peter Amstutz about 10 years ago. Updated about 10 years ago.

Status:
Resolved
Priority:
Normal
Assigned To:
Category:
-
Target version:
Story points:
0.5

Description

  • "logs.id > ?" condition is open ended. This should have a limit and schedule more work if necessary.
  • Should look at 'id' passed into push_events and return immediately if that id < last_log_id
  • Should record 'id' in the last_log_id if no rows were returned

Subtasks 1 (0 open1 closed)

Task #4301: Review 4295-efficient-websocketsResolvedPeter Amstutz10/23/2014Actions
Actions #1

Updated by Peter Amstutz about 10 years ago

  • Description updated (diff)
Actions #2

Updated by Ward Vandewege about 10 years ago

puma also shouldn't recover from out of memory conditions, it should just die. That way runit will restart it.

2014-07-02_18:28:36.48001 * Version 2.8.2 (ruby 2.1.1-p76), codename: Sir Edmund Percival Hillary
2014-07-02_18:28:36.48002 * Min threads: 0, max threads: 64
2014-07-02_18:28:36.48002 * Environment: production
2014-07-02_18:28:41.48719 * Listening on tcp://127.0.0.1:8100
2014-07-02_18:28:41.49459 Use Ctrl-C to stop
2014-07-08_16:16:41.99895 /var/www/4xphq.arvadosapi.com/releases/20140702182803/lib/eventbus.rb:206:in `wait_for_notify': failed to allocate memory (NoMemoryError)
2014-07-08_16:16:42.00571   from /var/www/4xphq.arvadosapi.com/releases/20140702182803/lib/eventbus.rb:206:in `block (3 levels) in on_connect'
2014-07-08_16:16:42.00572   from /var/www/4xphq.arvadosapi.com/releases/20140702182803/vendor/bundle/ruby/2.1.0/gems/activerecord-3.2.17/lib/active_record/connection_adapters/abstract/connection_pool.rb:129:in `with_connection'
2014-07-08_16:16:42.00573   from /var/www/4xphq.arvadosapi.com/releases/20140702182803/lib/eventbus.rb:195:in `block (2 levels) in on_connect'
Actions #3

Updated by Peter Amstutz about 10 years ago

  • Status changed from New to In Progress
  • Assigned To set to Peter Amstutz
Actions #4

Updated by Brett Smith about 10 years ago

Reviewing de3bb6c. There's a small typo in your comments for push_events where it says "it may nil" (missing a verb). But this is a good to merge, thanks.

Actions #5

Updated by Anonymous about 10 years ago

  • Status changed from In Progress to Resolved
  • % Done changed from 0 to 100

Applied in changeset arvados|commit:cf1097ef1225c05eb4431093a4971739a3ee5a37.

Actions #6

Updated by Ward Vandewege about 10 years ago

  • Story points set to 0.5
Actions

Also available in: Atom PDF