Skip to content

Commit

Permalink
status messages with polling
Browse files Browse the repository at this point in the history
  • Loading branch information
gonzalo authored and gonzalo committed Apr 25, 2014
1 parent 3bcc8b3 commit 1ed0d80
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 15 deletions.
10 changes: 5 additions & 5 deletions urbansim/server/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,6 @@
$ celery -A urbansim.server.tasks worker --loglevel=info
"""

from celery import Celery

app = Celery('tasks', backend='amqp', broker='amqp://guest@localhost//')

import cPickle
import decimal
import json
Expand All @@ -32,7 +28,11 @@
# sys.path.remove(".")
# sys.path.pop(0)

# should we do this on each task
from celery import Celery

app = Celery('tasks', backend='amqp', broker='amqp://guest@localhost//')

# should we do this on each task?
DSET = dataset.LocalDataset('../bayarea_urbansim/data/bayarea.h5')


Expand Down
10 changes: 0 additions & 10 deletions urbansim/server/urbansimd.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,16 +71,6 @@ def enable_cors():
'Origin, Accept, Content-Type, X-Requested-With, X-CSRF-Token'


# http://localhost:8765/stream
@route('/stream')
def stream():
yield 'START'
time.sleep(3)
yield 'MIDDLE'
time.sleep(10)
yield 'END'


@route('/configs')
def list_configs():
def resp():
Expand Down

0 comments on commit 1ed0d80

Please sign in to comment.