aurora-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kevi...@apache.org
Subject [1/2] aurora git commit: One python_library per exported setup.py project
Date Mon, 03 Aug 2015 18:41:52 GMT
Repository: aurora
Updated Branches:
  refs/heads/master 7f81411da -> 8fa4fb0f3


http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/cli/commands/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/cli/commands/BUILD b/src/main/python/apache/thermos/cli/commands/BUILD
deleted file mode 100644
index 552eeb4..0000000
--- a/src/main/python/apache/thermos/cli/commands/BUILD
+++ /dev/null
@@ -1,113 +0,0 @@
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-python_library(
-  name = 'commands',
-  dependencies = [
-    ':help',
-    ':inspect',
-    ':kill',
-    ':read',
-    ':run',
-    ':simplerun',
-    ':status',
-    ':tail',
-  ]
-)
-
-python_library(
-  name = 'help',
-  sources = ['help.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.app',
-  ]
-)
-
-python_library(
-  name = 'inspect',
-  sources = ['inspect.py'],
-  dependencies = [
-    '3rdparty/python:pystachio',
-    '3rdparty/python:twitter.common.app',
-    'src/main/python/apache/thermos/cli:common',
-    'src/main/python/apache/thermos/common:options',
-  ]
-)
-
-python_library(
-  name = 'kill',
-  sources = ['kill.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.app',
-    'src/main/python/apache/thermos/cli:common',
-    'src/main/python/apache/thermos/core:helper',
-  ]
-)
-
-python_library(
-  name = 'read',
-  sources = ['read.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.app',
-    '3rdparty/python:twitter.common.recordio',
-    'src/main/python/apache/thermos/common:ckpt',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-  ]
-)
-
-python_library(
-  name = 'run',
-  sources = ['run.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.app',
-    'src/main/python/apache/thermos/cli:common',
-    'src/main/python/apache/thermos/common:options',
-  ]
-)
-
-python_library(
-  name = 'simplerun',
-  sources = ['simplerun.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.app',
-    'src/main/python/apache/thermos/cli:common',
-    'src/main/python/apache/thermos/config',
-    'src/main/python/apache/thermos/config:schema',
-  ]
-)
-
-python_library(
-  name = 'status',
-  sources = ['status.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.app',
-    'src/main/python/apache/thermos/common:ckpt',
-    'src/main/python/apache/thermos/monitoring:detector',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-  ]
-)
-
-python_library(
-  name = 'tail',
-  sources = ['tail.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.app',
-    '3rdparty/python:twitter.common.dirutil',
-    'src/main/python/apache/thermos/common:ckpt',
-    'src/main/python/apache/thermos/common:path',
-    'src/main/python/apache/thermos/monitoring:detector',
-    'src/main/python/apache/thermos/monitoring:monitor',
-  ]
-)
-

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/cli/commands/__init__.py
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/cli/commands/__init__.py b/src/main/python/apache/thermos/cli/commands/__init__.py
new file mode 100644
index 0000000..0663a9a
--- /dev/null
+++ b/src/main/python/apache/thermos/cli/commands/__init__.py
@@ -0,0 +1,13 @@
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/common/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/common/BUILD b/src/main/python/apache/thermos/common/BUILD
index 942fc15..879b812 100644
--- a/src/main/python/apache/thermos/common/BUILD
+++ b/src/main/python/apache/thermos/common/BUILD
@@ -14,54 +14,15 @@
 
 import os
 
-python_library(
-  name = 'ckpt',
-  sources = ['ckpt.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.log',
-    '3rdparty/python:twitter.common.recordio',
-    'api/src/main/thrift/org/apache/thermos:py-thrift'
-  ]
-)
-
-python_library(
-  name = 'path',
-  sources = ['path.py'],
-)
-
-python_library(
-  name = 'planner',
-  sources = ['planner.py'],
-)
-
-python_library(
-  name = 'options',
-  sources = ['options.py'],
-  dependencies = [
-    '3rdparty/python:pystachio',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-  ]
-)
-
-python_library(
-  name = 'statuses',
-  sources = ['statuses.py'],
-)
-
-python_library(
-  name = 'constants',
-  sources = ['constants.py']
-)
 
 python_library(
   name = 'common',
+  sources = rglobs('*.py'),
   dependencies = [
-    ':ckpt',
-    ':constants',
-    ':options',
-    ':path',
-    ':planner',
-    ':statuses',
+    '3rdparty/python:pystachio',
+    '3rdparty/python:twitter.common.log',
+    '3rdparty/python:twitter.common.recordio',
+    'api/src/main/thrift/org/apache/thermos'
   ],
   provides = setup_py(
     name = 'apache.thermos.common',

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/config/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/config/BUILD b/src/main/python/apache/thermos/config/BUILD
index d9099c5..6e52c4b 100644
--- a/src/main/python/apache/thermos/config/BUILD
+++ b/src/main/python/apache/thermos/config/BUILD
@@ -14,21 +14,14 @@
 
 import os
 
-python_library(
-  name = 'schema',
-  sources = globs('*.py'),
-  dependencies = [
-    '3rdparty/python:pystachio',
-    '3rdparty/python:twitter.common.lang',
-    'src/main/python/apache/thermos/common:planner'
-  ],
-)
 
 python_library(
   name = 'config',
+  sources = rglobs('*.py'),
   dependencies = [
-    ':schema',
-    'src/main/python/apache/thermos/common',  # cover common:planner
+    '3rdparty/python:pystachio',
+    '3rdparty/python:twitter.common.lang',
+    'src/main/python/apache/thermos/common',
   ],
   provides = setup_py(
     name = 'apache.thermos.config',

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/config/bin/config_load.py
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/config/bin/config_load.py b/src/main/python/apache/thermos/config/bin/config_load.py
deleted file mode 100644
index d6e1f82..0000000
--- a/src/main/python/apache/thermos/config/bin/config_load.py
+++ /dev/null
@@ -1,62 +0,0 @@
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-from __future__ import print_function
-
-import json
-import pprint
-
-from twitter.common import app
-
-from apache.thermos.config.loader import ThermosConfigLoader
-
-
-def main(args):
-  """Given .thermos configs, loads them and prints out information about them."""
-
-  if len(args) == 0:
-    app.help()
-
-  for arg in args:
-    print('\nparsing %s\n' % arg)
-    tc = ThermosConfigLoader.load(arg)
-
-    for task_wrapper in tc.tasks():
-      task = task_wrapper.task
-      if not task.has_name():
-        print('Found unnamed task!  Skipping...')
-        continue
-
-      print('Task: %s [check: %s]' % (task.name(), task.check()))
-      if not task.processes():
-        print('  No processes.')
-      else:
-        print('  Processes:')
-        for proc in task.processes():
-          print('    %s' % proc)
-
-      ports = task_wrapper.ports()
-      if not ports:
-        print('  No unbound ports.')
-      else:
-        print('  Ports:')
-        for port in ports:
-          print('    %s' % port)
-
-      print('raw:')
-      pprint.pprint(json.loads(task_wrapper.to_json()))
-
-
-app.set_usage("%s config1 config2 ..." % app.name())
-app.main()

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/config/bin/config_repl.py
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/config/bin/config_repl.py b/src/main/python/apache/thermos/config/bin/config_repl.py
deleted file mode 100644
index ae9ca3b..0000000
--- a/src/main/python/apache/thermos/config/bin/config_repl.py
+++ /dev/null
@@ -1,19 +0,0 @@
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-from code import interact
-
-from apache.thermos.config.schema import *  # noqa
-
-interact('Thermos Config REPL', local=locals())

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/core/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/core/BUILD b/src/main/python/apache/thermos/core/BUILD
index d47b7a2..1094664 100644
--- a/src/main/python/apache/thermos/core/BUILD
+++ b/src/main/python/apache/thermos/core/BUILD
@@ -14,73 +14,20 @@
 
 import os
 
-python_library(
-  name = 'helper',
-  sources = ['helper.py'],
-  dependencies = [
-    '3rdparty/python:psutil',
-    '3rdparty/python:twitter.common.dirutil',
-    '3rdparty/python:twitter.common.log',
-    '3rdparty/python:twitter.common.quantity',
-    '3rdparty/python:twitter.common.recordio',
-    'src/main/python/apache/thermos/common:ckpt',
-    'src/main/python/apache/thermos/common:path',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-  ]
-)
 
 python_library(
-  name = 'muxer',
-  sources = ['muxer.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.log',
-    '3rdparty/python:twitter.common.recordio',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-  ]
-)
-
-python_library(
-  name = 'process',
-  sources = ['process.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.dirutil',
-    '3rdparty/python:twitter.common.lang',
-    '3rdparty/python:twitter.common.log',
-    '3rdparty/python:twitter.common.quantity',
-    '3rdparty/python:twitter.common.recordio',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-  ]
-)
-
-python_library(
-  name = 'runner',
-  sources = ['__init__.py', 'runner.py'],
+  name = 'core',
+  sources = rglobs('*.py'),
   dependencies = [
-    ':helper',
-    ':muxer',
-    ':process',
     '3rdparty/python:psutil',
     '3rdparty/python:twitter.common.dirutil',
+    '3rdparty/python:twitter.common.lang',
     '3rdparty/python:twitter.common.log',
     '3rdparty/python:twitter.common.quantity',
     '3rdparty/python:twitter.common.recordio',
-    'src/main/python/apache/thermos/common:ckpt',
-    'src/main/python/apache/thermos/common:path',
-    'src/main/python/apache/thermos/common:planner',
-    'src/main/python/apache/thermos/config:schema',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-  ]
-)
-
-python_library(
-  name = 'core',
-  dependencies = [
-    ':runner',
-
-    # covering libs
+    'api/src/main/thrift/org/apache/thermos',
     'src/main/python/apache/thermos/common',
     'src/main/python/apache/thermos/config',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
   ],
   provides = setup_py(
     name = 'apache.thermos.core',

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/monitoring/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/monitoring/BUILD b/src/main/python/apache/thermos/monitoring/BUILD
index e885102..65ba708 100644
--- a/src/main/python/apache/thermos/monitoring/BUILD
+++ b/src/main/python/apache/thermos/monitoring/BUILD
@@ -14,79 +14,21 @@
 
 import os
 
-python_library(
-  name = 'detector',
-  sources = ['detector.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.lang',
-    'src/main/python/apache/thermos/common:constants',
-    'src/main/python/apache/thermos/common:path',
-  ]
-)
-
-python_library(
-  name = 'monitor',
-  sources = ['monitor.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.log',
-    '3rdparty/python:twitter.common.recordio',
-    'src/main/python/apache/thermos/common:ckpt',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-  ]
-)
-
-python_library(
-  name = 'disk',
-  sources = ['disk.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.dirutil',
-    '3rdparty/python:twitter.common.exceptions',
-    '3rdparty/python:twitter.common.lang',
-    '3rdparty/python:twitter.common.log',
-  ]
-)
 
 python_library(
-  name = 'process',
-  sources = ['process.py'],
-)
-
-python_library(
-  name = 'process_collector_psutil',
-  sources = ['process_collector_psutil.py'],
+  name = 'monitoring',
+  sources = rglobs('*.py'),
   dependencies = [
-    ':process',
     '3rdparty/python:psutil',
-    '3rdparty/python:twitter.common.log',
-  ]
-)
-
-python_library(
-  name = 'resource',
-  sources = ['resource.py'],
-  dependencies = [
-    ':disk',
-    ':monitor',
-    ':process',
-    ':process_collector_psutil',
     '3rdparty/python:twitter.common.collections',
     '3rdparty/python:twitter.common.concurrent',
+    '3rdparty/python:twitter.common.dirutil',
+    '3rdparty/python:twitter.common.exceptions',
     '3rdparty/python:twitter.common.lang',
     '3rdparty/python:twitter.common.log',
     '3rdparty/python:twitter.common.quantity',
-  ]
-)
-
-python_library(
-  name = 'monitoring',
-  dependencies = [
-    ':detector',
-    ':disk',
-    ':monitor',
-    ':process',
-    ':resource',
-
-    # covering dependency for common
+    '3rdparty/python:twitter.common.recordio',
+    'api/src/main/thrift/org/apache/thermos',
     'src/main/python/apache/thermos/common',
   ],
   provides = setup_py(

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/observer/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/observer/BUILD b/src/main/python/apache/thermos/observer/BUILD
index 41db2cc..d7eedab 100644
--- a/src/main/python/apache/thermos/observer/BUILD
+++ b/src/main/python/apache/thermos/observer/BUILD
@@ -14,52 +14,23 @@
 
 import os
 
-python_library(
-  name = 'observed_task',
-  sources = ['observed_task.py'],
-  dependencies = [
-    '3rdparty/python:pystachio',
-    '3rdparty/python:twitter.common.lang',
-    '3rdparty/python:twitter.common.log',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-    'src/main/python/apache/thermos/common:ckpt',
-    'src/main/python/apache/thermos/common:path',
-    'src/main/python/apache/thermos/config',
-  ]
-)
 
 python_library(
-  name = 'detector',
-  sources = ['detector.py'],
-  dependencies = [
-    'src/main/python/apache/thermos/monitoring:detector',
-  ]
-)
-
-
-python_library(
-  name = 'task_observer',
-  sources = ['task_observer.py'],
+  name = 'observer',
+  sources = rglobs('*.py'),
+  resources = zglobs('**/assets/*') + rglobs('*.tpl'),
   dependencies = [
-    ':detector',
-    ':observed_task',
+    '3rdparty/python:bottle',
+    '3rdparty/python:mako',
+    '3rdparty/python:pex',
+    '3rdparty/python:pystachio',
     '3rdparty/python:twitter.common.exceptions',
+    '3rdparty/python:twitter.common.http',
     '3rdparty/python:twitter.common.lang',
     '3rdparty/python:twitter.common.log',
+    '3rdparty/python:twitter.common.metrics',
     '3rdparty/python:twitter.common.quantity',
-    'src/main/python/apache/thermos/common:path',
-    'src/main/python/apache/thermos/monitoring:monitor',
-    'src/main/python/apache/thermos/monitoring:process',
-    'src/main/python/apache/thermos/monitoring:resource',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
-  ]
-)
-
-python_library(
-  name = 'observer',
-  dependencies = [
-    ':task_observer',
-    'src/main/python/apache/thermos/observer/http:http_observer',
+    'api/src/main/thrift/org/apache/thermos',
 
     # covering libraries
     'src/main/python/apache/thermos/common',
@@ -69,8 +40,6 @@ python_library(
   provides = setup_py(
     name = 'apache.thermos.observer',
     version = open(os.path.join(get_buildroot(), '.auroraversion')).read().strip().upper(),
-    description = 'The Thermos observer web interface.',
-  ).with_binaries(
-    thermos_observer = 'src/main/python/apache/thermos/observer/bin:thermos_observer',
-  )
+    description = 'The Thermos observer web interface libraries.',
+  ),
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/observer/bin/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/observer/bin/BUILD b/src/main/python/apache/thermos/observer/bin/BUILD
deleted file mode 100644
index 0abe2cc..0000000
--- a/src/main/python/apache/thermos/observer/bin/BUILD
+++ /dev/null
@@ -1,28 +0,0 @@
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-python_binary(
-  name = 'thermos_observer',
-  source = 'thermos_observer.py',
-  entry_point = 'apache.thermos.observer.bin.thermos_observer:run',
-  dependencies = [
-    '3rdparty/python:CherryPy',
-    '3rdparty/python:twitter.common.app',
-    '3rdparty/python:twitter.common.exceptions',
-    'src/main/python/apache/thermos/common:constants',
-    'src/main/python/apache/thermos/monitoring:detector',
-    'src/main/python/apache/thermos/observer/http:configure',
-    'src/main/python/apache/thermos/observer:task_observer',
-  ],
-)

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/observer/bin/__init__.py
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/observer/bin/__init__.py b/src/main/python/apache/thermos/observer/bin/__init__.py
deleted file mode 100644
index 0663a9a..0000000
--- a/src/main/python/apache/thermos/observer/bin/__init__.py
+++ /dev/null
@@ -1,13 +0,0 @@
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/observer/bin/thermos_observer.py
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/observer/bin/thermos_observer.py b/src/main/python/apache/thermos/observer/bin/thermos_observer.py
deleted file mode 100644
index 39d3994..0000000
--- a/src/main/python/apache/thermos/observer/bin/thermos_observer.py
+++ /dev/null
@@ -1,59 +0,0 @@
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-from __future__ import print_function
-
-import time
-
-from twitter.common import app
-from twitter.common.exceptions import ExceptionalThread
-
-from apache.thermos.common.constants import DEFAULT_CHECKPOINT_ROOT
-from apache.thermos.monitoring.detector import FixedPathDetector
-from apache.thermos.observer.http.configure import configure_server
-from apache.thermos.observer.task_observer import TaskObserver
-
-app.add_option("--root",
-               dest="root",
-               metavar="DIR",
-               default=DEFAULT_CHECKPOINT_ROOT,
-               help="root checkpoint directory for thermos task runners")
-
-
-app.add_option("--port",
-               dest="port",
-               metavar="INT",
-               default=1338,
-               help="port number to listen on.")
-
-
-def sleep_forever():
-  while True:
-    time.sleep(1)
-
-
-def run():
-  def main(_, opts):
-    path_detector = FixedPathDetector(opts.root)
-    task_observer = TaskObserver(path_detector)
-    task_observer.start()
-    server = configure_server(task_observer)
-
-    thread = ExceptionalThread(target=lambda: server.run('0.0.0.0', opts.port, 'cherrypy'))
-    thread.daemon = True
-    thread.start()
-
-    sleep_forever()
-
-  app.main()

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/observer/http/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/observer/http/BUILD b/src/main/python/apache/thermos/observer/http/BUILD
deleted file mode 100644
index 0bd77045..0000000
--- a/src/main/python/apache/thermos/observer/http/BUILD
+++ /dev/null
@@ -1,90 +0,0 @@
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-python_library(
-  name = 'json',
-  sources = ['json.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.http',
-  ]
-)
-
-python_library(
-  name = 'static_assets',
-  sources = ['static_assets.py'],
-  resources = rglobs('assets/*'),
-  dependencies = [
-    '3rdparty/python:bottle',
-  ]
-)
-
-python_library(
-  name = 'templating',
-  sources = ['templating.py'],
-  resources = globs('templates/*.tpl'),
-)
-
-python_library(
-  name = 'diagnostics',
-  sources = ['diagnostics.py'],
-  dependencies = [
-    '3rdparty/python:pex',
-    '3rdparty/python:twitter.common.metrics',
-  ]
-)
-
-python_library(
-  name = 'vars_endpoint',
-  sources = ['vars_endpoint.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.http',
-    '3rdparty/python:twitter.common.metrics',
-  ]
-)
-
-python_library(
-  name = 'configure',
-  sources = ['configure.py'],
-  dependencies = [
-    '3rdparty/python:twitter.common.http',
-    ':diagnostics',
-    ':http_observer',
-    ':vars_endpoint',
-  ]
-)
-
-python_library(
-  name = 'file_browser',
-  sources = ['file_browser.py'],
-  dependencies = [
-    ':templating',
-    '3rdparty/python:bottle',
-    '3rdparty/python:mako',
-    '3rdparty/python:twitter.common.log',
-    '3rdparty/python:twitter.common.http',
-  ]
-)
-
-python_library(
-  name = 'http_observer',
-  sources = ['__init__.py', 'http_observer.py'],
-  dependencies = [
-    ':file_browser',
-    ':json',
-    ':static_assets',
-    ':templating',
-    '3rdparty/python:twitter.common.log',
-    '3rdparty/python:twitter.common.http',
-  ]
-)

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/runner/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/runner/BUILD b/src/main/python/apache/thermos/runner/BUILD
new file mode 100644
index 0000000..085b6ce
--- /dev/null
+++ b/src/main/python/apache/thermos/runner/BUILD
@@ -0,0 +1,48 @@
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+import os
+
+
+python_library(
+  name = '_runner',
+  sources = rglobs('*.py'),
+  dependencies = [
+    '3rdparty/python:twitter.common.app',
+    '3rdparty/python:twitter.common.log',
+    'src/main/python/apache/thermos/common',
+    'src/main/python/apache/thermos/config',
+    'src/main/python/apache/thermos/core',
+  ],
+)
+
+python_library(
+  name = 'runner',
+  dependencies = [
+    ':_runner',
+  ],
+  provides = setup_py(
+    name = 'apache.thermos.runner',
+    version = open(os.path.join(get_buildroot(), '.auroraversion')).read().strip().upper(),
+  ).with_binaries(
+    thermos_runner = ':thermos_runner',
+  ),
+)
+
+python_binary(
+  name = 'thermos_runner',
+  entry_point = 'apache.thermos.runner.thermos_runner',
+  dependencies = [
+    ':_runner',
+  ],
+)

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/runner/__init__.py
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/runner/__init__.py b/src/main/python/apache/thermos/runner/__init__.py
new file mode 100644
index 0000000..0663a9a
--- /dev/null
+++ b/src/main/python/apache/thermos/runner/__init__.py
@@ -0,0 +1,13 @@
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/runner/thermos_runner.py
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/runner/thermos_runner.py b/src/main/python/apache/thermos/runner/thermos_runner.py
new file mode 100644
index 0000000..bd8cf7f
--- /dev/null
+++ b/src/main/python/apache/thermos/runner/thermos_runner.py
@@ -0,0 +1,203 @@
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+import functools
+import getpass
+import os
+import pwd
+import signal
+import sys
+import traceback
+
+from twitter.common import app, log
+
+from apache.thermos.common.options import add_port_to
+from apache.thermos.common.planner import TaskPlanner
+from apache.thermos.common.statuses import (
+    INTERNAL_ERROR,
+    INVALID_TASK,
+    TERMINAL_TASK,
+    UNKNOWN_ERROR,
+    UNKNOWN_USER
+)
+from apache.thermos.config.loader import ThermosConfigLoader
+from apache.thermos.core.process import Process
+from apache.thermos.core.runner import TaskRunner
+
+app.add_option(
+    "--thermos_json",
+    dest="thermos_json",
+    default=None,
+    help="read a thermos Task from a serialized json blob")
+
+
+app.add_option(
+    "--sandbox",
+    dest="sandbox",
+    metavar="PATH",
+    default=None,
+    help="the sandbox in which this task should run")
+
+
+app.add_option(
+     "--checkpoint_root",
+     dest="checkpoint_root",
+     metavar="PATH",
+     default=None,
+     help="the path where we will store checkpoints")
+
+
+app.add_option(
+     "--task_id",
+     dest="task_id",
+     metavar="STRING",
+     default=None,
+     help="The id to which this task should be bound, created if it does not exist.")
+
+
+app.add_option(
+     "--setuid",
+     dest="setuid",
+     metavar="USER",
+     default=None,
+     help="setuid tasks to this user, requires superuser privileges.")
+
+
+app.add_option(
+     "--enable_chroot",
+     dest="chroot",
+     default=False,
+     action='store_true',
+     help="chroot tasks to the sandbox before executing them.")
+
+
+app.add_option(
+     "--port",
+     type='string',
+     nargs=1,
+     action='callback',
+     callback=add_port_to('prebound_ports'),
+     dest='prebound_ports',
+     default={},
+     metavar="NAME:PORT",
+     help="bind a numbered port PORT to name NAME")
+
+
+app.add_option(
+    "--hostname",
+    default=None,
+    dest="hostname",
+    help="The hostname to advertise in ZooKeeper and the thermos observer instead of "
+         "the locally-resolved hostname.")
+
+
+def get_task_from_options(opts):
+  tasks = ThermosConfigLoader.load_json(opts.thermos_json)
+  if len(tasks.tasks()) == 0:
+    app.error("No tasks specified!")
+  if len(tasks.tasks()) > 1:
+    app.error("Multiple tasks in config but no task name specified!")
+  task = tasks.tasks()[0]
+  if not task.task.check().ok():
+    app.error(task.task.check().message())
+  return task
+
+
+def runner_teardown(runner, sig=signal.SIGUSR1, frame=None):
+  """Destroy runner on SIGUSR1 (kill) or SIGUSR2 (lose)"""
+  op = 'kill' if sig == signal.SIGUSR1 else 'lose'
+  log.info('Thermos runner got signal %s, shutting down.' % sig)
+  log.info('Interrupted frame:')
+  if frame:
+    for line in ''.join(traceback.format_stack(frame)).splitlines():
+      log.info(line)
+  runner.close_ckpt()
+  log.info('Calling runner.%s()' % op)
+  getattr(runner, op)()
+  sys.exit(0)
+
+
+class CappedTaskPlanner(TaskPlanner):
+  TOTAL_RUN_LIMIT = 100
+
+
+def proxy_main(args, opts):
+  assert opts.thermos_json and os.path.exists(opts.thermos_json)
+  assert opts.sandbox
+  assert opts.checkpoint_root
+
+  thermos_task = get_task_from_options(opts)
+  prebound_ports = opts.prebound_ports
+  missing_ports = set(thermos_task.ports()) - set(prebound_ports)
+
+  if missing_ports:
+    log.error('ERROR!  Unbound ports: %s' % ' '.join(port for port in missing_ports))
+    sys.exit(INTERNAL_ERROR)
+
+  if opts.setuid:
+    user = opts.setuid
+  else:
+    user = getpass.getuser()
+
+  # if we cannot get the uid, this is an unknown user and we should fail
+  try:
+    pwd.getpwnam(user).pw_uid
+  except KeyError:
+    log.error('Unknown user: %s' % user)
+    sys.exit(UNKNOWN_USER)
+
+  task_runner = TaskRunner(
+      thermos_task.task,
+      opts.checkpoint_root,
+      opts.sandbox,
+      task_id=opts.task_id,
+      user=opts.setuid,
+      portmap=prebound_ports,
+      chroot=opts.chroot,
+      planner_class=CappedTaskPlanner,
+      hostname=opts.hostname,
+  )
+
+  for sig in (signal.SIGUSR1, signal.SIGUSR2):
+    signal.signal(sig, functools.partial(runner_teardown, task_runner))
+
+  try:
+    task_runner.run()
+  except TaskRunner.InternalError as err:
+    log.error('Internal error: %s' % err)
+    sys.exit(INTERNAL_ERROR)
+  except TaskRunner.InvalidTask as err:
+    log.error('Invalid task: %s' % err)
+    sys.exit(INVALID_TASK)
+  except TaskRunner.StateError as err:
+    log.error('Checkpoint error: %s' % err)
+    sys.exit(TERMINAL_TASK)
+  except Process.UnknownUserError as err:
+    log.error('User ceased to exist: %s' % err)
+    sys.exit(UNKNOWN_USER)
+  except KeyboardInterrupt:
+    log.info('Caught ^C, tearing down runner.')
+    runner_teardown(task_runner)
+  except Exception as e:
+    log.error('Unknown exception: %s' % e)
+    for line in traceback.format_exc().splitlines():
+      log.error(line)
+    sys.exit(UNKNOWN_ERROR)
+
+
+def main(args, opts):
+  return proxy_main(args, opts)
+
+
+app.main()

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/main/python/apache/thermos/testing/BUILD
----------------------------------------------------------------------
diff --git a/src/main/python/apache/thermos/testing/BUILD b/src/main/python/apache/thermos/testing/BUILD
index 8b5f6dc..2426170 100644
--- a/src/main/python/apache/thermos/testing/BUILD
+++ b/src/main/python/apache/thermos/testing/BUILD
@@ -13,16 +13,16 @@
 #
 
 python_library(
-  name = 'runner',
-  sources = ['runner.py'],
+  name = 'testing',
+  sources = rglobs('*.py'),
   dependencies = [
     '3rdparty/python:thrift',
     '3rdparty/python:twitter.common.contextutil',
     '3rdparty/python:twitter.common.log',
-    'src/main/python/apache/thermos/common:ckpt',
-    'src/main/python/apache/thermos/common:path',
+    'src/main/python/apache/thermos/common',
     'src/main/python/apache/thermos/config',
     'src/main/python/apache/thermos/core',
-    'api/src/main/thrift/org/apache/thermos:py-thrift',
+    'api/src/main/thrift/org/apache/thermos',
   ]
+  # NOTE: This is not exported as a setup-py because it's only depended-on by test code.
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/BUILD b/src/test/python/apache/aurora/BUILD
index c2251ce..7db8b0e 100644
--- a/src/test/python/apache/aurora/BUILD
+++ b/src/test/python/apache/aurora/BUILD
@@ -28,7 +28,7 @@ python_library(
   name = 'api_util',
   sources = [ 'api_util.py' ],
   dependencies = [
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
-    'src/main/python/apache/aurora/client/api:scheduler_client',
+    'api/src/main/thrift/org/apache/aurora/gen',
+    'src/main/python/apache/aurora/client',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/admin/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/admin/BUILD b/src/test/python/apache/aurora/admin/BUILD
index 69da2c9..d401045 100644
--- a/src/test/python/apache/aurora/admin/BUILD
+++ b/src/test/python/apache/aurora/admin/BUILD
@@ -31,8 +31,8 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/admin:admin',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/admin',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ],
 )
 
@@ -43,10 +43,10 @@ python_tests(name = 'host_maintenance',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.log',
     '3rdparty/python:twitter.common.quantity',
-    'src/main/python/apache/aurora/client:api',
-    'src/main/python/apache/aurora/common:cluster',
-    'src/main/python/apache/aurora/admin:host_maintenance',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/admin',
+    'src/main/python/apache/aurora/client',
+    'src/main/python/apache/aurora/common',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ],
 )
 
@@ -58,7 +58,7 @@ python_tests(
   dependencies = [
     ':util',
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/admin:maintenance',
+    'src/main/python/apache/aurora/admin',
   ],
 )
 
@@ -67,9 +67,8 @@ python_library(
   sources = [ 'util.py' ],
   dependencies = [
     '3rdparty/python:mock',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
-    'src/main/python/apache/aurora/client/hooks:hooks',
-    'src/main/python/apache/aurora/client:config',
+    'api/src/main/thrift/org/apache/aurora/gen',
+    'src/main/python/apache/aurora/client',
     'src/test/python/apache/aurora:api_util',
   ],
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/client/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/client/BUILD b/src/test/python/apache/aurora/client/BUILD
index c55adfe..dc7912e 100644
--- a/src/test/python/apache/aurora/client/BUILD
+++ b/src/test/python/apache/aurora/client/BUILD
@@ -29,7 +29,7 @@ python_tests(
   dependencies = [
     '3rdparty/python:pystachio',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client:binding_helper',
+    'src/main/python/apache/aurora/client',
     'src/main/python/apache/aurora/config',
   ],
 )
@@ -37,7 +37,7 @@ python_tests(
 python_tests(name = 'base',
   sources = ['test_base.py'],
   dependencies = [
-    'src/main/python/apache/aurora/client:base',
+    'src/main/python/apache/aurora/client',
   ],
 )
 
@@ -45,7 +45,7 @@ python_tests(name = 'config',
   sources = ['test_config.py'],
   dependencies = [
     '3rdparty/python:mox',
-    'src/main/python/apache/aurora/client:config',
+    'src/main/python/apache/aurora/client',
   ],
 )
 
@@ -53,6 +53,6 @@ python_library(
   name = 'fake_scheduler_proxy',
   sources = ['fake_scheduler_proxy.py'],
   dependencies = [
-    'src/main/python/apache/aurora/client/api:scheduler_client',
+    'src/main/python/apache/aurora/client',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/client/api/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/client/api/BUILD b/src/test/python/apache/aurora/client/api/BUILD
index 65b378b..c375ae9 100644
--- a/src/test/python/apache/aurora/client/api/BUILD
+++ b/src/test/python/apache/aurora/client/api/BUILD
@@ -32,9 +32,8 @@ python_tests(name = 'api',
   sources = ['test_api.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/client/api:api',
-    'src/main/python/apache/aurora/client:config',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift'
+    'src/main/python/apache/aurora/client',
+    'api/src/main/thrift/org/apache/aurora/gen'
   ],
 )
 
@@ -42,9 +41,8 @@ python_tests(name = 'job_monitor',
   sources = ['test_job_monitor.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/client/api:api',
-    'src/main/python/apache/aurora/client/api:job_monitor',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/client',
+    'api/src/main/thrift/org/apache/aurora/gen',
     'src/test/python/apache/aurora/client:fake_scheduler_proxy',
   ],
 )
@@ -53,15 +51,15 @@ python_tests(name = 'instance_watcher',
   sources = ['test_instance_watcher.py', 'test_health_check.py'],
   dependencies = [
     '3rdparty/python:mox',
-    'src/main/python/apache/aurora/client/api:instance_watcher',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/client',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ]
 )
 
 python_tests(name = 'mux',
   sources = ['test_scheduler_mux.py'],
   dependencies = [
-    'src/main/python/apache/aurora/client/api:scheduler_mux',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -69,8 +67,8 @@ python_tests(name = 'quota_check',
   sources = ['test_quota_check.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/client/api:quota_check',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/client',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ]
 )
 
@@ -78,9 +76,9 @@ python_tests(name = 'restarter',
   sources = ['test_restarter.py'],
   dependencies = [
     '3rdparty/python:mox',
-    'src/main/python/apache/aurora/client/api:restarter',
-    'src/main/python/apache/aurora/common:aurora_job_key',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/client',
+    'src/main/python/apache/aurora/common',
+    'api/src/main/thrift/org/apache/aurora/gen',
     'src/test/python/apache/aurora/client:fake_scheduler_proxy',
   ],
 )
@@ -90,8 +88,8 @@ python_tests(name = 'scheduler_client',
   dependencies = [
     '3rdparty/python:mock',
     '3rdparty/python:mox',
-    'src/main/python/apache/aurora/client/api:scheduler_client',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/client',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ]
 )
 
@@ -99,8 +97,8 @@ python_tests(name = 'sla',
   sources = ['test_sla.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/client/api:sla',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/client',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ]
 )
 
@@ -108,9 +106,8 @@ python_tests(name = 'task_util',
   sources = ['test_task_util.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/client/api:scheduler_client',
-    'src/main/python/apache/aurora/client/api:task_util',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/client',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ]
 )
 
@@ -118,9 +115,9 @@ python_tests(name = 'updater',
   sources = ['test_updater.py'],
   dependencies = [
     '3rdparty/python:mox',
-    'src/main/python/apache/aurora/common:aurora_job_key',
-    'src/main/python/apache/aurora/client/api:updater',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/common',
+    'src/main/python/apache/aurora/client',
+    'api/src/main/thrift/org/apache/aurora/gen',
     'src/test/python/apache/aurora/client:fake_scheduler_proxy',
   ]
 )
@@ -128,7 +125,7 @@ python_tests(name = 'updater',
 python_tests(name = 'updater_util',
   sources = ['test_updater_util.py'],
   dependencies = [
-    'src/main/python/apache/aurora/client/api:api',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift'
+    'src/main/python/apache/aurora/client',
+    'api/src/main/thrift/org/apache/aurora/gen'
   ],
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/client/cli/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/client/cli/BUILD b/src/test/python/apache/aurora/client/cli/BUILD
index 0d85f5f..36fd98a 100644
--- a/src/test/python/apache/aurora/client/cli/BUILD
+++ b/src/test/python/apache/aurora/client/cli/BUILD
@@ -39,7 +39,7 @@ python_library(
   sources = [ 'util.py' ],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/client/cli',
+    'src/main/python/apache/aurora/client',
     'src/test/python/apache/aurora:api_util',
   ]
 )
@@ -51,8 +51,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -63,8 +62,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -75,8 +73,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -87,8 +84,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -100,8 +96,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -112,8 +107,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -132,8 +126,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -146,8 +139,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -159,8 +151,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -171,8 +162,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -183,8 +173,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -195,8 +184,7 @@ python_tests(
     ':util',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/client/cli',
-    'src/main/python/apache/aurora/client/cli:client_lib',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -204,7 +192,7 @@ python_tests(
   name = 'client',
   sources = [ 'test_client.py' ],
   dependencies = [
-    'src/main/python/apache/aurora/client/cli',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -213,7 +201,7 @@ python_tests(
   sources = [ 'test_version.py' ],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/client/cli',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -222,7 +210,7 @@ python_tests(
   sources = [ 'test_context.py' ],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/client/cli',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
@@ -230,6 +218,6 @@ python_tests(
   name = 'options',
   sources = [ 'test_options.py' ],
   dependencies = [
-    'src/main/python/apache/aurora/client/cli',
+    'src/main/python/apache/aurora/client',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/client/hooks/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/client/hooks/BUILD b/src/test/python/apache/aurora/client/hooks/BUILD
index 0b924cc..ae97ebf 100644
--- a/src/test/python/apache/aurora/client/hooks/BUILD
+++ b/src/test/python/apache/aurora/client/hooks/BUILD
@@ -23,16 +23,15 @@ python_tests(name = 'hooked_api',
   sources = ['test_hooked_api.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/common:cluster',
-    'src/main/python/apache/aurora/client:api',
-    'src/main/python/apache/aurora/client/hooks',
+    'src/main/python/apache/aurora/common',
+    'src/main/python/apache/aurora/client',
   ]
 )
 
 python_tests(name = 'non_hooked_api',
   sources = ['test_non_hooked_api.py'],
   dependencies = [
-    'src/main/python/apache/aurora/common:aurora_job_key',
-    'src/main/python/apache/aurora/client/hooks',
+    'src/main/python/apache/aurora/common',
+    'src/main/python/apache/aurora/client',
   ],
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/common/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/common/BUILD b/src/test/python/apache/aurora/common/BUILD
index 9b1d4d8..2556c32 100644
--- a/src/test/python/apache/aurora/common/BUILD
+++ b/src/test/python/apache/aurora/common/BUILD
@@ -29,7 +29,7 @@ python_test_suite(
 python_tests(name = 'test_aurora_job_key',
   sources = ['test_aurora_job_key.py'],
   dependencies = [
-    'src/main/python/apache/aurora/common:aurora_job_key'
+    'src/main/python/apache/aurora/common'
   ],
 )
 
@@ -38,7 +38,7 @@ python_tests(
   sources = ['test_pex_version.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/common:pex_version',
+    'src/main/python/apache/aurora/common',
   ]
 )
 
@@ -46,7 +46,7 @@ python_tests(
   name = 'test_cluster',
   sources = ['test_cluster.py'],
   dependencies = [
-    'src/main/python/apache/aurora/common:cluster',
+    'src/main/python/apache/aurora/common',
   ]
 )
 
@@ -55,7 +55,7 @@ python_tests(
   sources = ['test_clusters.py'],
   dependencies = [
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/common:clusters',
+    'src/main/python/apache/aurora/common',
   ]
 )
 
@@ -64,9 +64,7 @@ python_tests(
   sources = ['test_cluster_option.py'],
   dependencies = [
     '3rdparty/python:twitter.common.options',
-    'src/main/python/apache/aurora/common:cluster',
-    'src/main/python/apache/aurora/common:cluster_option',
-    'src/main/python/apache/aurora/common:clusters',
+    'src/main/python/apache/aurora/common',
   ]
 )
 
@@ -75,7 +73,7 @@ python_tests(
   sources = ['test_http_signaler.py'],
   dependencies = [
     '3rdparty/python:mox',
-    'src/main/python/apache/aurora/common:http_signaler',
+    'src/main/python/apache/aurora/common',
   ]
 )
 
@@ -83,7 +81,7 @@ python_tests(
   name = 'test_shellify',
   sources = ['test_shellify.py'],
   dependencies = [
-    'src/main/python/apache/aurora/common:shellify',
+    'src/main/python/apache/aurora/common',
   ]
 )
 
@@ -91,8 +89,8 @@ python_tests(
   name = 'test_transport',
   sources = ['test_transport.py'],
   dependencies = [
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
-    'src/main/python/apache/aurora/common:transport',
+    'api/src/main/thrift/org/apache/aurora/gen',
+    'src/main/python/apache/aurora/common',
     '3rdparty/python:mock',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/config/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/config/BUILD b/src/test/python/apache/aurora/config/BUILD
index c85e998..92bc680 100644
--- a/src/test/python/apache/aurora/config/BUILD
+++ b/src/test/python/apache/aurora/config/BUILD
@@ -52,6 +52,6 @@ python_tests(name = 'test_thrift',
   sources = ['test_thrift.py'],
   dependencies = [
     'src/main/python/apache/aurora/config',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift-test',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/executor/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/executor/BUILD b/src/test/python/apache/aurora/executor/BUILD
index 8fff66e..1c97375 100644
--- a/src/test/python/apache/aurora/executor/BUILD
+++ b/src/test/python/apache/aurora/executor/BUILD
@@ -48,16 +48,11 @@ python_tests(name = 'thermos_executor',
     '3rdparty/python:twitter.common.app',
     '3rdparty/python:twitter.common.exceptions',
     '3rdparty/python:twitter.common.quantity',
+    'api/src/main/thrift/org/apache/aurora/gen',
+    'src/main/python/apache/aurora/config',
+    'src/main/python/apache/aurora/executor',
     'src/main/python/apache/thermos/core',
-    'src/main/python/apache/thermos/monitoring:monitor',
-    'src/main/python/apache/aurora/config:schema',
-    'src/main/python/apache/aurora/executor/common:executor_timeout',
-    'src/main/python/apache/aurora/executor/common:health_checker',
-    'src/main/python/apache/aurora/executor/common:sandbox',
-    'src/main/python/apache/aurora/executor/common:task_runner',
-    'src/main/python/apache/aurora/executor:aurora_executor',
-    'src/main/python/apache/aurora/executor:thermos_task_runner',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/thermos/monitoring',
   ]
 )
 
@@ -70,9 +65,8 @@ python_tests(name = 'thermos_task_runner',
     '3rdparty/python:twitter.common.dirutil',
     '3rdparty/python:twitter.common.log',
     '3rdparty/python:twitter.common.quantity',
-    'src/main/python/apache/aurora/config:schema',
-    'src/main/python/apache/aurora/executor/common:sandbox',
-    'src/main/python/apache/aurora/executor:thermos_task_runner',
+    'src/main/python/apache/aurora/config',
+    'src/main/python/apache/aurora/executor',
   ]
 )
 
@@ -82,7 +76,7 @@ python_tests(name = 'executor_base',
     '3rdparty/python:mesos.interface',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.log',
-    'src/main/python/apache/aurora/executor:executor_base',
+    'src/main/python/apache/aurora/executor',
   ],
 )
 
@@ -91,8 +85,7 @@ python_tests(name = 'status_manager',
   dependencies = [
     '3rdparty/python:mesos.interface',
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/executor:status_manager',
-    'src/main/python/apache/aurora/executor/common:status_checker',
+    'src/main/python/apache/aurora/executor',
   ],
 )
 
@@ -101,7 +94,7 @@ python_tests(name = 'executor_vars',
   dependencies = [
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/executor:executor_vars',
+    'src/main/python/apache/aurora/executor',
   ]
 )
 
@@ -109,8 +102,7 @@ python_tests(name = 'http_lifecycle',
   sources = ['test_http_lifecycle.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/config:schema',
-    'src/main/python/apache/aurora/executor:http_lifecycle',
-    'src/main/python/apache/aurora/executor:thermos_task_runner',
+    'src/main/python/apache/aurora/config',
+    'src/main/python/apache/aurora/executor',
   ],
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/executor/bin/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/executor/bin/BUILD b/src/test/python/apache/aurora/executor/bin/BUILD
index 713ce95..c3b538c 100644
--- a/src/test/python/apache/aurora/executor/bin/BUILD
+++ b/src/test/python/apache/aurora/executor/bin/BUILD
@@ -24,6 +24,6 @@ python_tests(
   sources = ['test_thermos_executor_entry_point.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/executor/bin:thermos_executor_source',
+    'src/main/python/apache/aurora/executor',
   ],
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/executor/common/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/executor/common/BUILD b/src/test/python/apache/aurora/executor/common/BUILD
index b3da27b..7dafebf 100644
--- a/src/test/python/apache/aurora/executor/common/BUILD
+++ b/src/test/python/apache/aurora/executor/common/BUILD
@@ -32,7 +32,7 @@ python_tests(name = 'executor_detector',
   dependencies = [
     '3rdparty/python:twitter.common.contextutil',
     '3rdparty/python:twitter.common.dirutil',
-    'src/main/python/apache/aurora/executor/common:executor_detector'
+    'src/main/python/apache/aurora/executor',
   ]
 )
 
@@ -40,8 +40,7 @@ python_tests(name = 'path_detector',
   sources = [ 'test_path_detector.py' ],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/executor/common:executor_detector',
-    'src/main/python/apache/aurora/executor/common:path_detector',
+    'src/main/python/apache/aurora/executor',
   ]
 )
 
@@ -49,8 +48,8 @@ python_library(
   name = 'fixtures',
   sources = ['fixtures.py'],
   dependencies = [
-    'src/main/python/apache/aurora/config/schema',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/config',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ],
 )
 
@@ -61,7 +60,7 @@ python_tests(
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.quantity',
     '3rdparty/python:twitter.common.testing',
-    'src/main/python/apache/aurora/executor/common:announcer',
+    'src/main/python/apache/aurora/executor',
   ],
 )
 
@@ -71,7 +70,7 @@ python_tests(
   dependencies = [
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/aurora/executor/common:sandbox',
+    'src/main/python/apache/aurora/executor',
   ],
 )
 
@@ -83,10 +82,9 @@ python_tests(
     '3rdparty/python:mesos.interface',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.testing',
-    'src/main/python/apache/aurora/common:http_signaler',
-    'src/main/python/apache/aurora/executor/common:health_checker',
-    'src/main/python/apache/aurora/executor/common:sandbox',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/common',
+    'src/main/python/apache/aurora/executor',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ]
 )
 
@@ -95,7 +93,7 @@ python_tests(
   sources = ['test_status_checker.py'],
   dependencies = [
     '3rdparty/python:mesos.interface',
-    'src/main/python/apache/aurora/executor/common:status_checker',
+    'src/main/python/apache/aurora/executor',
   ]
 )
 
@@ -104,8 +102,7 @@ python_tests(
   sources = ['test_kill_manager.py'],
   dependencies = [
     '3rdparty/python:mesos.interface',
-    'src/main/python/apache/aurora/executor/common:kill_manager',
-    'src/main/python/apache/aurora/executor/common:status_checker',
+    'src/main/python/apache/aurora/executor',
   ],
 )
 
@@ -114,8 +111,8 @@ python_tests(
   sources = ['test_task_info.py'],
   dependencies = [
     ':fixtures',
-    'src/main/python/apache/aurora/executor/common:task_info',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
+    'src/main/python/apache/aurora/executor',
+    'api/src/main/thrift/org/apache/aurora/gen',
   ]
 )
 
@@ -126,7 +123,7 @@ python_tests(
     '3rdparty/python:mesos.interface',
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.quantity',
-    'src/main/python/apache/aurora/executor/common:executor_timeout',
+    'src/main/python/apache/aurora/executor',
   ],
 )
 
@@ -135,8 +132,8 @@ python_tests(
   sources = [ 'test_resource_manager.py' ],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/aurora/config:schema',
-    'src/main/python/apache/aurora/executor/common:resource_manager',
+    'src/main/python/apache/aurora/config',
+    'src/main/python/apache/aurora/executor',
     'src/main/python/apache/thermos/config',
     'src/main/python/apache/thermos/monitoring',
   ]
@@ -150,10 +147,9 @@ python_tests(
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
     '3rdparty/python:twitter.common.dirutil',
-    'api/src/main/thrift/org/apache/aurora/gen:py-thrift',
-    'src/main/python/apache/aurora/config:schema',
-    'src/main/python/apache/aurora/executor/common:sandbox',
-    'src/main/python/apache/aurora/executor/common:resource_manager',
-    'src/main/python/apache/thermos/core:helper',
+    'api/src/main/thrift/org/apache/aurora/gen',
+    'src/main/python/apache/aurora/config',
+    'src/main/python/apache/aurora/executor',
+    'src/main/python/apache/thermos/core',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/executor/test_thermos_executor.py
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/executor/test_thermos_executor.py b/src/test/python/apache/aurora/executor/test_thermos_executor.py
index c3baa9f..d24c611 100644
--- a/src/test/python/apache/aurora/executor/test_thermos_executor.py
+++ b/src/test/python/apache/aurora/executor/test_thermos_executor.py
@@ -268,7 +268,7 @@ class TestThermosExecutor(object):
     log.init('executor_logger')
     if not cls.PANTS_BUILT and 'SKIP_PANTS_BUILD' not in os.environ:
       assert subprocess.call(["./pants", "binary",
-          "src/main/python/apache/thermos/bin:thermos_runner"]) == 0
+          "src/main/python/apache/thermos/runner:thermos_runner"]) == 0
       cls.PANTS_BUILT = True
 
   @classmethod

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/aurora/executor/test_thermos_task_runner.py
----------------------------------------------------------------------
diff --git a/src/test/python/apache/aurora/executor/test_thermos_task_runner.py b/src/test/python/apache/aurora/executor/test_thermos_task_runner.py
index cc32656..bb998c0 100644
--- a/src/test/python/apache/aurora/executor/test_thermos_task_runner.py
+++ b/src/test/python/apache/aurora/executor/test_thermos_task_runner.py
@@ -69,7 +69,7 @@ class TestThermosTaskRunnerIntegration(object):
     log.init('executor_logger')
     if not cls.PANTS_BUILT and 'SKIP_PANTS_BUILD' not in os.environ:
       assert subprocess.call(["./pants", "binary",
-          "src/main/python/apache/thermos/bin:thermos_runner"]) == 0
+          "src/main/python/apache/thermos/runner:thermos_runner"]) == 0
       cls.PANTS_BUILT = True
 
   @classmethod

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/thermos/cli/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/thermos/cli/BUILD b/src/test/python/apache/thermos/cli/BUILD
index 087b174..e6284e3 100644
--- a/src/test/python/apache/thermos/cli/BUILD
+++ b/src/test/python/apache/thermos/cli/BUILD
@@ -26,7 +26,7 @@ python_tests(
   sources = ['test_common.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/thermos/cli:common',
+    'src/main/python/apache/thermos/cli',
   ]
 )
 
@@ -34,6 +34,6 @@ python_tests(
   name = 'main',
   sources = ['test_main.py'],
   dependencies = [
-    'src/main/python/apache/thermos/cli:main',
+    'src/main/python/apache/thermos/cli',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/thermos/cli/commands/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/thermos/cli/commands/BUILD b/src/test/python/apache/thermos/cli/commands/BUILD
index 5465b19..7ed1d6c 100644
--- a/src/test/python/apache/thermos/cli/commands/BUILD
+++ b/src/test/python/apache/thermos/cli/commands/BUILD
@@ -17,6 +17,6 @@ python_tests(
   sources = globs('*.py'),
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/thermos/cli/commands',
+    'src/main/python/apache/thermos/cli',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/thermos/common/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/thermos/common/BUILD b/src/test/python/apache/thermos/common/BUILD
index bb70867..7813dbc 100644
--- a/src/test/python/apache/thermos/common/BUILD
+++ b/src/test/python/apache/thermos/common/BUILD
@@ -23,14 +23,14 @@ python_test_suite(name = 'all',
 python_tests(name = 'test_pathspec',
   sources = ['test_pathspec.py'],
   dependencies = [
-    'src/main/python/apache/thermos/common:path',
+    'src/main/python/apache/thermos/common',
   ],
 )
 
 python_tests(name = 'test_planner',
   sources = ['test_planner.py'],
   dependencies = [
-    'src/main/python/apache/thermos/common:planner',
+    'src/main/python/apache/thermos/common',
   ],
 )
 
@@ -38,7 +38,7 @@ python_tests(name = 'test_task_planner',
   sources = ['test_task_planner.py'],
   dependencies = [
     '3rdparty/python:twitter.common.testing',
-    'src/main/python/apache/thermos/common:planner',
-    'src/main/python/apache/thermos/config:schema',
+    'src/main/python/apache/thermos/common',
+    'src/main/python/apache/thermos/config',
   ],
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/thermos/config/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/thermos/config/BUILD b/src/test/python/apache/thermos/config/BUILD
index a06af36..cee0f05 100644
--- a/src/test/python/apache/thermos/config/BUILD
+++ b/src/test/python/apache/thermos/config/BUILD
@@ -22,6 +22,6 @@ python_tests(name = 'test_schema',
   sources = ['test_schema.py'],
   dependencies = [
     '3rdparty/python:twitter.common.collections',
-    'src/main/python/apache/thermos/config:schema'
+    'src/main/python/apache/thermos/config',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/thermos/core/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/thermos/core/BUILD b/src/test/python/apache/thermos/core/BUILD
index d637c24..53cc575 100644
--- a/src/test/python/apache/thermos/core/BUILD
+++ b/src/test/python/apache/thermos/core/BUILD
@@ -47,14 +47,14 @@ python_test_suite(name = 'large',
 python_tests(name = 'test_runner_integration',
   sources = ['test_runner_integration.py'],
   dependencies = [
-    'src/main/python/apache/thermos/testing:runner',
+    'src/main/python/apache/thermos/testing',
   ],
 )
 
 python_tests(name = 'test_angry',
   sources = ['test_angry.py'],
   dependencies = [
-    'src/main/python/apache/thermos/testing:runner',
+    'src/main/python/apache/thermos/testing',
   ],
 #  timeout = Amount(5, Time.MINUTES)
 )
@@ -62,28 +62,28 @@ python_tests(name = 'test_angry',
 python_tests(name = 'test_ephemerals',
   sources = ['test_ephemerals.py'],
   dependencies = [
-    'src/main/python/apache/thermos/testing:runner',
+    'src/main/python/apache/thermos/testing',
   ],
 )
 
 python_tests(name = 'test_failing_runner',
   sources = ['test_failing_runner.py'],
   dependencies = [
-    'src/main/python/apache/thermos/testing:runner',
+    'src/main/python/apache/thermos/testing',
   ],
 )
 
 python_tests(name = 'test_finalization',
   sources = ['test_finalization.py'],
   dependencies = [
-    'src/main/python/apache/thermos/testing:runner',
+    'src/main/python/apache/thermos/testing',
   ],
 )
 
 python_tests(name = 'test_failure_limit',
   sources = ['test_failure_limit.py'],
   dependencies = [
-    'src/main/python/apache/thermos/testing:runner',
+    'src/main/python/apache/thermos/testing',
   ],
 )
 
@@ -92,7 +92,7 @@ python_tests(name = 'test_helper',
   dependencies = [
     '3rdparty/python:mock',
     '3rdparty/python:psutil',
-    'src/main/python/apache/thermos/core:helper',
+    'src/main/python/apache/thermos/core',
   ]
 )
 
@@ -101,7 +101,7 @@ python_tests(name = 'test_process',
   dependencies = [
     '3rdparty/python:mock',
     '3rdparty/python:twitter.common.contextutil',
-    'src/main/python/apache/thermos/testing:runner',
+    'src/main/python/apache/thermos/testing',
   ],
 )
 
@@ -109,7 +109,7 @@ python_tests(name = 'test_staged_kill',
   sources = ['test_staged_kill.py'],
   dependencies = [
      '3rdparty/python:twitter.common.process',
-     'src/main/python/apache/thermos/testing:runner',
-     'src/main/python/apache/thermos/monitoring:monitor',
+     'src/main/python/apache/thermos/testing',
+     'src/main/python/apache/thermos/monitoring',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/thermos/monitoring/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/thermos/monitoring/BUILD b/src/test/python/apache/thermos/monitoring/BUILD
index f4ad7fc..b8d6d2f 100644
--- a/src/test/python/apache/thermos/monitoring/BUILD
+++ b/src/test/python/apache/thermos/monitoring/BUILD
@@ -23,7 +23,7 @@ python_test_suite(name = 'all',
 python_tests(name = 'test_disk',
   sources = ['test_disk.py'],
   dependencies = [
-    'src/main/python/apache/thermos/monitoring:disk',
+    'src/main/python/apache/thermos/monitoring',
     '3rdparty/python:twitter.common.quantity',
   ]
 )
@@ -33,8 +33,8 @@ python_tests(name = 'test_detector',
   dependencies = [
     '3rdparty/python:twitter.common.contextutil',
     '3rdparty/python:twitter.common.dirutil',
-    'src/main/python/apache/thermos/common:constants',
-    'src/main/python/apache/thermos/monitoring:detector',
+    'src/main/python/apache/thermos/common',
+    'src/main/python/apache/thermos/monitoring',
   ]
 )
 
@@ -42,7 +42,7 @@ python_tests(name = 'test_resource',
   sources = ['test_resource.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/thermos/common:path',
-    'src/main/python/apache/thermos/monitoring:resource',
+    'src/main/python/apache/thermos/common',
+    'src/main/python/apache/thermos/monitoring',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/thermos/observer/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/thermos/observer/BUILD b/src/test/python/apache/thermos/observer/BUILD
index ff92a52..34475d2 100644
--- a/src/test/python/apache/thermos/observer/BUILD
+++ b/src/test/python/apache/thermos/observer/BUILD
@@ -25,6 +25,6 @@ python_tests(
   sources = ['test_detector.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/thermos/observer:detector',
+    'src/main/python/apache/thermos/observer',
   ]
 )

http://git-wip-us.apache.org/repos/asf/aurora/blob/8fa4fb0f/src/test/python/apache/thermos/observer/http/BUILD
----------------------------------------------------------------------
diff --git a/src/test/python/apache/thermos/observer/http/BUILD b/src/test/python/apache/thermos/observer/http/BUILD
index 0cdaafc..bdead2c 100644
--- a/src/test/python/apache/thermos/observer/http/BUILD
+++ b/src/test/python/apache/thermos/observer/http/BUILD
@@ -25,8 +25,7 @@ python_tests(
   sources = ['test_file_browser.py'],
   dependencies = [
     '3rdparty/python:mock',
-    'src/main/python/apache/thermos/observer:task_observer',
-    'src/main/python/apache/thermos/monitoring:detector',
-    'src/main/python/apache/thermos/observer/http:file_browser',
+    'src/main/python/apache/thermos/monitoring',
+    'src/main/python/apache/thermos/observer',
   ]
 )


Mime
View raw message