This class have been stayed in source code for a long
time and not used since it created. The API service used `senlin.api.common.wsgi.Server`, not this class . It should be cleaned up.
Change-Id: I71196af4ad5ce0c975bec1c8c80be19b43ccbd2d
Currently, the python openstacksdk changed rebuild_server function's
parameters. So, when the senlin-engine handle rebuild nova instance, it
will raise this error like: "rebuild_server() got multiple values
for argument 'image'"
This patch will fix above error
Change-Id: Ibc03fe6d5ca6db2b02ece5d0b3aab00dff157de1
Many python files have their executable permissions flag set but they shouldn't Removed executable flag from files that did not need it
Closes-Bug: #2055736
Change-Id: Ic04051fdc597b2f915f76e4c4c47f392354ddfe1
When using token to init a new openstacksdk connection, the SDK try to fetch
another token from it, causing keystone raise exception and return 500 status
response. Refer: https://bugs.launchpad.net/keystone/+bug/1959674
Switch from `token` to `admin_token` to make the SDK session use the provided
token directly instead of fetching a new one.
Closes-bug: #2048452
Depends-On: https://review.opendev.org/c/openstack/senlin/+/905555
Change-Id: I8f9b2db3d4851cf54c2113b2fb0ae97ae38ac286
Excluding CLUSTER_RESIZE from the list of actions that skip
pre-operation checks if the cluster is already at the minimum threshold.
When the cluster is at the minimum threshold, pre-op LB will function
with actions such as CLUSTER_DEL_NODES, CLUSTER_SCALE_IN, NODE_DELETE,
and will skip actions like CLUSTER_REPLACE_NODES and CLUSTER_RESIZE.
Closes-Bug: #2049191
Change-Id: I00a7ea40f69bafc94ca2bba9f268af7b03344997
The SSL Middleware got removed from the `oslo.middleware` lib. Refer: 67b9c23f16
This cause zuul jobs failed.
Change-Id: Iba896057e16843739e3a395edf8df97fbac6107d
In cases where the cluster's desired capacity equals
the minimum size, executing an action causing node
(exception: CLUSTER_REPLACE_NODES) reduction led to
premature removal of the node's IP from the load
balancer during the pre_op step.
The commit addresses this issue by introducing a check
to skip the pre_op step if the cluster is already at
its minimum size. Now, when desired_capacity equals min_size,
the pre_op step is bypassed, preventing unnecessary
removal of IPs from the load balancer.
Closes-Bug: #2048100
Change-Id: Ia7389e8c555497cfa5ccbdca77258f4165dfc62d
The SCALE_IN action in the lb_policy module was removing only
one node from the load balancer, regardless of the specified
count when the count was greater than 1. This was due to a
hard-coded count of 1 in the _get_delete_candidates function.
The root cause has been addressed by updating the
_get_delete_candidates function to dynamically handle the count
for SCALE_IN. The count is now retrieved from the action inputs,
and if not specified or invalid, it defaults to 1.
Closes-Bug: #2048099
Change-Id: I9ff12dec26f4c558ef5ef84de87668e9668cec80
When terminate senlin-api process the `evenlet.wsgi.server` raised OSError exception that is not a list or a tuple which make TypeError raised and the senlin-api process may not be terminated properly
Closes-Bug: #2047914
Change-Id: Id02befe51e9118c8d8dafc3c926398fbf7e1258e
Re-arranged sessions to always be at the top level to make
it easier to know the origin of the current session. This
is important now that we no longer have autocommit enabled.
- Added zuul job testing sqlalchemy 2.x.
- Added new db api for service cleanup.
- Removed broken sqlite cleanup step during testing.
Change-Id: I168f3d9518611ac66cb9eec1132a7add19e92d5f
has_calls was removed from Python 3.12, as starts failing in Debian
unstable. This patch fixes it.
Change-Id: Id594856ad39c17e2eb105e6ad5067fa9a66a04a3
This patch allow to define subnet in profile,
Default network port will find a random subnet to create port on, user can define specific subnet.
Change-Id: I8a29dcb7c8b92c8bd1b8c9111134c3ace6ea9a76
sqlalchemy-migrate is no longer supported and we need to switch
to alembic for database migrations.
Change-Id: I2e51b4027f7af63944b5504ddcf50e9e48818259
When spliting the engine up into multiple services
the cleanup job was left on the conductor, but in
reality each service needs to handle their own clean
up, as the service startup order is never guaranteed.
This patch refactors the service workflow and moves
all cleanup logic to the base class.
Closes-Bug: 1975440
Change-Id: I718910a124780804ec8e14c2e99697025e4c4df0
Because of how sql tracing was implemented, the
order of operations was very important, this made
it difficult to run tests from an IDE. This patch
makes the tracing code safer so that it won't break
depending on how the code is executed.
Change-Id: Id4e82ba8f0abafb527dd811b190d2355f9fce71d
We can no longer use flavor id from server_get and now
always use either flavor name or original_name as a
fallback.
Change-Id: I4e34fe4911abfb3c8ed59104ff67f6a1f27cda24
The call cluster_policy_get_all did not properly
implement the and_ sqlalchemy method so it didn't
properly respect the contraint.
Change-Id: I71a9a6f4fbf5e6177ddad65709ea995728a89d6f
The following unused configuration options were removed.
- periodic_interval_max
- periodic_fuzzy_delay
Change-Id: Ifbd520a88156ec52a1f998b0b7fae4db27a3debb
The standard library's collections abstract base classes have been
moved from the collections module to the collections.abc module. The
abstract data clases in the collections module have been deprecated
since Python 3.3 and are removed in Python 3.10.
Closes-Bug: #1954319
Change-Id: I27b3ddb38c677cce2966554d625791f02c0e11df
The assertRaisesRegexp method has been deprecated since it was renamed
to assertRaisesRegex in Python 3.2 .
https: //docs.python.org/3/library/unittest.html#deprecated-aliases
Change-Id: I9b6e6283301dfb6d1874b81bb5f26db56568bd5a
inspect.getargspec was deprecated since Python 3.0 and
inspect.getfullargspec is its replacement with correct handling of
function annotations and keyword-only parameters[1].
[1] https://docs.python.org/3/library/inspect.html#inspect.getargspec
Change-Id: I2411be23a83aef9550d58ead51b4caf2f8c5409f
the pool can be created without setting the var below
session_persistence[type|cookie_name]
Closes-Bug: 1934543
Change-Id: I08eecb2c45d2cb1f730e6b9d8bb549306b3a2f89
Change Ibc0c6e7adc6cbdf87c1d1c5ec42f6954d6995253 has a bug for the
order of args which failed the lb creation with policy attach. This
change fixes the issue.
Change-Id: I38a0c768a16527d7f36f81f1e7ffddb8aa3b0146
We are passing senlin cluster_name to lb/pool/listener for name,
That way we have proper name relationship between all 3 components.
specially for troubleshooting when we have many loadbalancers.
Example:
$ openstack cluster list -c name -c status
+-----------+--------+
| name | status |
+-----------+--------+
| mycluster | ACTIVE |
+-----------+--------+
$ openstack loadbalancer list -c name -c vip_address
+---------------------+-------------+
| name | vip_address |
+---------------------+-------------+
| senlin-lb-mycluster | 10.69.1.173 |
+---------------------+-------------+
$ openstack loadbalancer pool list -c name -c provisioning_status
+-----------------------+---------------------+
| name | provisioning_status |
+-----------------------+---------------------+
| senlin-pool-mycluster | ACTIVE |
+-----------------------+---------------------+
Change-Id: Ibc0c6e7adc6cbdf87c1d1c5ec42f6954d6995253
This patch will fix broken support of session_persistence and
only add cookie_name when type is APP_COOKIE.
Change-Id: I32ad7840208bcc20091abcc1df68a7a707a7c4ac
Add placeholder 'r' in node.name.format cluster config option to use
only lowercase random letters for node name.
Change-Id: I49a90dc60649e01e6fead031b90f49fd29b2518e