| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implement a periodic task in the ConductorManager which will check all
the existing, non-locked nodes and verify that their current power
states correspond to state stored in DB. If they differ, for now, log a
warning and update the DB using current power state.
This is a step towards keeping powered-off-nodes off.
Also, this removes the unused db.api.get_nodes method
and adds a new get_nodeinfo_list method.
Change-Id: I609fdbd7db6620de617b44f83c7ec35350f9178c
Blueprint: keep-powered-off-nodes-off
|
|
|
|
|
|
|
|
|
| |
Built-in function xrange were used in Python 2 were removed in
Python3. Python3 uses range, we use range() to support both
Python2 and Python3.
Change-Id: Ib4e4f833866ed6653f75e0ace67f1d9fa493babf
Closes-bug: #1256159
|
|
|
|
|
|
|
|
|
| |
SQLite backend used in unit tests, but unique constraint for 'address'
column in 'ports' table not working for this backend. Patch fix this
and also unit tests which violates 'address' UC.
Closes-Bug: #1252343
Change-Id: I761e480c99f1687531cf4c64a64c02faa7e4fb73
|
|
|
|
|
|
|
|
|
|
|
|
| |
uuidutils.generate_uuid() is going to be removed from oslo, so we
need to remove the call from our Ironic code.
http://lists.openstack.org/pipermail/openstack-dev/2013-November/
018980.html
We create new method in our Ironic common utils to wrap the
generate_uuid methods.
Change-Id: I7bc4ca8fcdb29c4ee5b3e7fc7afb0235812a1c0d
Partial-Bug: #1253497
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
79e6bc6 fix lockutils.lock() to make it thread-safe
ace5120 Add main() to lockutils that creates temp dir for locks
537d8e2 Allow lockutils to get lock_path conf from envvar
d498c42 Fix to properly log when we release a semaphore
29d387c Add LockFixture to lockutils
3e3ac0c Modify lockutils.py due to dispose of eventlet
90b6a65 Fix locking bug
27d4b41 Move synchronized body to a first-class function
15c17fb Make lock_file_prefix optional
1a2df89 Enable H302 hacking check
b41862d Use param keyword for docstrings
Change-Id: Id604ae4188ebf822746e229165e7fcdb78a66f96
|
|\ \ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Made these changes:
* power_state -- always represents current power state.
Any power operation sets this back to "actual" when done
(whether successful or not). It is set to ERROR only when
unable to get the power state from a node.
* target_power_state -- represents the requested destination
of a state transition. Cleared when the transition window is
over (whether successful or not).
* last_error -- string field used to store the last error from
any requested asynchronous operation (eg, whether that was to
change power state, or deploy a node, or anything else) that
started but failed to finish. Cleared when any new asynchronous
operation is started.
Closes-Bug: #1237688
Change-Id: I7e079627b87b2cb1606e677e287dd08dcc87263a
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When accessing a subresource like /nodes/<id>/ports or /chassis/<id>/nodes
where <id> does not exist should fail with 404.
Also fix a typo in the name of a method on test_nodes.py
Change-Id: I5b6beba00fa7cc72b45689c5685914da895b7aa2
Closes-Bug: #1246731
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
We should use six.text_type for both python2 and python3 for
textual data type, not unicode, it supports python 2 only.
Change-Id: Ia5d7b5df83ff1a7536954f6a190502f117c80ff2
Partial-Bug: #1249886
|
| |/
|/|
| |
| |
| |
| |
| | |
The db api get_node_by_instance did not check if the given
instance uuid is a valid uuid or not. This patch fixes it.
Change-Id: Ic22e0bf5db34fdd3d8ef974f40ea3a736ee95525
|
|\ \ |
|
| |/
| |
| |
| |
| |
| |
| |
| |
| | |
The commands module was deprecated since version 2.6 and it has been
removed in Python 3. Use the subprocess module instead.
See http://docs.python.org/2/library/commands#module-commands
Closes-Bug: #1248216
Change-Id: I16d6baa77637f84b878df3ee6f964ddb9446d7bf
|
|/
|
|
|
|
|
|
|
|
|
| |
With new hacking>=0.8.0,<0.9 requirements, some functions are
now deprecated.
assertEquals -> assertEqual
assertNotEquals -> assertNotEqual
assert_ -> assertTrue
Change-Id: If666b68e6af5fcb9565f10c645b4e13dca16a141
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
To facilitate exposing a list of drivers in the API,
and keep track of which ironic-conductor instance status,
this patch ...
* adds a new 'conductors' table in the DB
* adds a Conductor object class (with intentionally limited
functionality)
* adds db/api methods for register/unregister/get/touch
* adds periodic task to conductor to maintain its updated_at field
* adds an additional db/api method to retrieve a list of drivers
which are registered by active conductor instances
Change-Id: I1ebdb92d5c2d6ad1a6d1717dd13ff51be181ccc0
|
|\ \ |
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In DB APIs that return a list of nodes, limiting and sorting the
output is necessary for a large number of output nodes. This is
especially important for the GUI that uses the APIs where the view
is limited. This patch adds limit, marker, sort_key and sort_dir
to get_associated_nodes and get_unassociated_nodes DB APIs.
Change-Id: Ia2c616fff65a03bace1244fe646bdf0cf5f30a29
|
|/
|
|
| |
Change-Id: I44612bbb92655c653766f8227571cbd99aa370ad
|
|
|
|
|
|
|
|
| |
Checks that node is associated with instance
added to method destroy_node() in db api.
Exception NodeAssociated raised in case associated node.
Change-Id: I52c7a0b3d33078b38460b5fd08e4cd2d4c7731ef
|
|
|
|
|
|
|
|
| |
These method were just stubs.
This patch implements them in db/sqlalchemy/api.py, and a subsequent
patch will expose this functionality via the API.
Change-Id: Iae68cbe3bf4e84a0f47a0770695bed9dae78aa95
|
|
|
|
|
|
|
|
|
|
| |
Most unit tests are derived from TestCase class of base.py.
A few unit tests are derived from BaseTestCase class of utils.py.
This patch consolidates these two classes into one and have all
the tests derived from a single base class which is TestCase class.
Hence, the ironic/tests/util.py is removed from this patch.
Change-Id: Iecc3352ef7e49524b202e6551a233692a2f6acea
|
|
|
|
|
|
|
|
| |
driver_info do not support nested objects. Self-namespace will be used
to distinguish parameters from one driver to another.
Change-Id: Ia720fac4b60aa0aa18406e0ba61d8a0a8c5c8a78
Partial-Bug: #1236533
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| | |
Infra team has indicated that tearDown should not be used, and should
be replaced with addCleanup in all places. This patch removes the
few cases of tearDown in Ironic.
Change-Id: Ie2a59ea018c68fccadf0530409255bd9a0cf9717
|
|\ \ |
|
| |/
| |
| |
| |
| |
| |
| |
| | |
driver_info do not support nested objects. Self-namespace will be used
to distinguish parameters from one driver to another.
Change-Id: I2756abc855ddfd5388dacb083c12c8916beedd01
Partial-Bug: #1236533
|
|/
|
|
|
|
|
|
| |
driver_info do not support nested objects. Self-namespace will be used
to distinguish parameters from one driver to another.
Change-Id: I165438fff7a032b54d3f019b727f6f85ad88d153
Partial-Bug: #1236533
|
|
|
|
|
|
|
|
| |
Currently the API on ports does not check for any required fields,
this patch add such verifications + tests.
Change-Id: I4a2003c3a5ab0a0b31742fcac119fbe20929f636
Partial-Bug: #1223847
|
|
|
|
|
|
|
|
|
| |
On the API side, when creating a new node or port, translate 'chassis_id'
and 'node_id' from uuid to id, internally id will be always used to do
database operations. The opposite will happen when returning data back
to the user the internal id will be translated to an uuid.
Change-Id: I84782268c4317b4eec53fdcdfc6cb2b901b22780
|
|
|
|
|
|
|
| |
This patch will prevent clients to update a node while its transitioning
from one state to another.
Change-Id: I3395916b5f9be3f6a5b6d7e6d92dd9353217d4d0
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| | |
Bulk queries used for replacement one-by-one cycles.
Complex operations executed only in the case of error.
add_filter_by_many_identities() method added.
Change-Id: I3161f5ace1fa5b1bee76cda48700218b64e2b79e
|
| |
| |
| |
| |
| |
| |
| | |
There is missing unique constraint in chassis table.
This patch adds missing UC in separate migration.
Change-Id: If4640d09a19bbd1548375fa6817e9d926c805c7c
|
|\ \ |
|
| |/
| |
| |
| |
| |
| |
| |
| | |
Chassis table is created after nodes table, there
is missing foreign key nodes.chassis_id -> chassis.id.
This patch adds missing FK in separate migration.
Change-Id: Ic82181c7aa85515a5a2bba49c8dc8d35b495742c
|
|/
|
|
|
|
| |
Implements: blueprint equivalent-pxe-driver
Change-Id: I59cf6e10ff00b3787e2bd60082ca872348157ec8
|
|
|
|
|
|
|
|
|
|
|
|
| |
Expose the power state and provision state of a baremetal node in the
API, each state is represented by a separate entity where clients can
GET/PUT value from/to it. A generic /state subresource is also exposed
allowing clients to GET all the current states of that node and links
to each one of the specific states.
Partially implements blueprint state-machine
Change-Id: I0dcea268718dc3bcb152880654631f9fd61295e7
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Checks that node is locked added to methods
destroy_node(), update_port(), destroy_port()
in db api.
Exception NodeLocked raised in case locked node.
Tests updated respectively.
Change-Id: I3218df016d35f80df7a707fd3f3c6dd40db81fd2
|
|\ \
| |/
|/| |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Deleting a chassis that has nodes might cause orphaned
hardware to appear. This patch disables deleting chassis
like that by checking the number of nodes that are in the
target chassis.
Change-Id: I0c7b83457b3be17949795c5cd8292421f66fa81e
|
|/
|
|
|
|
|
|
|
|
|
|
|
| |
Pagination is designed to return a subset of the larger collection while
providing a link that can be used to retrieve the next. The next link
will preserve any parameters sent in the initial request.
The patch also creates a new 'api' option group and move the existing
api configuration from the [default] section to the new [api] section.
Implements blueprint add-api-pagination
Change-Id: I3e72599344b7716a3ac88e504d018cbe7b0764b3
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
For db migrations tests on Jenkins we must use
hardcoded credentials and skip test if backend
(mysql or postgres) not available on developer
host.
Patch moves this "opportunistic" tests from Nova.
blueprint db-migration-tests-opportunistic
Change-Id: I3bd0be61a00916507f02a86a2e45c5831b3aaa5f
|
|/
|
|
|
|
|
| |
1. test create node
2. test delete node
Change-Id: I9e4e2b5dbb992bed12ec07db0a55614b9d045d31
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This patch adds links to the resources, this allows a client to easily
obtain rather than construct resource URIs.
The patch also:
* Add from_rpc_object to convert RPC objects into API object
* Add unittests for the API /chassis/ and /port/
* Change get_all() to return a list of objects instead of a list of UUIDs
Change-Id: I54a7b4846f1e9a76ee5fcb1bc84b5fd2b4fc3d8a
|
|\ \ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Test case TestMigrations with existing db
migrations tests added to common code in
test_migration.
blueprint db-migration-tests
Change-Id: I94feb7720d5b99da3790ba344c9c97861bc8ae1b
|