Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
smogonet
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dominik Rosiek
smogonet
Commits
02365b6b
Commit
02365b6b
authored
Dec 13, 2016
by
Antek Grzanka
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cache?
parent
5ee60c43
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
0 deletions
+4
-0
models.py
models.py
+3
-0
requirements.txt
requirements.txt
+1
-0
No files found.
models.py
View file @
02365b6b
...
...
@@ -2,9 +2,11 @@ import uuid
from
db
import
DDBtypes
,
DDBmeasurements
,
DDBstations
from
functools
import
partial
import
hermes.backend.dict
from
tornado.ioloop
import
IOLoop
cache
=
hermes
.
Hermes
(
hermes
.
backend
.
dict
.
Backend
)
class
DDBobject
(
object
):
@
classmethod
...
...
@@ -66,6 +68,7 @@ class Measurement(DDBobject):
self
.
value
=
value
self
.
time
=
time
@
cache
(
ttl
=
6000
)
@
classmethod
def
get
(
cls
,
measurement_id
):
if
cls
.
stored
.
get
(
measurement_id
,
None
):
...
...
requirements.txt
View file @
02365b6b
tornado
== 4.4.2
botocore
==0.65.0
tornado-botocore
==0.1.6
HermesCache
==0.6.0
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment