Remove six, the python 2/3 compatibility library. It's not needed
anymore since the repo is python3 only.
Remove a now unneeded hacking test.
Change-Id: I40522c4accb4aaf8115d11fee8b081e2d991cb4d
Log messages are no longer being translated. This removes all use of
the _LE, _LI, and _LW translation markers to simplify logging and to
avoid confusion with new contributions.
Change-Id: I9ddb6595fc52e46ed8844e39d2fa71029c90b65c
Closes-Bug: #1674567
there's only one scenario where the generator actually needs to be
forced into a list. don't waste time doing something unnecessary.
Change-Id: Iec897b1f6fed3d88b798eb673779e7c68ff930ec
groupby requires items to be sorted as it's clumping consecutive
items together. also, just use itemgetter instead of lambda
Change-Id: I1676fc60ebc2c9ff03ea00cc67061fdfb3b50868
Dispatcher should be responsible for routing message to the
callback method of endpoint object and returning result back to the
server only. But now it is also responsible for sending reply,
ack/reque messages etc.
Also this patch makes small improvements:
1) Notification dispatcher now requeue message if endpoint raises exception
2) unstable behaviour of test_mask_passwords test is fixed
Change-Id: I5f23e23644e90919cb67f81fc306ee85c5e09974
Revert the change I556b112371bec2ec29cea4dc254bb3f9c6d2c07a: the
executor callback API was only used by the aioeventlet executor which
was just removed.
Change-Id: I1223f32594d8c1be28cc43fdd9bf102c86d75325
1. Use translation marker functions, their argument must just be a string
2. Any message with more than one variable should use named
interpolation instead of positional to allow translators
to move the variables around in the string to account for
differences in grammar and writing direction.
3. String interpolation should be delayed to be handled by the logging
code, rather than being done at the point of the logging call.
For more details, please refert to oslo.i18n guideline [1]
Note: this commit doesn't touch test code.
[1] http://docs.openstack.org/developer/oslo.i18n/guidelines.html
Change-Id: I5f013d65b20396bbe0e5a2cceaed2a33fad1af23
The transport/driver features check is done into the get listener
methods.
So when these methods are not used the driver features checks is not
done.
This change moves it into the dispatcher layer to ensure the
requirements are always checked.
This changes a bit the behavior of when the check occurs. Before
it was during the listener object initialisation. Now this
when the listener server start.
Change-Id: I4d81a4e8496f04d62e48317829d5dd8b942d501c
Gnocchi performs better if measurements are write in batch
When Ceilometer is used with Gnocchi, this is not possible.
This change introduce a new notification listener that allows that.
On the driver side, a default batch implementation is provided.
It's just call the legacy poll method many times.
Driver can override it to provide a better implementation.
For example, kafka handles batch natively and take benefit of this.
Change-Id: I16184da24b8661aff7f4fba6196ecf33165f1a77
This change creates a dispatcher abstraction
to document the interface of a dispatcher.
And also allows in the futur to have attributes with default values.
Change-Id: I9a7e5e03f89635a3790b3851f492a1a7aab58feb
The context manager in the executor fit only for the blocking executor.
Even the dispatcher needs to run code before and after the application
callback, eventlet and future executors have to run the pre/post code
into the main thread and can run the callback into an other thread,
and that force them to run __enter__ and __exit__ manually and deal
the exception path.
This change adds a helper object instead of the context manager.
It is designed to be explicit on what must be executed
before and after the callback and what can be done in a thread or not.
All the executor code is now in the impl_pooledexecutor.py
and use the futures "PoolExecutor" API.
This use futurist to provide a eventlet and aioeventlet futures friendly
object.
Change-Id: I8cd7640f36beeda47560e3c82671bad3530e38d1
The NotificationFilter class is used to filter notifications that a
notification listerner endpoint will received.
The notification can be filtered on different fields: context,
publisher_id, event_type, metadata, and payload
DocImpact
Implements: blueprint notification-dispatcher-filter
Change-Id: Ic1239422fac9879b113c9d3d6c3f8dccef20d044
Move the public API out of oslo.messaging to oslo_messaging. Retain
the ability to import from the old namespace package for backwards
compatibility for this release cycle.
bp/drop-namespace-packages
Co-authored-by: Mehdi Abaakouk <mehdi.abaakouk@enovance.com>
Change-Id: Ia562010c152a214f1c0fed767c82022c7c2c52e7