Now when create a claim with a big number, the message is not
correct. It's showing the max TTL of message instead of claim.
This patch fixes it.
Closes-Bug: #1575870
Change-Id: Ia948cc521a48101fa17ec23f49b5b03164f02940
Currently, when querying queue, Zaqar will return
the _default_message_ttl and _max_messages_post_size,
for _default_message_ttl, it's value is 1209600
if user didn't set it, but it's not correct.
It should be 3600 by default.
APIImpact
Change value of _default message_ttl to 3600
Change-Id: I6b999e56806c6ddcf47190a1fb1953ae373d1ad3
Closes-Bug: #1569663
Now when access the root path of Zaqar service, for example:
curl GET http://127.0.0.1:8888/, user will see 401 error. Which
will cause some front end proxy(like HAProxy) complain. This
patch fixes the issue.
Closes-Bug: #1569474
Change-Id: I92c98495bf26277cd4c8c1d019c54698cace4bbd
In IPv6 management network environment, starting Zaqar server will
run into 'Address family for hostname not support' when use WSGI
simple server. The root cause is python TCPServer implementation
is hard-coded to use IPv4, even in IPv6 environments. Fix stolen
from Ceilometer.
Closes-Bug: #1569133
Change-Id: I708bf40526c1ff1632c0034e5758c6725a517ca1
Currently Zaqar will support more built-in/reserved
attributes in queue.
We add two important attributes max_messages_post_size
and max_message_ttl.
So it's very useful for users that if they create a queue without
metadata, when they query queue, Zaqar add those two attributes from
config to queue metadata and then return.
That will not be stuck if config is changed and user also can
know what value it is.
APIImpact
DocImpact
Change-Id: Icf9af8e357b2e2df363cd28ef3ca7f7f97a77744
Implements: blueprint show-default-attributes-for-queue
meta:version: 2.0.0
meta:series: mitaka
meta:release-type: release
meta:announce: openstack-announce@lists.openstack.org
meta:pypi: no
meta:first: yes
-----BEGIN PGP SIGNATURE-----
Comment: GPGTools - http://gpgtools.org
iQEcBAABAgAGBQJXBg/3AAoJEDttBqDEKEN6RdcH/iuKxRjuJ3Hqffu0pjyFhwnn
SHr17VAoEpGEP8m1ur7PC0TOVPry2PazWaJ71a86DpW29KJdntWd458IYYUdVqKO
Q3tukakx8lCs6AMuSfuLMEtPKg1eFwcLOa8PvggWA3rAbl/9qGNcy2YzgPUIS+7M
fiRUL+hkciVqF/vNBkyAfHV8gH3zdyPQfgwHXLCr+lrg+LVAypUkvKQVgbHTEGv4
0+c3BHFGXniHlu5sWopMuc+z9aWIfAV66PUL5TJCxXZPm1p/VONX9F05FZ4JAThg
SaPO9wrv1SSLTgoyIVfBRjeJP3j5tSOASiG95CcFMyu/vnlEcu1bXL+SIrg8A4M=
=0yfm
-----END PGP SIGNATURE-----
Merge tag '2.0.0'
This is a null-merge of the 2.0.0 release tag back into the master
branch so that the 2.0.0 tag will appear in the git commit history of
the master branch. It contains no actual changes to the master branch,
regardless of how our code review system's UI represents it. Please
ask in #openstack-infra if you have any questions, and otherwise try
to merge this as quickly as possible to avoid later conflicts on the
master branch.
Change-Id: Iae0d9bc98a6dad492dd0c25ccb0fb9888063e817
Running command `testr list-tests zaqar` under tempest directory
get an empty list instead of the list of zaqar tempest list. This
patch set bath_path to the top directory of zaqar.
Change-Id: I8c91b83bfb5da37a95d6a797f1882221ccdc437a
Closes-Bug: #1563925
When creating pre-signed url, if expire time is set
as some special string like "'expires'='3600'",
after creation is done, the expire time will be
"3600-01-01T00:00:00", that means this url will be
valid until the year 3600!
So we should check the data format of expire time,
if it's a string of integer value, zaqar should return error.
Change-Id: I61d2d977d45b5d33ff3355f2c854215ee1a52bb2
Closes-Bug: #1561311
We recently introduced reserved queue metadata feature in our API v2.
And because it's a feature of API v2, we decided not to change at all
our older APIs. But through our older APIs it's possible to PUT invalid
queue attributes, which can cause unstable work of API v2.
This patch makes API v1 restrict any metadata keys which names start
with "_", because they are probably reserved queue attributes.
This patch makes API v1.1 validate metadata like API v2 validates it now
to ensure that the reserved queue attributes have valid values, before
sending them to the database.
This patch also adds unit tests to APIs.
APIImpact
Closes-Bug: 1557247
Change-Id: Idcd063787c8d8da49a9c3d126441f9336c85e7cd
(cherry picked from commit 400fc6ec7de96f1119fd4d9dc4130374d6ca5895)
We recently introduced reserved queue metadata feature in our API v2.
And because it's a feature of API v2, we decided not to change at all
our older APIs. But through our older APIs it's possible to PUT invalid
queue attributes, which can cause unstable work of API v2.
This patch makes API v1 restrict any metadata keys which names start
with "_", because they are probably reserved queue attributes.
This patch makes API v1.1 validate metadata like API v2 validates it now
to ensure that the reserved queue attributes have valid values, before
sending them to the database.
This patch also adds unit tests to APIs.
APIImpact
Closes-Bug: 1557247
Change-Id: Idcd063787c8d8da49a9c3d126441f9336c85e7cd
v1.0 has been deprecated for a while now but it's still on by default.
V1.1, on the other hand, is still supported but on its way to being
deprecated. Warn users that both APIs will be turned off by default
during the Newton cycle.
Change-Id: Ibd6e12bd9a8ba414bb9ea26136a5acc1ca092142
(cherry picked from commit eb3dcee2389394eb62ff0f5a12acad7c6057a361)
Currently generated zaqar.conf.sample is missing oslo.cache library
options, but they are used by Zaqar and are important in production
install.
This patch makes the command 'tox -e gencofig' generate also oslo.cache
options.
Change-Id: Ia8f78fd5a106888882f882aed8d8355e7e1e459e
Closes-Bug: 1560707
v1.0 has been deprecated for a while now but it's still on by default.
V1.1, on the other hand, is still supported but on its way to being
deprecated. Warn users that both APIs will be turned off by default
during the Newton cycle.
Change-Id: Ibd6e12bd9a8ba414bb9ea26136a5acc1ca092142
Currently, the way queue's PATCH HTTP method is implemented in API v2 is
not correct.
This patch makes PATCH HTTP method to work as RFC6902 recommends:
http://tools.ietf.org/html/rfc6902
This patch adds tests.
This patch makes Zaqar return 404 response in the case when the user
tries to perform PATCH on non-existing queue.
APIImpact
DocImpact
Closes-Bug: #1553002
Co-Authored-By: Fei Long Wang <flwang@catalyst.net.nz>
Co-Authored-By: Eva Balycheva <ubershy@gmail.com>
Change-Id: Id1f02c63e8f078ddb657d3e9bc83ac0668672748
Now, if you try to run Zaqar on Websocket driver with fresh 'autobahn'
library, Zaqar will fail:
TypeError: __init__() got an unexpected keyword argument 'debug'
Websocket-related tests now fail too.
The 'debug' option for instantiating websocket WebSocketServerFactory
was deprecated and recently it was finally removed from 'autobahn'
library.
This patch makes Zaqar not pass 'debug' option to WebSocketServerFactory
constructor. The change will not affect logging and will just fix the
problem.
Change-Id: Ifebf849b278f95438ed87ca50ff8cc48ad159104
Closes-Bug: 1558062
Now, if you will try to run two times this command:
tox -e py27 wsgi.v2_0.test_validation.TestValidation.test_queue_metadata
_putting
You will see: MismatchError: '201 Created' != '204 No Content'
This is because cleanUp() is not written good in this test case.
self.simulate_delete function has missing argument: project id, so the
default project id is used instead during cleanUp().
The problem went unnoticed, because we usually run all tests. And when
all tests run the database is somehow cleaned in the place we need to
clean.
Change-Id: Id0241aeb76aabcb5e57098b0f02d26e62aead42e
Now when we update subscription and specify TTL, subscription is not
renewed. It's life is not extended, and it's expiration date is still
old.
Because of that, it's impossible to extend life of subscription without
recreating it. But during subscription recreation some messages may not
be sent to subscriber, because there will be a moment when subscription
does not exist, which is bad.
This patch makes subscriptions renewable by PATCH method, when TTL is
specified in the body. In such case PATCH method sets subscription TTL
to a new value and sets expiration date to a recalculated value: current
time + TTL.
This patch also adds two functional tests for testing TTL-related things
in subscriptions. This increases functional testing time by ~2-4
minutes.
APIimpact
Closes-Bug: #1552866
Co-Authored-By: wangxiyuan <wangxiyuan@huawei.com>
Co-Authored-By: Eva Balycheva <ubershy@gmail.com>
Change-Id: I048c37d6485ff27cf18ed27988874e470301fb57
Now if users update a subscription in a queue, it doesn't check the
legality of the new subscriber. We should forbid update subscription to
duplicate and return 409 response in such case.
This patch modifies Redis and MongoDB storage controllers and API v2.
It also adds unit tests for them.
The functional test will be updated in zaqar client.
APIimpact
Closes-Bug: #1545548
Closes-Bug: #1547131
Co-Authored-By: wangxiyuan <wangxiyuan@huawei.com>
Co-Authored-By: Eva Balycheva <ubershy@gmail.com>
Change-Id: I28fe7a114860488c503642417690bf5bfbd99678
Now, if you try to update subscription in Redis and specify new options,
these options will be written to database in plain text format instead
of MessagePack format.
Then, if you try to get this subscription, Zaqar will return response
with code 503. Internally Zaqar will experience a problem while trying
to unpack subscription's options.
This patch makes Redis driver on HTTP PATCH method pack subscription
options in MessagePack format, before sending changes to database.
Change-Id: Ic3940b5093021c0d0cc5c345acabe29804d5a291
Closes-Bug: 1554683
Now there is no way to update metadata after queue create.
That because we were trying to remove metadata but finally we
decided to keep it. As a result, we missed a way to update queue's
metadata. This patch fixes it buy supporting PATCH for queue. And
a test case is added.
APIImpact
DocImpact
Closes-Bug: #1543900
Change-Id: Iba6d7a0ca5cf7a755c20d9af69d5c52687142dff