diff --git a/tornado_eventsource/__init__.py b/tornado_eventsource/__init__.py index 044347c..1777df5 100644 --- a/tornado_eventsource/__init__.py +++ b/tornado_eventsource/__init__.py @@ -1,4 +1,4 @@ #!/usr/bin/python # -*- coding: utf-8 -*- -__version__ = '2.0.0rc2' +__version__ = '2.0.0rc3' diff --git a/tornado_eventsource/event_source_client.py b/tornado_eventsource/event_source_client.py index 92127fe..914d443 100644 --- a/tornado_eventsource/event_source_client.py +++ b/tornado_eventsource/event_source_client.py @@ -5,6 +5,7 @@ import logging import collections import re +import datetime from tornado import simple_httpclient from tornado.ioloop import IOLoop @@ -38,6 +39,9 @@ def __init__(self): self.data = None self.id = None self.retry = None + self.timestamp = int( + datetime.datetime.utcnow().timestamp() * 1000 + ) def __repr__(self): return "Event<%s,%s,%s>" % (str(self.id), str(self.name), str(self.data))