2094 Commits

Author SHA1 Message Date
Jenkins
a1fecbec58 Merge "ensure we set channel in lock" 2017-01-05 02:46:44 +00:00
Jenkins
6809dbe044 Merge "kafka: Don't hide unpack/unserialize exception" 2017-01-04 13:11:35 +00:00
Jenkins
8ac9558c6e Merge "kafka: timeout is in milliseconds" 2017-01-04 13:11:29 +00:00
Jenkins
42d1fa4aac Merge "kafka: disable batch for functional tests" 2017-01-04 13:11:23 +00:00
Jenkins
654be38629 Merge "kafka: Remove Producer singleton" 2017-01-04 13:11:21 +00:00
Jenkins
74f5dd5c1c Merge "Moving driver to new kafka-python version" 2017-01-04 13:11:06 +00:00
gord chung
1dc575ce5b ensure we set channel in lock
_set_current_channel must be called  with a lock

Change-Id: I151564670946b3399158352c51d1670b9e7291fb
2017-01-03 14:39:21 +00:00
Mehdi Abaakouk
a7044799ad kafka: Don't hide unpack/unserialize exception
These exception are software bugs, don't convert them into
log for deployer.

Change-Id: I10e9112b53e5c754f38247679896d1d24dd454bf
2017-01-02 11:46:48 +01:00
Mehdi Abaakouk
c8880b6f11 kafka: timeout is in milliseconds
Change-Id: I791c5dd8e7f4fb46a0aea3e825b9b392686a2abd
2017-01-02 11:46:48 +01:00
Mehdi Abaakouk
799cd6fa8f kafka: disable batch for functional tests
Change-Id: I09a3049ca5f4647d0f6b002b3732a4c0edd43986
2017-01-02 11:46:48 +01:00
Mehdi Abaakouk
a76a51a78c kafka: Remove Producer singleton
This producer singleton works only if one transport use kafka.

If multiple transports with kafka are used, their overrides each other
the producer on each send.

This change creates only one producer per connection.

A later optimisation can be one producer per driver instance.

Change-Id: I429f7c5efcb41690dd1b17f856bda2425c788e53
2017-01-02 11:46:48 +01:00
Ilya Tyaptin
f139eb258d Moving driver to new kafka-python version
Currently Kafka driver for an oslo.messaging uses kafka-python==0.9.5
and mostly broken. This package version supports only low level Kafka
producer and consumer API which are marked as deprecated now [1]. Using
of these interfaces bring a big concern to the message processing,
because current KafkaConsumer has not any consuming coordination. This
fact causes a message duplication for the several consumers of one
topic. This behavior is specific to Ceilometer and services which read
and process notifications from other services.

New version of kafka-python allows to use async thread safe message
producers and coordinated consumers [1].

[1] http://kafka-python.readthedocs.io/en/master/changelog.html#feb-15-2016

The driver is currently experimental, python-kafka<1.0.0 API have major
issue described above that can't make the oslo.messaging driver works,
so we prefer having a working driver with a non-synced dependencies, that the
reverse.

Co-Authored-By: Mehdi Abaakouk <sileht@redhat.com>
Change-Id: I29862ed7bf56b9d8878fa8e9fb1cbd9d643908a4
2017-01-02 11:46:48 +01:00
Mehdi Abaakouk
8d2331a3b7 tox: rename zeromq target
The current zeromq target name are too long and reach the limitation
of 127 chars of the sheband of the virtualenv binary.

A target name must not be more than 22 chars to run in gate with
the tox job template.

This renames them to a shorter one.

It also creates aliases for the legacy jobs that we will remove
when the tox jobs are ready.

Change-Id: I5cbc368e7ea252f8c0c949c8e7ee3a70a560db22
2017-01-02 11:34:02 +01:00
Jenkins
8fefbc064d Merge "Updated from global requirements" 2016-12-30 04:30:47 +00:00
Jenkins
d265b49ac3 Merge "[zmq] Restore static direct connections" 2016-12-29 22:54:01 +00:00
OpenStack Proposal Bot
64914790f4 Updated from global requirements
Change-Id: I6375d299c56fb3789c9d37276dc0a6adb6ec4de8
2016-12-28 09:15:07 +00:00
Jenkins
1242564e4d Merge "reject when skipping failed messages" 2016-12-26 07:39:49 +00:00
Jenkins
99789d2381 Merge "test_rabbitmq: remove dead code" 2016-12-25 21:44:32 +00:00
ozamiatin
fe6cf0f8a2 [zmq] Restore static direct connections
Restore static direct connections which may be useful
for services running RPC on controllers only and talking
to agents via other means (ssh for example).

Change-Id: Icbe45978cb4a8ba5db74e5593ea7be23cba3f44e
2016-12-24 04:26:19 +02:00
Jenkins
b0507a6bdb Merge "[AMQP 1.0] Setup the amqp1 test environment on ubuntu" 2016-12-23 15:02:36 +00:00
gord chung
85b05a7f2f reject when skipping failed messages
reject is a more accurate action when we are tossing away messages
we cannot handle.

Change-Id: I7f40ac8809f93afb8e518f236d0ddf64a3b241eb
2016-12-21 16:03:24 +00:00
jolie
f1efaf1b6e fix one typo
Change-Id: Ie4ce6e4a8bad8610b40050c94bb3d0796f9f4d2f
2016-12-21 17:52:14 +08:00
Kenneth Giusti
2a9094af5d [AMQP 1.0] Setup the amqp1 test environment on ubuntu
Fixes the amqp1 functional tests so they can be run on Xenial.

Closes-Bug: 1643644
Change-Id: I3e3ee6779a60774ebffc1f45ae5564db934f8eaf
2016-12-19 14:47:04 -05:00
Julien Danjou
fd9f5073c7 test_rabbitmq: remove dead code
This method does not seem to be used by anything.

Change-Id: I71a0a6b12b45a4c7e2c4f301abda5a9cde3e777f
2016-12-19 10:30:51 +01:00
OpenStack Proposal Bot
ea61a81014 Updated from global requirements
Change-Id: I35e0f9e78c31a7c68746401dcf289f8648ef7e6a
2016-12-17 20:48:42 +00:00
Jenkins
d16e4883fe Merge "Replace mox with mock" 2016-12-17 18:42:26 +00:00
howardlee
de88370982 Replace mox with mock
Replace mox with mock in some files for testing.

See:
https://blueprints.launchpad.net/nova/+spec/remove-mox-ocata

Change-Id: Ic2a3c760d03d19c5a07d71796f24580393102163
2016-12-16 11:24:13 +01:00
Mehdi Abaakouk
04f9be69e5 tests: fix test-setup.sh
tox doesn't have quiet option, so we have to create the virtualenv first
and run bindep manually.

Change-Id: I3ae76278391baa5cd80202f32ad88b1368b0f16d
2016-12-15 09:41:29 +01:00
Jenkins
c805618d9a Merge "[AMQP 1.0] Simplify the I/O event loop code" 2016-12-09 17:26:34 +00:00
Jenkins
a88637253e Merge "tests: remove useless debug" 2016-12-09 16:57:59 +00:00
Mehdi Abaakouk
2f1ee2f71b tests: remove useless debug
It's useless to print the 250 events

Change-Id: Ib1e05bc20869a0892dfae4b4e45832ebce6373d8
2016-12-09 13:36:21 +01:00
Dmitry Mescheryakov
04f89a76f0 [rabbit] Log correct topic on cast/call
Change-Id: Icc06f7f0f99728fcf4abbdce0bf85af88713494a
2016-12-09 14:24:52 +04:00
OpenStack Proposal Bot
2c3ae0af3c Updated from global requirements
Change-Id: Icdcb2a730f2e01d7c4aad42bf4cb1cc3e7876eff
2016-12-08 20:11:30 +00:00
Jenkins
8f2852a627 Merge "Add bindep.txt/test-setup.sh to prepare the system" 2016-12-08 19:57:05 +00:00
Jenkins
92f7bf04a8 Merge "[zmq] Matchmaker redis available time" 2016-12-08 00:06:05 +00:00
Mehdi Abaakouk
37c0ae18dd kafka separate unit/functionnal tests
The kafka functional tests don't use our setup framework but hardcode
the kafka url.

The kafka driver is broken and currently try to be loaded with other
driver tests (and break py3 gate job).

This change remove the hardcoded stuff and uses the normal functional
tests setup to check kafka.

This avoids kafka tests to be ran on other driver tests job.

It also creates the tox target for functional tests and use
pifpaf to setup kafka.

As today, the functional test suite doesn't work all.

Change-Id: Ie6af35321905a04b38e549bf7268dd40543d9e3a
2016-12-07 18:39:36 +01:00
Jenkins
4a00697536 Merge "Show team and repo badges on README" 2016-12-07 15:26:27 +00:00
Mehdi Abaakouk
5fc28ec9cf Add bindep.txt/test-setup.sh to prepare the system
Change-Id: I9ac3132c082a31020dc2bf2a778fb5c4c0836c4c
2016-12-07 09:29:29 +01:00
Oleksii Zamiatin
adda657f6c [zmq] Matchmaker redis available time
Use zmq_target_expire rather than zmq_target_update
as it supposed to represent longer period of time so
all services will definitely be updated.

Change-Id: I0b9a1c8cbc7fea9b2c0c543a270dad318d135c1f
2016-12-06 12:14:43 +00:00
Jenkins
044e1bba82 Merge "[zmq] Support message versions for rolling upgrades" 2016-12-06 08:25:30 +00:00
Kenneth Giusti
41e23c2436 [AMQP 1.0] Simplify the I/O event loop code
Leverage the fact that there is never more than one socket active to
simplify the event loop's I/O processing.  This removes the need to
look up active connections.  Also removes the need to query the return
values from select since there is only one socket to process. This
change improves RPC throughput under the simulator by up to 20%

As part of this change I've clarified the code's use of the pyngus
connection by renaming the connection property to something a bit more
specific.

Change-Id: If7c020bb0bd96490af78bc06659db10073b02417
2016-12-05 19:49:06 -05:00
Jenkins
13dffe9913 Merge "Periodically purge sender link cache" 2016-12-05 22:43:56 +00:00
Jenkins
5c08aaeed3 Merge "Use assertGreater(len(x), 0) instead of assertTrue(len(x) > 0)" 2016-12-05 17:09:48 +00:00
Gevorg Davoian
656bc21d34 [zmq] Support message versions for rolling upgrades
Change-Id: I62b001ca396e3a87c061725db55184b2f1f869e3
Closes-Bug: #1524248
2016-12-05 11:50:01 +00:00
Jenkins
9efdc374e8 Merge "Register opts if we're going to check conf.transport_url in parse()" 2016-12-02 18:52:37 +00:00
Oleksii Zamiatin
7cb0683dc6 [zmq] Fix non voting gate jobs
Fix proxy configuration and create a valid transport_url.

Change-Id: I35f22376b8eb75c2cb2175f19435a806f3dca1c1
2016-12-02 17:12:43 +02:00
Mehdi Abaakouk
9d55749c05 Fix transport url with empty port
When transport url is set to something like "amqp://hostname:/"
it currently raise ValueError while any url parsing library
(like urlparse) just ignore the port, and don't fail since this is a
value url.

This change make the transport url ignore empty port instead of raising
ValueError.

Change-Id: I04df76012e3b133eddbcf365363cd261d277e369
2016-12-02 10:06:30 +00:00
Jenkins
7f2299f7e9 Merge "Remove ordering assumption from functional test" 2016-12-02 09:46:43 +00:00
Mehdi Abaakouk
9d1b90c7f5 Remove ordering assumption from functional test
oslo.messaging doesn't ensure ordering of notification. By chance
that works for some driver/setup. But for example zmq job often
fail this one.

This changes removes this assumption.

That fixes the zmq gate job

Change-Id: I2087f0a219a4a5b8fb30bb8ed84e1a72f8d9e0ab
2016-12-02 07:21:05 +01:00
Andrew Smith
3c9c97603f Periodically purge sender link cache
Closes-Bug: 1640266
Change-Id: Id38b756792f8fb14803bc9ead69e1fc903b9eea5
2016-12-01 10:31:56 -05:00