[ARVADOS] updated: bb4eb4d94b2376bc471f9efd71a95fca84f0f011
git at public.curoverse.com
git at public.curoverse.com
Thu Oct 9 13:45:56 EDT 2014
Summary of changes:
services/nodemanager/.gitignore | 1 +
services/nodemanager/README.rst | 35 ++++++++++++++++++++++++++++++++++
services/nodemanager/setup.py | 1 +
services/nodemanager/tests/__init__.py | 16 ++++++++++++++++
services/nodemanager/tests/testutil.py | 4 +++-
5 files changed, 56 insertions(+), 1 deletion(-)
create mode 100644 services/nodemanager/README.rst
via bb4eb4d94b2376bc471f9efd71a95fca84f0f011 (commit)
via f2695a30103f21b43da4443c4843e726769e5efb (commit)
via 4a3cb7560929cb3fe4a7970bb1e307aa7af35712 (commit)
from dd59a50f9f3933c359930806516b43899a8b4957 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
commit bb4eb4d94b2376bc471f9efd71a95fca84f0f011
Author: Brett Smith <brett at curoverse.com>
Date: Thu Oct 9 13:46:51 2014 -0400
4139: Add README to Node Manager.
Refs #4139.
diff --git a/services/nodemanager/README.rst b/services/nodemanager/README.rst
new file mode 100644
index 0000000..4a1b162
--- /dev/null
+++ b/services/nodemanager/README.rst
@@ -0,0 +1,35 @@
+====================
+Arvados Node Manager
+====================
+
+Overview
+--------
+
+This package provides ``arvados-node-manager``. It dynamically starts
+and stops compute nodes on an Arvados_ cloud installation based on job
+demand.
+
+.. _Arvados: https://arvados.org/
+
+Setup
+-----
+
+1. Install the package.
+
+2. Write a configuration file. ``doc/ec2.example.cfg`` documents all
+ of the options available, with specific tunables for EC2 clouds.
+
+3. Run ``arvados-node-manager --config YOURCONFIGFILE`` using whatever
+ supervisor you like (e.g., runit).
+
+Testing and Development
+-----------------------
+
+To run tests, just run::
+
+ python setup.py test
+
+Our `hacking guide
+<https://arvados.org/projects/arvados/wiki/Hacking_Node_Manager>`_
+provides an architectural overview of the Arvados Node Manager to help
+you find your way around the source.
diff --git a/services/nodemanager/setup.py b/services/nodemanager/setup.py
index fabb883..44a35f5 100644
--- a/services/nodemanager/setup.py
+++ b/services/nodemanager/setup.py
@@ -22,6 +22,7 @@ else:
setup(name='arvados-node-manager',
version='0.1',
description='Arvados compute node manager',
+ long_description=open(os.path.join(SETUP_DIR, 'README.rst')).read(),
author='Arvados',
author_email='info at arvados.org',
url="https://arvados.org",
commit f2695a30103f21b43da4443c4843e726769e5efb
Author: Brett Smith <brett at curoverse.com>
Date: Thu Oct 9 13:32:50 2014 -0400
4139: Add *.egg to Node Manager's .gitignore.
`python setup.py test` will automatically download dependencies to the
source directory if you don't already have them available in your
environment. Refs #2881, #4139.
diff --git a/services/nodemanager/.gitignore b/services/nodemanager/.gitignore
index 488ddd5..d6bc7fe 100644
--- a/services/nodemanager/.gitignore
+++ b/services/nodemanager/.gitignore
@@ -1,4 +1,5 @@
*.pyc
+*.egg
*.egg-info
build/
dist/
commit 4a3cb7560929cb3fe4a7970bb1e307aa7af35712
Author: Brett Smith <brett at curoverse.com>
Date: Thu Oct 9 13:31:47 2014 -0400
4139: Add environment configuration knobs for Node Manager tests.
These are settings I've fiddled with regularly over the course of
development, and now it looks like we're going to need to fiddle them
some more to accommodate Jenkins. I'm exposing them as environment
variables so I can stop messing with the code appropriately.
Refs #4139.
diff --git a/services/nodemanager/tests/__init__.py b/services/nodemanager/tests/__init__.py
index e69de29..d374840 100644
--- a/services/nodemanager/tests/__init__.py
+++ b/services/nodemanager/tests/__init__.py
@@ -0,0 +1,16 @@
+#!/usr/bin/env python
+
+import logging
+import os
+
+# Set the ANMTEST_LOGLEVEL environment variable to enable logging at that level.
+loglevel = os.environ.get('ANMTEST_LOGLEVEL', 'CRITICAL')
+logging.basicConfig(level=getattr(logging, loglevel.upper()))
+
+# Many tests wait for an actor to call a mock method. They poll very
+# regularly (see wait_for_call in ActorTestMixin), but if you've
+# broken something, a long timeout can mean you'll spend a lot of time
+# watching failures come in. You can set the ANMTEST_TIMEOUT
+# environment variable to arrange a shorter timeout while you're doing
+# regular development.
+pykka_timeout = int(os.environ.get('ANMTEST_TIMEOUT', '10'))
diff --git a/services/nodemanager/tests/testutil.py b/services/nodemanager/tests/testutil.py
index a33f76f..7d6549d 100644
--- a/services/nodemanager/tests/testutil.py
+++ b/services/nodemanager/tests/testutil.py
@@ -7,6 +7,8 @@ import time
import mock
import pykka
+from . import pykka_timeout
+
no_sleep = mock.patch('time.sleep', lambda n: None)
def arvados_node_mock(node_num=99, job_uuid=None, age=0, **kwargs):
@@ -60,7 +62,7 @@ class MockTimer(object):
class ActorTestMixin(object):
FUTURE_CLASS = pykka.ThreadingFuture
- TIMEOUT = 5
+ TIMEOUT = pykka_timeout
def tearDown(self):
pykka.ActorRegistry.stop_all()
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list