2536 Commits

Author SHA1 Message Date
Hervé Beraud
ad0d99c812 doc: Remove crud from conf.py file
Change-Id: I35c6221f78cac9fe4ab3e194e8a94ca4f0b24ca2
2018-10-15 09:42:18 +02:00
ZhongShengping
b868aebf45 Clean up .gitignore references to personal tools
Developers run all sorts of different tools within Git repositories,
any of which can leave their own special trashfiles all over the
place. We can't every hope to catalog them all, so better to
recommend developers simply configure a global core.excludesfile to
filter the irrelevant files which tend to get created by their
personal choice of tools.

To this end, remove the long-standing sections for "Mr Developer"
and "Editors" since their mere existence here sends the signal that
we welcome (and have time to review) additions for any old tool
someone ever might happen to try. Also add a comment block
explaining this, for clarity.

We can, and should of course, continue to list files created by the
tools recommended by our workflow (test frameworks called from tox,
documentation and packaging builds, et cetera).

This change is a port of I1b41efac219fca44e2548fc36633724d0ecfc0cb
from the openstack-dev/oslo-cookiecutter repository.

Change-Id: I4078179f3d55847ea23f8790572ba911e52fce53
2018-10-15 11:49:38 +08:00
Kenneth Giusti
9ca7359bfd Allow transport_url initialization in ConfFixture constructor
Change-Id: Ibe2a5277cdcf89cd006507f13eddbbec4b384681
2018-10-09 13:46:00 -04:00
Zuul
16fea5b368 Merge "Fix oslo.messaging default transport" 2018-10-05 22:48:55 +00:00
Mehdi Abaakouk
172cfb33f3 Fix oslo.messaging default transport
Change d3f6ca0b47e2a5a3413b27617d9655f02b191c6a have broken
oslo.messaging defaults, no more transport are selected by default and
oslo.messaging just crash:

    Traceback (most recent call last):
      File "/home/sileht/workspace/openstack/oslo.messaging/.tox/py27/lib/python2.7/site-packages/mock/mock.py", line 1305, in patched
        return func(*args, **keywargs)
      File "oslo_messaging/tests/test_transport.py", line 111, in test_get_transport
        transport_ = oslo_messaging.get_transport(self.conf, **kwargs)
      File "/home/sileht/workspace/openstack/oslo.messaging/.tox/py27/lib/python2.7/site-packages/debtcollector/removals.py", line 242, in wrapper
        return f(*args, **kwargs)
      File "oslo_messaging/transport.py", line 247, in get_transport
        transport_cls=RPCTransport)
      File "oslo_messaging/transport.py", line 205, in _get_transport
        url.transport.split('+')[0],
    AttributeError: 'NoneType' object has no attribute 'split'

This change restores rabbit:// as default.

Change-Id: I945a2aca60347dad672cc406cd33e80e93c588a7
2018-10-05 15:21:45 +02:00
Hervé Beraud
e9ed47f416 always build universal wheels
All of our projects are pure python, so we can build universal wheels by default.

Change-Id: I3369303d278af6154cdcf06b727e8ff941dc410a
2018-10-04 19:56:43 +02:00
Oleg Bondarev
3a5de89dd6 Use default exchange for direct messaging
Lots of exchanges create problems during failover under high
load. Please see bug report for details.

This is step 1 in the process: only using default exchange
when publishing. Consumers will still consume on separate
exchanges (and on default exchange by default) so this
should be (and tested to be) a non-breaking and
upgrade-friendly change.

Step 2 is to update consumers to only listen on default exchange,
to happen in T release.

Change-Id: Id3603f4b7e1274b616d76e1c0c009d2ab7f6efb6
Closes-Bug: #1789177
2018-09-25 07:59:28 +00:00
Steve Kowalik
95b487ba6b Refactor GetTransportSadPathTestCase
GetTransportSadPathTestCase did an awful lot of mocking for things that
were no longer called. Since we only have one callable now, make use of
self.assertRaises.

Change-Id: Ie93ff74de84ff4d6cc75a3c89dd9a03fdcba5d35
2018-09-25 14:18:57 +10:00
Zuul
815e25e55b Merge "Add release note about deprecated option removals" 2018-09-24 16:49:12 +00:00
Zuul
34519efd2d Merge "Remove rpc_backend and ConfFixture.transport_driver" 2018-09-24 16:49:11 +00:00
Zuul
4eca2a29b0 Merge "Use templates for cover and lower-constraints" 2018-09-24 16:28:50 +00:00
Steve Kowalik
58fb5b0675 Add release note about deprecated option removals
Since we have removed a large amount of deprecated options, add a
release note documenting which options have been removed.

Depends-On: https://review.openstack.org/580910
Change-Id: Idb45f691dab77e5bfae841ea45fa167c224c3322
2018-09-14 11:48:28 -06:00
Zuul
ede61c360d Merge "Remove deprecated amqp1 options" 2018-09-14 17:46:26 +00:00
Zuul
14c5bed497 Merge "Remove default_{host,port} deprecated options" 2018-09-14 16:00:45 +00:00
Steve Kowalik
d3f6ca0b47 Remove rpc_backend and ConfFixture.transport_driver
Now that most projects have transitioned from using
ConfFixture.transport_driver, we can remove it and rpc_backend as a
whole. rpc_backend was first deprecated in 5.10.0, released during
Ocata.

Closes-Bug: #1712399
Change-Id: I193cc0e613459a6dbbfd54ed0901a54ded78d712
2018-09-13 15:01:27 -06:00
Steve Kowalik
b0d3bfceb8 Remove deprecated rabbit options
Remove the deprecated options rabbit_host, rabbit_port, rabbit_hosts,
rabbit_userid, rabbit_password, rabbit_virtual_host and
rabbit_max_retries which were deprecated in 5.10.0, released during
Ocata.

Change-Id: I39dec568e5de0b653e5af1f196537e09ef126a36
Closes-Bug: #1712394
2018-09-10 15:11:19 -06:00
Andreas Jaeger
3d7ad9cab4 Use templates for cover and lower-constraints
Use openstack-tox-cover template, this runs the cover job as
non-voting in the check queue only.

Use openstack-lower-constraints-jobs template

Remove jobs that are part of the templates.

Sort list of templates, move templates first in project stanza as is
common practice.

Change-Id: Idb976b160479efcf9f3726c1716bf9d2c39ab6cc
2018-09-07 12:18:29 +02:00
Steve Kowalik
8881ed4378 Remove deprecated amqp1 options
The amqp1 options allow_insecure_options, username and password are all
deprecated, remove them. allow_insecure_options was deprecated during
Ocata, and the other two were deprecated in 5.22.0, released during
Pike.

Change-Id: I321266c3dba83a38fe6ebd775db2e74c14cc96cd
2018-09-05 16:59:13 +10:00
Steve Kowalik
3b1b08b74a Remove rabbit_durable_queues deprecated option
The rabbit_durable_queues option has been deprecated since amqp code was
moved from olso-incubator to this project, so it's high time it was
removed.

Change-Id: If2450696a43c05c32d35bff26d3dc38423f4330e
2018-09-05 15:35:20 +10:00
Steve Kowalik
4cc1264a18 Remove default_{host,port} deprecated options
The Kafka driver deprecated the kafka_default_host and
kafka_default_port options in 5.10.0, released in Ocata. Remove them.

Change-Id: I206e68ec1624bb6d5d6ba320572530352bbd4378
2018-09-05 14:44:54 +10:00
Zuul
90a5bd5077 Merge "Remove the deprecated ZeroMQ driver" 2018-08-29 14:08:20 +00:00
Zuul
9ab5a2e30e Merge "Fix the coverage tox tests" 2018-08-29 11:57:24 +00:00
Andy Smith
f2fd8d4375 Remove the deprecated ZeroMQ driver
Users of the oslo.messaging RPC communications service must use
the rabbit ("rabbit://...") or AMQP 1.0 ("amqp://...") drivers.

Change-Id: If3474142f1fe99d41d7b4466061ed0e23ca38549
Closes-Bug: 1789259
2018-08-28 16:00:50 -04:00
Kenneth Giusti
d8b0d48055 Fix the coverage tox tests
Change-Id: I45f7269c95807e7a804f116c2d1aed6baf9f46e2
2018-08-20 15:20:47 -04:00
Kenneth Giusti
d9866029a2 Avoid logging passwords on connection events
Change-Id: I15c8c4a1177c363283281d2fed63545658eda5de
Closes-Bug: #1787214
2018-08-20 12:31:16 -04:00
Doug Hellmann
a4a8eef010 add lib-forward-testing-python3 test job
This is a mechanically generated patch to add a functional test job
running under Python 3 as part of the python3-first goal.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: Ib99a323861c0fdb548287446ab25e0516a7c182e
Story: #2002586
Task: #24322
2018-08-11 18:20:14 -04:00
Doug Hellmann
deec8c1f13 add python 3.6 unit test job
This is a mechanically generated patch to add a unit test job running
under Python 3.6 as part of the python3-first goal.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: I1da69d0b77a3970c727b60de4c341552970fbb47
Story: #2002586
Task: #24322
2018-08-07 16:17:34 -04:00
Doug Hellmann
818fd688a2 import zuul job settings from project-config
This is a mechanically generated patch to complete step 1 of moving
the zuul job settings out of project-config and into each project
repository.

Because there will be a separate patch on each branch, the branch
specifiers for branch-specific jobs have been removed.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: I0401a53945ad87e1dc046904054b12e2b106a3e8
Story: #2003250
2018-08-03 17:45:00 -04:00
Andras Kovi
d8fa6d5edf Call listener stop only if listener is initialized
Change-Id: I1303d74af7a242edefe774d8f5e12e63614c0158
Closes-Bug: #1785048
2018-08-02 13:28:42 +02:00
Zuul
3a725f957b Merge "Update reno for stable/rocky" 2018-08-01 20:57:30 +00:00
Zuul
01a37733eb Merge "Issue blocking ACK for RPC requests from the consumer thread" 2018-07-30 15:48:21 +00:00
59c47233f5 Update reno for stable/rocky
Change-Id: I1a8834b95487805805395e919e2c6cdc435522b0
2018-07-26 12:38:43 +00:00
Dirk Mueller
e233334a9e Remove setting of DEVSTACK_GATE_EXERCISES
This defaults to 0 anyway, and is being removed as the devstack
excercises are being removed. see https://review.openstack.org/#/c/581377/

Change-Id: Ifb147f9fb2071724a9eaf306273276db65125cf7
2018-07-17 10:46:55 +02:00
Daniel Alvarez
7dc7684311 Bump py-amqp to >= 2.3.0
Due to the bug below we want to have py-amqp>=2.3.0 so that connecting
to rabbit endpoints don't timeout when relying on /etc/hosts entries.
Closes-Bug: 1780992

Change-Id: Ia2c1114cb0f8d480695197714f7c6293751430dd
2018-07-11 15:22:21 +02:00
Kenneth Giusti
26b0be585a Issue blocking ACK for RPC requests from the consumer thread
The patch for https://review.openstack.org/#/c/436958/ fixed a
threading problem by moving the ack back to the polling
thread. However the RPC server expects to catch any failures of the
ACK and abort the request.  This patch adds the ACK error handling
back to the polling thread.

This patch is based heavily off the original work done by Mehdi
Abaakouk (sileht).

Change-Id: I708c3d6676b974d8daac6817c15f596cdf35817b
Closes-Bug: #1695746
2018-07-11 08:59:35 -04:00
Zuul
b97481ce19 Merge "No longer allow redundant calls to server start()" 2018-07-10 10:24:58 +00:00
Zuul
8047377562 Merge "py37: deal with Exception repr changes" 2018-07-09 22:13:18 +00:00
Zuul
1f0682bc59 Merge "py37: drop use of 'async' as parameter name" 2018-07-09 17:38:37 +00:00
Zuul
9be8c1a6e2 Merge "Do not access the connection's socket during error callback" 2018-07-06 21:21:00 +00:00
Kenneth Giusti
361669764f Do not access the connection's socket during error callback
The _get_connection_info() method attempts to gather debug information
from the connection, and will reach into the amqp channel to get the
local (client's) TCP port number via the 'sock' property.

If _get_connection_info() is called from autoretry's on_error handler
the 'sock' property notices that the transport is not set and attempts
to re-connect.  amqp has deprecated this reconnect behavior, and in
any case the client's socket is irrelevant since the connection may
not be valid at this point.

Closes-Bug: #1745166
Change-Id: I3c42f8463605927f6f94d6c3a7f05e584476abc1
2018-07-06 12:15:53 -04:00
Kenneth Giusti
679572272e Fix debug log message - missing argument
Change-Id: I811c6051808a34fa5235b47e56ee3b41cb35adad
2018-07-06 11:41:07 -04:00
Zuul
cd2c63753b Merge "Remove transport aliases support" 2018-07-05 18:26:23 +00:00
James Page
dfb83f4948 py37: deal with Exception repr changes
Under Python 3.7, a trailing comma is no longer added to
the init parameters generated by a repr() call:

    >>> repr(Exception('It Works'))
    "Exception('It Works')"

vs

    >>> repr(Exception('It Works'))
    "Exception('It Works',)"

Support pre and post Python 3.7 formats in test cases for
notification middleware.

Change-Id: I30a46ae82f2cc1b529287c049aa5fc6d987e2538
2018-07-05 06:38:38 -05:00
James Page
5626782fac py37: drop use of 'async' as parameter name
Python 3.7 does not allow the use of 'async' as
a parameter name or object attribute; update
occurrences to use a different name.

This is inline with PEP-492, where await and async
are keywords.

Change-Id: I73efcafab1e0832a0ada95f6c12cb6a659dfcf27
2018-07-05 06:09:37 -05:00
Steve Kowalik
e55f419017 Remove transport aliases support
To facilitate removing rpc_backend support, disentangle the aliases
code by removing it to simplify the code and the tests. Aliases were
first depreacted in 5.20.0 during Pike.

Change-Id: I7d80cd050ce1eca2c6b6c38f0fac29d090b90bf3
Closes-Bug: #1424728
2018-07-05 15:58:05 +10:00
Vu Cong Tuan
bcbebb7d6a Moving stestr to correct package order in test-requirements.txt
As the comment from Stephen [1],
after moving to stestr, the package should be in exact position
where testrepository is removed.

[1] https://review.openstack.org/#/c/579743/2/test-requirements.txt@16

Change-Id: Ib748e4f8ba1263f2c6475c8641c800b7df872b88
2018-07-05 08:28:33 +07:00
Zuul
9e61ad5405 Merge "Fix the bandit security linter test" 2018-07-04 18:04:50 +00:00
Zuul
2ca8a15905 Merge "Switch to stestr" 2018-07-04 13:03:07 +00:00
Vu Cong Tuan
7e5be7c54c Switch to stestr
According to Openstack summit session [1],
stestr is maintained project to which all Openstack projects should migrate.
Let's switch to stestr as other projects have already moved to it.

[1] https://etherpad.openstack.org/p/YVR-python-pti

Change-Id: I89b785c91738ab62e3f42da42c431b9df8ccfd70
2018-07-04 08:33:49 +07:00
Zuul
8a5da2c28f Merge "Enable RPC call monitoring in AMQP 1.0 driver" 2018-07-04 00:04:17 +00:00