Skip to content

Commit

Permalink
Fixing up imports in race / performance tests.
Browse files Browse the repository at this point in the history
Also renaming tasklet race with underscores.
  • Loading branch information
dhermes committed Jan 13, 2015
1 parent fbd9004 commit 00ecdbe
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 15 deletions.
30 changes: 15 additions & 15 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,19 @@ FLAGS=
PYTHON= python -Wignore

help:
@echo 'Makefile for NDB for Google App Engine '
@echo ' '
@echo 'Usage: '
@echo ' make bench Task creation benchmark '
@echo ' make keybench Key comparison benchmark '
@echo ' make gettaskletrace Test race conditions in get_tasklet'
@echo ' make stress Threadsafe Py27 Stress Test '
@echo ' make race Race condition tests for NDB '
@echo ' make multithread_test Multi-threading torture test '
@echo ' make repl Custom REPL with NDB loaded '
@echo ' '
@echo 'NOTE: This file is being wound down and will be fully '
@echo ' replaced by tox.ini. '
@echo 'Makefile for NDB for Google App Engine '
@echo ' '
@echo 'Usage: '
@echo ' make bench Task creation benchmark '
@echo ' make keybench Key comparison benchmark '
@echo ' make get_tasklet_race Test race conditions in get_tasklet'
@echo ' make stress Threadsafe Py27 Stress Test '
@echo ' make race Race condition tests for NDB '
@echo ' make multithread_test Multi-threading torture test '
@echo ' make repl Custom REPL with NDB loaded '
@echo ' '
@echo 'NOTE: This file is being wound down and will be fully '
@echo ' replaced by tox.ini. '


bench:
Expand All @@ -30,8 +30,8 @@ bench:
keybench:
PYTHONPATH=. $(PYTHON) keybench.py $(FLAGS)

gettaskletrace:
PYTHONPATH=. $(PYTHON) gettaskletrace.py $(FLAGS)
get_tasklet_race:
PYTHONPATH=. $(PYTHON) get_tasklet_race.py $(FLAGS)

stress:
PYTHONPATH=. $(PYTHON) stress.py $(FLAGS)
Expand Down
1 change: 1 addition & 0 deletions gettaskletrace.py → get_tasklet_race.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""Runs an infinite loop to find race conditions in context get_tasklet."""

from ndb import google_imports # For path fixing.
from google.appengine.ext import testbed

from ndb import model
Expand Down
1 change: 1 addition & 0 deletions race.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import threading
import time

from ndb import google_imports # For path fixing.
from google.appengine.api import memcache
from google.appengine.ext import testbed

Expand Down
2 changes: 2 additions & 0 deletions stress.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import threading
import time

from ndb import google_imports # For path fixing.
from google.appengine.api import apiproxy_stub_map
from google.appengine.datastore import datastore_stub_util

Expand Down Expand Up @@ -107,5 +108,6 @@ def main():

tb.deactivate()


if __name__ == '__main__':
main()

0 comments on commit 00ecdbe

Please sign in to comment.