Various components defines different options for the client sessions.
Standardize them with the help of keystonauth1 lib.
Change-Id: I2f791caaf230a58b8426d1c1d6e1eb4316a85a28
1.As mentioned in [1], we should avoid using six.iteritems to achieve
iterators. We can use dict.items instead, as it will return iterators
in PY3 as well. And dict.items/keys will more readable.
2.In py2, the performance about list should be negligible, see the
link [2].
[1] https://wiki.openstack.org/wiki/Python3
[2] http://lists.openstack.org/pipermail/openstack-dev/2015-June/066391.html
Change-Id: I45fa65427318e1c35bb521de46e81ea12ca7b770
Currently, murano.cfapi.cfapi throws 2 bugs, when certain
branches are reached.
1) An AttributeError is thrown by _get_muranoclient, because
CONF.cfapi is accessed; however, cfapi is not a defined
group in murano.common.conf. The group should instead be
CONF.engine, where packages_service is located.
2) A NameError can be thrown by get_last_operation, in the
unlikely situation when m_environment.status is not contained
in any of the cases enumerated in the if/elif branches;
when this happens, 'resp' is returned without being defined,
resulting in this error.
3) Not a bug per se, but a LOG.warning statement is not formatted
correctly in get_last_operation. It does not specify the
instance_id in the error message.
Change-Id: If91a0f8f700a9c0cda0ea85a1d37938f5ef8f98c
Closes-Bug: #1661065
According to http://docs.openstack.org/developer/oslo.i18n/
guidelines.html#log-translation,log messages are recommended to use log
translation marker.
Change-Id: Id1f2ef10eb65dcda6fa629d51a51870af2390548
Rewrite docstrings in murano/common/wsgi.py to make it
more clear. Fix typo in other files.
TrivialFix
Change-Id: Iaa6bde5f3b0356b6ac9e67f39ebf0f7feff4ee45
We are replacing all usages of the 'retrying' package with
'tenacity' as the author of retrying is not actively maintaining
the project. Tenacity is a fork of retrying, but has improved the
interface and extensibility (see [1] for more details). Our end
goal here is removing the retrying package from our requirements.
Tenacity provides the same functionality as retrying, but has the
following major differences to account for:
- tenacity uses seconds rather than ms as retrying did.
- tenacity has different kwargs for the decorator and
Retrying class itself.
- tenacity has a different approach for retrying args by
using classes for its stop/wait/retry kwargs.
- By default tenacity raises a RetryError if a retried callable
times out; retrying raises the last exception from the callable.
Tenacity provides backwards compatibility here by offering
the 'reraise' kwarg.
- tenacity defines 'time.sleep' as a default value for a kwarg.
That said consumers who need to mock patch time.sleep
need to account for this via mocking of time.sleep before
tenacity is imported.
This patch updates all usages of retrying with tenacity.
Unit tests will be added where applicable.
Note: This change is not newton critical so projects are welcome
to hold off on committing until post-newton. Ideally this change
will merge by the first part of Ocata so dependant functionality
can land and have time to solidify for Ocata.
[1] https://github.com/jd/tenacity
Change-Id: I18a0075e9a7c376b6881555ce67267a8944caafa
After separation service broker from native murano on the configs/db
level GLARE support was broken. This patch updates config, devstack
script and partially service broker itself to take support back.
Change-Id: I0ea99bc491ba2ddebfc34a9c0aa681432aca7801
Closes-Bug: #1610130
1.Add the devstack support for new cfapi
2.service broker use separate paste file
3.service broker use separate db
Closes-Bug: #1500777
Closes-Bug: #1500827
Change-Id: I2842828fe14878e6ff5ac194473f2ffa619370df
partial-implement: bp separate-service-broker-from-murano
Create separate murano-cfapi-paste.ini for service broker,
Change service broker start command to:
`murano-cfapi --config-file etc/murano/murano-cfapi.conf`
And move service broker api to the top level.
Change-Id: Id56786f31c16da11019a2064cc4285bdd266f538
partial-implement: bp separate-service-broker-from-murano