Skip to content

Commit 5f8eb7a

Browse files
Zuulopenstack-gerrit
authored andcommitted
Merge "Run codespell on octavia package directory"
2 parents 7228144 + 7ab75bf commit 5f8eb7a

27 files changed

+32
-32
lines changed

octavia/amphorae/backends/agent/api_server/lvs_listener_base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,6 @@ def delete_lvs_listener(self, listener_id):
8585
:param listener_id: The id of the listener
8686
8787
:returns: HTTP response with status code.
88-
:raises Exception: If unsupport initial system of amphora.
88+
:raises Exception: If unsupported initial system of amphora.
8989
9090
"""

octavia/amphorae/backends/utils/interface.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ def _addresses_up(self, interface, ipr, idx):
227227
if key in current_addresses:
228228
current_addresses.remove(key)
229229
elif address.get(consts.OCTAVIA_OWNED, True):
230-
# By default all adresses are managed/owned by Octavia
230+
# By default all addresses are managed/owned by Octavia
231231
address[consts.FAMILY] = self._family(
232232
address[consts.ADDRESS])
233233
LOG.debug("%s: Adding address %s", interface.name,

octavia/amphorae/drivers/haproxy/rest_api_driver.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ def _combined_config_delete(self, amphora, listener):
318318
# We have other listeners, so just update is fine.
319319
# TODO(rm_work): This is a little inefficient since this duplicates
320320
# a lot of the detection logic that has already been done, but it
321-
# is probably safer to re-use the existing code-path.
321+
# is probably safer to reuse the existing code-path.
322322
self.update_amphora_listeners(listener.load_balancer, amphora)
323323
else:
324324
# Deleting the last listener, so really do the delete

octavia/amphorae/drivers/health/heartbeat_udp.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -490,7 +490,7 @@ def _update_health(self, health, srcaddr):
490490
raw_pools = listener['pools']
491491

492492
# normalize the pool IDs. Single process listener pools
493-
# have the listener id appended with an ':' seperator.
493+
# have the listener id appended with an ':' separator.
494494
# Old multi-process listener pools only have a pool ID.
495495
# This makes sure the keys are only pool IDs.
496496
pools = {(k + ' ')[:k.rfind(':')]: v for k, v in
@@ -511,7 +511,7 @@ def _update_health(self, health, srcaddr):
511511
raw_pools = health['pools']
512512

513513
# normalize the pool IDs. Single process listener pools
514-
# have the listener id appended with an ':' seperator.
514+
# have the listener id appended with an ':' separator.
515515
# Old multi-process listener pools only have a pool ID.
516516
# This makes sure the keys are only pool IDs.
517517
pools = {(k + ' ')[:k.rfind(':')]: v for k, v in raw_pools.items()}

octavia/api/common/pagination.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ def apply(self, query, model, enforce_valid_params=True):
244244
:param query: the query object to which we should add
245245
paging/sorting/filtering
246246
:param model: the ORM model class
247-
:param enforce_valid_params: check for invalid enteries in self.params
247+
:param enforce_valid_params: check for invalid entries in self.params
248248
249249
:rtype: sqlalchemy.orm.query.Query
250250
:returns: The query with sorting/pagination/filtering added.
@@ -259,7 +259,7 @@ def apply(self, query, model, enforce_valid_params=True):
259259
secondary_query_filter = filter_params.pop(
260260
"project_id", None) if (model == models.Amphora) else None
261261

262-
# Tranlate arguments from API standard to data model's field name
262+
# Translate arguments from API standard to data model's field name
263263
filter_params = (
264264
model.__v2_wsme__.translate_dict_keys_to_data_model(
265265
filter_params)

octavia/cmd/driver_agent.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ def process_cleanup(*args, **kwargs):
155155
'ignoring and continuing shutdown process.',
156156
str(e), proc.name)
157157
else:
158-
LOG.info('Provider agent "%s" has succesfully shutdown.',
158+
LOG.info('Provider agent "%s" has successfully shutdown.',
159159
proc.name)
160160

161161
signal.signal(signal.SIGTERM, process_cleanup)

octavia/cmd/health_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ def hm_exit(*args, **kwargs):
7878

7979

8080
def _handle_mutate_config(listener_proc_pid, check_proc_pid, *args, **kwargs):
81-
LOG.info("Health Manager recieved HUP signal, mutating config.")
81+
LOG.info("Health Manager received HUP signal, mutating config.")
8282
_mutate_config()
8383
os.kill(listener_proc_pid, signal.SIGHUP)
8484
os.kill(check_proc_pid, signal.SIGHUP)

octavia/cmd/house_keeping.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ def cert_rotation():
7272

7373

7474
def _mutate_config(*args, **kwargs):
75-
LOG.info("Housekeeping recieved HUP signal, mutating config.")
75+
LOG.info("Housekeeping received HUP signal, mutating config.")
7676
CONF.mutate_config_files()
7777

7878

octavia/common/base_taskflow.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ def _details_filter(obj):
7171

7272
class FilteredJob(Job):
7373
def __str__(self):
74-
# Override the detault __str__ method from taskflow.job.base.Job,
74+
# Override the default __str__ method from taskflow.job.base.Job,
7575
# filter out private information from details
7676
cls_name = type(self).__name__
7777
details = _details_filter(self.details)

octavia/common/config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -935,7 +935,7 @@ def register_cli_opts():
935935
def handle_neutron_deprecations():
936936
# Apply neutron deprecated options to their new setting if needed
937937

938-
# Basicaly: if the value of the deprecated option is not the default:
938+
# Basically: if the value of the deprecated option is not the default:
939939
# * convert it to a valid "new" value if needed
940940
# * set it as the default for the new option
941941
# Thus [neutron].<new_option> has an higher precedence than

octavia/common/tls_utils/cert_parser.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ def _prepare_x509_cert(cert=None):
132132
def _split_x509s(xstr):
133133
"""Split the input string into individual x509 text blocks
134134
135-
:param xstr: A large multi x509 certificate blcok
135+
:param xstr: A large multi x509 certificate block
136136
:returns: A list of strings where each string represents an
137137
X509 pem block surrounded by BEGIN CERTIFICATE,
138138
END CERTIFICATE block tags

octavia/common/validate.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ def validate_l7rule_ssl_types(l7rule):
229229
# log or raise key and value must be specified.
230230
msg = 'L7rule type {0} needs to specify a key and a value.'.format(
231231
rule_type)
232-
# log or raise the key must be splited by '-'
232+
# log or raise the key must be split by '-'
233233
elif not dn_regex.match(req_key):
234234
msg = 'Invalid L7rule distinguished name field.'
235235

@@ -246,7 +246,7 @@ def sanitize_l7policy_api_args(l7policy, create=False):
246246
redirect_pool_id exists in the database, but will raise an
247247
error if a redirect_url doesn't look like a URL.
248248
249-
:param l7policy: The L7 Policy dictionary we are santizing / validating
249+
:param l7policy: The L7 Policy dictionary we are sanitizing / validating
250250
"""
251251
if 'action' in l7policy.keys():
252252
if l7policy['action'] == constants.L7POLICY_ACTION_REJECT:

octavia/controller/worker/v2/controller_worker.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,7 @@ def batch_update_members(self, old_members, new_members,
536536
self._member_repo.get(
537537
session, id=member[constants.MEMBER_ID])
538538
for member in new_members]
539-
# The API may not have commited all of the new member records yet.
539+
# The API may not have committed all of the new member records yet.
540540
# Make sure we retry looking them up.
541541
if None in db_new_members or len(db_new_members) != len(new_members):
542542
LOG.warning('Failed to fetch one of the new members from DB. '
@@ -1128,7 +1128,7 @@ def failover_loadbalancer(self, load_balancer_id):
11281128
11291129
:param load_balancer_id: ID for load balancer to failover
11301130
:returns: None
1131-
:raises octavia.commom.exceptions.NotFound: The load balancer was not
1131+
:raises octavia.common.exceptions.NotFound: The load balancer was not
11321132
found.
11331133
"""
11341134
try:

octavia/controller/worker/v2/tasks/amphora_driver_tasks.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ def on_failure(self, history, *args, **kwargs):
6161
max_retry_attempt = CONF.haproxy_amphora.connection_max_retries
6262
for task_name, ex_info in last_errors.items():
6363
if len(history) <= max_retry_attempt:
64-
# When taskflow persistance is enabled and flow/task state is
64+
# When taskflow persistence is enabled and flow/task state is
6565
# saved in the backend. If flow(task) is restored(restart of
6666
# worker,etc) we are getting ex_info as None - we need to RETRY
6767
# task to check its real state.

octavia/controller/worker/v2/tasks/compute_tasks.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def on_failure(self, history, *args, **kwargs):
5959
max_retry_attempt = CONF.controller_worker.amp_active_retries
6060
for task_name, ex_info in last_errors.items():
6161
if len(history) <= max_retry_attempt:
62-
# When taskflow persistance is enabled and flow/task state is
62+
# When taskflow persistence is enabled and flow/task state is
6363
# saved in the backend. If flow(task) is restored(restart of
6464
# worker,etc) we are getting ex_info as None - we need to RETRY
6565
# task to check its real state.

octavia/controller/worker/v2/tasks/lifecycle_tasks.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020

2121
class BaseLifecycleTask(task.Task):
22-
"""Base task to instansiate common classes."""
22+
"""Base task to instantiate common classes."""
2323

2424
def __init__(self, **kwargs):
2525
self.task_utils = task_utilities.TaskUtils()

octavia/db/migration/alembic_migrations/versions/55874a4ceed6_add_l7policy_action_redirect_prefix.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030

3131

3232
def upgrade():
33-
# Add collumn redirect_prefix
33+
# Add column redirect_prefix
3434
op.add_column(
3535
u'l7policy',
3636
sa.Column(u'redirect_prefix', sa.String(255), nullable=True)

octavia/db/migration/alembic_migrations/versions/5a3ee5472c31_add_cert_expiration__infor_in_amphora_table.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
1212
# License for the specific language governing permissions and limitations
1313
# under the License.
14-
"""add cert expiration infor in amphora table
14+
"""add cert expiration info in amphora table
1515
1616
Revision ID: 5a3ee5472c31
1717
Revises: 3b199c848b96

octavia/db/migration/alembic_migrations/versions/6742ca1b27c2_add_l7policy_redirect_http_code.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929

3030

3131
def upgrade():
32-
# Add collumn redirect_prefix
32+
# Add column redirect_prefix
3333
op.add_column(
3434
u'l7policy',
3535
sa.Column(u'redirect_http_code', sa.Integer(), nullable=True)

octavia/db/prepare.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def create_load_balancer(lb_dict):
3131
lb_dict[constants.PROVISIONING_STATUS] = constants.PENDING_CREATE
3232
lb_dict[constants.OPERATING_STATUS] = constants.OFFLINE
3333

34-
# Set defaults later possibly overriden by flavors later
34+
# Set defaults later possibly overridden by flavors later
3535
lb_dict['topology'] = CONF.controller_worker.loadbalancer_topology
3636

3737
return lb_dict

octavia/db/repositories.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1371,7 +1371,7 @@ def test_and_set_status_for_delete(self, lock_session, id):
13711371
13721372
Puts a lock on the amphora table to check the status of the
13731373
amphora. The status must be either AMPHORA_READY or ERROR to
1374-
successfuly update the amphora status.
1374+
successfully update the amphora status.
13751375
13761376
:param lock_session: A Sql Alchemy database session.
13771377
:param id: id of Load Balancer

octavia/distributor/drivers/driver_base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ def get_add_vip_subflow(self):
6464
:returns: A TaskFlow Flow that will add a VIP to the distributor
6565
6666
This method will return a TaskFlow Flow that adds a VIP to the
67-
distributor by perfoming the necessary steps to plug the VIP and
67+
distributor by performing the necessary steps to plug the VIP and
6868
configure the distributor to start receiving requests on this VIP.
6969
"""
7070

octavia/network/drivers/neutron/allowed_address_pairs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -491,7 +491,7 @@ def allocate_vip(self, load_balancer):
491491
LOG.info('Port %s already exists. Nothing to be done.',
492492
load_balancer.vip.port_id)
493493
return self._port_to_vip(port, load_balancer)
494-
LOG.error('Neutron VIP mis-match. Expected ip %s on '
494+
LOG.error('Neutron VIP mismatch. Expected ip %s on '
495495
'subnet %s in network %s. Neutron has fixed_ips %s '
496496
'in network %s. Deleting and recreating the VIP '
497497
'port.', load_balancer.vip.ip_address,

octavia/tests/common/sample_haproxy_prometheus

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ haproxy_process_pool_failures_total 0
2525
# HELP haproxy_process_max_fds Maximum number of open file descriptors; 0=unset.
2626
# TYPE haproxy_process_max_fds gauge
2727
haproxy_process_max_fds 375033
28-
# HELP haproxy_process_max_sockets Maximum numer of open sockets.
28+
# HELP haproxy_process_max_sockets Maximum number of open sockets.
2929
# TYPE haproxy_process_max_sockets gauge
3030
haproxy_process_max_sockets 375033
3131
# HELP haproxy_process_max_connections Maximum number of concurrent connections.

octavia/tests/functional/api/test_healthcheck.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ def test_healthcheck_get_text(self):
111111
self.assertEqual(200, response.status_code)
112112
self.assertEqual('OK', response.text)
113113

114-
# Note: For whatever reason, detailed=True text has no additonal info
114+
# Note: For whatever reason, detailed=True text has no additional info
115115
def test_healthcheck_get_text_detailed(self):
116116
self.conf.config(group='healthcheck', detailed=True)
117117
response = self._get(self._get_enabled_app(), '/healthcheck')
@@ -275,7 +275,7 @@ def test_healthcheck_get_html_detailed_failed(self, mock_get_session):
275275
self.assertIn('boom', response.text)
276276
self.assertIn('Garbage collector', response.text)
277277

278-
# Note: For whatever reason, detailed=True text has no additonal info
278+
# Note: For whatever reason, detailed=True text has no additional info
279279
@mock.patch('octavia.db.api.get_session')
280280
def test_healthcheck_get_text_detailed_failed(self, mock_get_session):
281281
self.conf.config(group='healthcheck', detailed=True)

octavia/tests/unit/amphorae/backends/utils/test_keepalivedlvs_query.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -620,7 +620,7 @@ def test_get_lvs_listener_pool_status_when_no_members(
620620
def test_get_lvs_listener_pool_status_when_not_get_realserver_result(
621621
self, mock_get_mapping, mock_os_stat):
622622
# This will hit if the kernel lvs file (/proc/net/ip_vs)
623-
# lose its content. So at this moment, eventhough we configure the
623+
# lose its content. So at this moment, even though we configure the
624624
# pool and member into udp keepalived config file, we have to set
625625
# ths status of pool and its members to DOWN.
626626
mock_os_stat.side_effect = (

octavia/tests/unit/controller/worker/v2/test_controller_worker.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2036,7 +2036,7 @@ def test_get_amphorae_for_failover_act_stdby_net_split(
20362036
mock_member_repo_get, mock_l7rule_repo_get, mock_l7policy_repo_get,
20372037
mock_listener_repo_get, mock_lb_repo_get, mock_health_mon_repo_get,
20382038
mock_amp_repo_get):
2039-
# Case where the amps can't see eachother and somehow end up with
2039+
# Case where the amps can't see each other and somehow end up with
20402040
# two amphora with an interface. This is highly unlikely as the
20412041
# higher priority amphora should get the IP in a net split, but
20422042
# let's test the code for this odd case.

0 commit comments

Comments
 (0)