Refactor current engine process to instantiate the concrete engine using
stevedore. The current engine uses importutils to load the concrete engine.
Since the executor is tightly coupled to the engine, it is also refactored
to use stevedore. The ScalableEngine is renamed to DefaultEngine and moved
to the mistral.engine.drivers.default namespace. The setup.cfg file is
updated to include entry points for the engine and executor plugins.
Change-Id: Ia9d15b25ca96387e5ac22c1a86cffc7a816e92fd
Implements: blueprint mistral-engine-plugin
* Rabbit configs are moved to 'default' section due to
oslo.messaging doesn't read these parameters from
section 'rabbit'
Change-Id: I39393a779076f36c6142d770efa268178437332b
Refactored engine to run as a standalone process. The engine is
modified to use the RPC client/server design pattern from
oslo.messaging. A new launch option is included to run the
engine separately. The API server communicates with the engine
via the RPC client. A pecan hook is used to pass a common client
instance with appropriate transport configuration to the API.
Change-Id: I9ca757aedad764fd38645a5b858800d69808bb95
Implements: blueprint mistral-engine-standalone-process
* Failure was in output transformer specified in retry_task.yaml.
* Added assertion back to enable the tests.
* Extra logging to include more context in the logs to gather more insight from the logs.
Change-Id: Ic6f4665cd4d74d2676fc17891dbf66984926cd42
* Created new log configuration for pretty workflow output.
* Since this config opt is used before importing
executor.server, I include some refactor of unit tests.
Implements blueprint mistral-pretty-workflow-logging
Change-Id: Ia9b8b5d401afafe99d6133685a4d3abbcb8ba2e3
* Removed redundant update task state - task is already in state RUNNING,
but in case of async action we are changing it one more time.
Change-Id: I60f02339432ef5f3945be9154718ef2229f0fdc7
* Fixed wrong convertation of action params and result.
In action parameters we can have an arbitrary dict, so
this dict can contain lists, or other dicts. To convert
params we should apply converter dict to base spec params
and action result accordingly.
Change-Id: I7549931c69637dfdf2bfa6583b8a78f8589b40b4
* It's now possible to specify common parameters in adhoc action
namespaces to avoid duplications in particular action definitions
* Fixed tests
Change-Id: I521ee7a42cad91e10608f9b0c2f7a74cb24e0465
* Since '$' is a valid expression it may be used to refer to
base action result in ad-hoc actions so using '$.base_output'
is redundant.
* Fixed module expressions.py so that YAQL expression '$' is
considered valid.
* Fixed corresponding test cases.
Change-Id: Ib7e534b3f9cc8fffb0f1626a987a8c8cc6eeddf6
* These tests should be rewritten to avoid race conditions. In
other words they pass not always.
TODO:
* Fix task retry tests.
Change-Id: I9b13bd9896b0bfc0f6d826e660cb7e2dbe441100
* These tests should be rewritten to avoid race conditions. In
other words they pass not always.
TODO:
* Fix task retry tests.
Change-Id: Ic92f6921cda70023b041de86887b3c1a85ee70cb
* Fixed HTTPAction result: To use expressions we need to
transform any action result to some expressions-readable
structure, e.g. dict. In case of HTTPActions we expose
status, content and headers. For example, if we recieved
response - {"server": "info" {"id": "some_id"}} we can
address to property 'id' using expression '$.content.server.id'
* Unit test
Change-Id: I9ecf4dc01f1ae084e27b29f46507c65fba9a6692
* Force raising ActionException in case if we can't convert result
in action output (e.g. we recieved a wrong result)
Change-Id: I2d16e0c8ff3a9050674d6d8ba44b29da822aec7c
* Fixed defaults for parameter 'data' in HTTPAction and MistralHTTPAction
* Small fix in abstract_engine.py related to adhoc acitons
Change-Id: I25c1b0581b17ca5c3e419b260a5bcc0e3c938ec5
* Retry is only attempted if task responds with error. Successful tasks do
not have to be retried which is the primary difference repeat and retry.
* Once a retry is triggered delay and break-on are taken into considertaion.
Modified tests appropriately and renamed types and properties appropriately.
Change-Id: I660cac05c20e791c0620add99d9d348f4bd910d1
* Switched from raw action spec (dict) to using ActionSpec in
ad-hoc actions
TODO:
* Fix all samples in mistral-extra
* Action plugin architecture
Change-Id: Id8da3642bcd9549bf2e64c07eb4d79fd856a01de
* Removed obsolete packages
* Fixed arguments order in assertions as pointed by Sergey Murashov in
https://review.openstack.org/#/c/85653/6/
TODO:
* Fix all samples in mistral-extra
* Action plugin architecture
Change-Id: I120363da862786e081f6eb0df2ae9cd5a434659c
* Added standard SSH action (based on SSHAction in engine/actions/actions.py)
* Added tests for SSH action
TODO:
* Fix all samples in mistral-extra
* Action plugin architecture
Change-Id: Ie00630a4b43f289888c3d3ce705857c45d738ae6
* Refactored action_factory.py (adhoc actions into a separate method)
* Fixed task db model (service_spec -> action_spec)
* Fixed workbook model (tasks, actions, Service -> Namespace)
* Fixed all tests related to DSL syntax changes
TODO:
* Fix all samples in mistral-extra
* Action plugin architecture
Change-Id: Iac6317dde894f17c81332a8c9a2397b70448f6b2
* Fixing action factory to create ad-hoc actions if needed
* More tests for action factory
TODO:
* Refactoring executor to use new action infrastructure
* Remove old action infrastructure
* Action plugin architecture
Partially implements: blueprint mistral-actions-design
Change-Id: I69946989226a1c05ed089acccb7e10a6516cf966