Changelog History
Page 4
-
v2.3.2 Changes
July 28, 2017β Added
* β Add test coverage and test timing capabilities to ``st2-run-pack-tests``. The ``-c`` option enables test coverage and the ``-t`` option enables test timings. These capabilities have also been enabled in the ci pipeline for packs in the exchange. Contributed by Nick Maludy. #3508 * β Add ability to explicitly set ``stream_url`` in st2client. (improvement) #3432 * β Add support for handling arrays of dictionaries to ``st2 config`` CLI command. (improvement) #3594 Contributed by Hiroyasu OHYAMA. π Changed
- β‘οΈ Update
st2
CLI so it also displays "there are more results" note when-n
flag is used and there are more items available. (improvement) #3552
π Fixed
* π Fix st2client to display unicode characters in pack content description. (bug-fix) #3511 * Don't automatically append ``.git`` suffix to repo URIs passed to ``packs.download`` action. This fixes a bug and now action also works with repo urls which don't contain ``.git`` suffix. (bug fix) Contributed by carbineneutral. #3534 #3544 * st2 pack commands now work when StackStorm servers are behind a HTTP/HTTPS proxy. You can set ``http_proxy`` or ``https_proxy`` environment variables for ``st2api`` and ``st2actionrunner`` processes and pack commands will work with proxy. Refer to documentation for details on proxy configuration. (bug-fix) #3137 * π Fix API validation regression so all input data sent to some POST and PUT API endpoints is correctly validated. (bug fix) #3580 * π Fix an API bug and allow users to create rules which reference actions which don't yet exist in the system when RBAC is enabled and user doesn't have system admin permission. (bug fix) #3572 #3573 Reported by sibirajal. * β Add a check to make sure action exists in the POST of the action execution API. (bug fix) * π Fix api key generation, to use system user, when auth is disabled. (bug fix) #3578 #3593 * π Fix invocation of Mistral workflow from Action Chain with jinja in params. (bug fix) #3440 * π Fix st2client API bug, a backward incompatible change in ``query()`` method, introduced in note implementation (#3514) in 2.3.1. The ``query()`` method is now backward compatible (pre 2.3) and ``query_with_count()`` method is used for results pagination and note. #3616 * π Fix logrotate script so that it no longer prints the ``st2ctl`` PID status to stdout for each file that it rotates. Also, it will no longer print an error if ``/var/log/st2/st2web.log`` is missing. Contributed by Nick Maludy. #3633
- β‘οΈ Update
-
v2.3.1 Changes
July 07, 2017β Added
* β Add support for ``passphrase`` parameter to ``remote-shell-script`` runner and as such, support for password protected SSH key files. (improvement) Reported by Sibiraja L, Nick Maludy. * β Add ``json_escape`` Jinja filter for escaping JSON strings. (improvement) Contributed by mierdin. #3480 * π¨ Print a note to stderr if there are more entries / results on the server side which are displayed to the user for the following ``list`` CLI commands: ``rule``, ``execution``, ``rule-enforcment``, ``trace`` and ``trigger-instance``. Default limit is 50. (improvement) Reported by Eugen C. #3488 π Changed
- β‘οΈ Update
st2 run
/st2 execution run
command to display result of workflow actions when they finish. In the workflow case, result of the last task (action) of the workflow is used. (improvement) #3481 - β‘οΈ Update Python runner so it mimics behavior from StackStorm pre 1.6 and returns action result as is (serialized as string) in case we are unable to serialize action result because it contains non-simple types (e.g. class instances) which can't be serialized.
In v1.6 we introduced a change when in such instances, we simply returned
None
as result and didn't log anything which was confusing. (improvement) #3489Reported by Anthony Shaw.
- β Add missing pagination support to
/v1/apikeys
API endpoint. (improvement) #3486 - β‘οΈ Update action-chain runner so a default value for
display_published
runner parameter isTrue
. This way it's consistent with Mistral runner behavior and intermediate variables published inside action-chain workflow are stored and displayed by default. #3518 #3519
Reported by Jacob Floyd.
- β¬οΈ Reduce API service (
st2api
) log clutter and log whole API response (API controller method return value / response body) underDEBUG
log level instead ofINFO
. (improvement) #3539
Reported by Sibiraja L.
- Enforce validation on
position
parameter for action parameters. If position values are not sequential or not unique, action registration will now fail. (bug-fix) (improvement) #3317 #3474
π Deprecated
* π§ Deprecate ``results_tracker`` config group and move configuration variables to ``resultstracker`` group instead. If you have ``results_tracker`` config group in the config, it is recommended to switch to ``resultstracker`` instead. (bug-fix) #3500 π Fixed ~~~~~ * π Fix ``?name`` query param filter in ``/v1/actionalias`` API endpoint. (bug fix) #3503 * Notifier now consumes ``ActionExecution`` queue as opposed to ``LiveAction`` queue. With this change, the Jinja templates used in notify messages that refer to keys in ``ActionExecution`` resolve reliably. Previously, there was a race condition in which a ``LiveAction`` would have been updated but ``ActionExecution`` was not and therefore, the jinja templates weren't reliably resolved. (bug-fix) #3487 #3496 Reported by Chris Katzmann, Nick Maludy. * β‘οΈ Update config loader so it correctly handles config schema default values which are falsey (``False``, ``None``, ``0``, etc.) (bug-fix) #3504 #3531 Reported by Simas Δepaitis. * π Fix ``st2ctl register`` failure to register rules in some race conditions. ``st2-register-content`` will now register internal trigger types by default. (bug-fix) #3542 * Correctly use service token TTL when generating temporary token for datastore service. This fixes a bug and allows user to set TTL value for non service tokens to less than 24 hours. (bug fix) #3523 #3524 Reported by theuiz.
- β‘οΈ Update
-
v2.3.0 Changes
June 19, 2017β Added
* Introduce new ``CAPABILITIES`` constant on auth backend classes. With this constant, auth backends can advertise functionality they support (e.g. authenticate a user, retrieve information about a particular user, retrieve a list of groups a particular user is a member of). (new feature) * β Add support for automatic RBAC role assignment based on the remote auth backend groups user is a member of (e.g. LDAP groups) and mappings defined in ``/opt/stackstorm/rbac/mappings`` directory. Note: This functionality is currently implemented for enterprise LDAP auth backend and only available in enterprise edition. (new feature) * π Allow user to specify a custom list of attribute names which are masked in the log messages by setting ``log.mask_secrets_blacklist`` config option. (improvement) * β Add webhook payload to the Jinja render context when rendering Jinja variable inside rule criteria section. * Implement RBAC for traces API endpoints. (improvement) * Implement RBAC for ``API_KEY_CREATE`` permission type. (improvement) * Implement RBAC for timers API endpoints. (improvement) * Implement RBAC for webhooks get all and get one API endpoint. (improvement) * Implement RBAC for policy types and policies get all and get one API endpoint. (improvement) * β Add new ``/v1/rbac/role_assignments`` API endpoint for retrieving user role assignment information. (new feature) * β Add CLI commands for listing RBAC roles: * ``st2 role list [--system]`` * ``st2 role get <role id or name>`` * β Add CLI commands for listing RBAC user role assignments: * ``st2 role-assignment list [--role=<role name>] [--user=<username>]`` * ``st2 role-assignment get <role assignment id>`` * β Add the following new actions to ``chatops`` pack: * ``chatops.match`` * ``chatops.match_and_execute`` * ``chatops.run`` #3425 [Anthony Shaw] * β Add new ``examples.forloop_chain`` action-chain workflow to the examples pack which demonstrates how to iterate over multiple pages inside a workflow. #3328 [Carles Figuerola] * β Add new ``core.uuid`` action for generating type 1 and type 4 UUIDs. [John Anderson] #3414 π Changed
- π¨ Refactor the action execution asynchronous callback functionality into the runner plugin architecture. (improvement)
- π§ Linux file watch sensor is now disabled by default. To enable it, set
enabled: true
in/opt/stackstorm/packs/linux/sensors/file_watch_sensor.yaml
- β‘οΈ Update the code so user can specify arbitrary default TTL for access tokens in
st2.conf
and all the StackStorm services which rely on access tokens still work.
Previously, the lowest TTL user could specify for all the services to still work was 24 hours. This has been fixed and the default TTL specified in the config now only affects user access tokens and services use special service access tokens with no max TTL limit. (bug fix)
Reported by Jiang Wei. #3314 #3315
- β‘οΈ Update
/executions/views/filters
API endpoint so it excludes null / None from filter values for fields wherenull
is not a valid field value. (improvement)
Contributed by Cody A. Ray. #3193
- Require
ACTION_VIEW
permission type to be able to access entry_point and parameters actions view controller. (improvement) - Update
/v1/rbac/permission_types
and/v1/rbac/permission_types/<resource type>
API endpoint to return a dictionary which also includes a description for each available permission type. (improvement) - Require
EXECUTION_VIEWS_FILTERS_LIST
RBAC permission type to be able to access/executions/views/filters
API endpoint. (improvement) - β Add webhook payload to the Jinja render context when rendering Jinja variable inside rule criteria section
- Switch file_watch_sensor in Linux pack to use trigger type with parameters. Now you can add a
rule with
file_path
and sensor will pick up thefile_path
from the rule. A sample rule is provided incontrib/examples/rules/sample_rule_file_watch.yaml
. (improvement) - Cancel actions that are Mistral workflow when the parent workflow is cancelled. (improvement)
- β¬οΈ Upgrade various internal Python library dependencies to the latest stable versions (pyyaml, requests, appscheduler, gitpython, paramiko, mongoengine, tooz).
- β‘οΈ Update
/v1/rbac/roles
API endpoint so it includes corresponding permission grant objects. Previously it only included permission grant ids. (improvement) - β± When RBAC is enabled and action is scheduled (ran) through the API, include
rbac
dictionary withuser
androles
action_context
attribute. (improvement) - π§ Make the query interval to third party workflow systems (including mistral) a configurable
value. You can now set
query_interval
in[results_tracker]
section in/etc/st2/st2.conf
. With this, the default query interval is set to 20s as opposed to 0.1s which was rather aggressive and could cause CPU churn when there is a large number of outstanding workflows. (improvement) - 0οΈβ£ Let
st2 pack install
register all available content in pack by default to be consistent withst2 pack register
. (improvement) #3452 - π§ The
dest_server
parameter has been removed from thelinux.scp
action. Going forward simply specify the server as part of thesource
and / ordestination
arguments. (improvement) #3335 #3463 [Nick Maludy] - β Add missing database indexes which should speed up various queries on production deployments with large datasets. (improvement)
- 0οΈβ£ Use a default value for a config item from config schema even if that config item is not required
(
required: false
). (improvement)
Reported by nmlaudy. #3468 #3469
- π Removing empty
config.yaml
for packs pack so warning isn't thrown by default now that deprecation warning is in place. (improvement)
β Removed
* π Drop support for invalid semver versions strings (e.g. ``2.0``) in pack.yaml pack metadata. Only full semver version strings are supported, e.g. ``2.1.1``. This was originally deprecated in v2.1.0. π Deprecated
- β Packs containing
config.yaml
will now generate a WARNING log on pack registration. Support forconfig.yaml
will be removed in StackStorm 2.4. Migrate your pack configurations now.
π Fixed
* β‘οΈ Update st2rulesengine to exit non-0 on failure (bug fix) #3394 [Andrew Regan] * π Fix a bug where trigger parameters and payloads were being validated regardless of the relevant settings in the configuration (``system.validate_trigger_payload``, ``system.validate_trigger_parameters``). (bug fix) * π Fix ``system=True`` filter in the ``/v1/rbac/roles`` API endpoint so it works correctly. (bug fix) * π Fix a bug where keyvalue objects weren't properly cast to numeric types. (bug fix) * π· When action worker is being shutdown and action executions are being abandoned, invoke post run on the action executions to ensure operations such as callback is performed. (bug fix) * π Fix action chain runner workflows so variables (vars) and parameter values support non-ascii (unicode) characters. (bug fix) * π Fix a bug in query base module when outstanding queries to mistral or other workflow engines could cause a tight loop without cooperative yield leading to 100% CPU usage by st2resultstracker process. (bug-fix) * Ignore unicode related encoding errors which could occur in some circumstances when ``packs.setup_virtualenv`` fails due to a missing dependency or similar. (improvement, bug fix) #3337 [Sean Reifschneider] * β‘οΈ Update ``st2-apply-rbac-definitions`` so it also removes assignments for users which don't exist in the database. (improvement, bug fix) * π Fix a bug where action runner throws KeyError on abandoning action executions during process shutdown. (bug fix) * π Fix URL parsing bug where percent encoded URLs aren't decoded properly (bug fix) * β‘οΈ The API endpoint for searching or showing packs has been updated to return an empty list instead of ``None`` when the pack was not found in the index. (bug fix) π Security
- π Make sure all the role assignments for a particular user are correctly deleted from the database
after deleting an assignment file from
/opt/stackstorm/rbac/assignments
directory and runningst2-apply-rbac-definitions
tool. (bug fix)
-
v2.2.1 Changes
April 03, 2017β Added
* π Allow user to specify which branch of ``st2tests`` repository to use by passing ``-b`` option to ``st2-self-check`` script. (improvement) * β‘οΈ Update ``tooz`` library to the latest version (v1.15.0). Using the latest version means StackStorm now also supports using ``consul``, ``etcd`` and other new backends supported by tooz for coordination. (improvement) π Fixed
- π Fix
st2ctl reload
command so it preserves exit code fromst2-register-content
script and correctly fails on failure by default. - π Fix base action alias test class (
BaseActionAliasTestCase
) so it also works if the local pack directory name doesn't match the pack name (this might be the case with new pack management during development where local git repository directory name doesn't match pack name) (bug fix) - π Fix a bug with default values from pack config schema not being passed via config to Python
runner actions and sensors if pack didn't contain a config file in
/opt/stackstorm/configs
directory. (bug fix)
Reported by Jon Middleton.
- β
Make various improvements and changes to
st2-run-pack-tests
script so it works out of the box on servers where StackStorm has been installed using packages. (improvement) - π Fix a bug with authentication middleware not working correctly when supplying credentials in an
Authorization header using basic auth format when password contained a colon (
:
).
Note: Usernames with colon are still not supported. (bug fix)
Contributed by Carlos.
- β‘οΈ Update
st2-run-pack-tests
script so it doesn't try to install global pack test dependencies (mock, unittest2, nose) when running in an environment where those dependencies are already available. - π Make sure remote command and script runner correctly close SSH connections after the action execution has completed. (bug fix)
Reported by Nagy KrisztiΓ‘n.
- π Fix a bug with pack configs API endpoint (
PUT /v1/configs/
) not working when RBAC was enabled. (bug fix)
Reported by efenian.
- π Fix concurrency related unit tests to support upgrade of the tooz library. (bug fix)
- π Fix a bug with config schema validation not being performed upon registration which could cause bad or empty config schema to end up in the system. (bug fix)
π Security
* β Removed support for medium-strength ciphers from default nginx configuration (#3244) * π Various security related improvements in the enterprise LDAP auth backend. (improvement, bug fix)
- π Fix
-
v2.2.0 Changes
February 27, 2017β Added
* π Use the newly introduced CANCELLED state in mistral for workflow cancellation. Currently, st2 put the workflow in a PAUSED state in mistral. (improvement) * β Add support for evaluating Jinja expressions in mistral workflow definition where yaql expressions are typically accepted. (improvement) * β‘οΈ Update the dependencies and the code base so we now also support MongoDB 3.4. Officially supported MongoDB versions are now MongoDB 3.2 and 3.4. Currently default version installed by the installer script still is 3.2. (improvement) * Introduce validation of trigger parameters when creating a rule for non-system (user-defined) trigger types. Validation is only performed if ``system.validate_trigger_parameters`` config option is enabled (it's disabled by default) and if trigger object defines ``parameters_schema`` attribute. Contribution by Hiroyasu OHYAMA. #3094 * π° Introduce validation of trigger payload for non-system and user-defined triggers which is performed when dispatching a trigger inside a sensor and when sending a trigger via custom webhook. Validation is only performed if ``system.validate_trigger_payload`` config option is enabled (it's disabled by default) and if trigger object defines ``payload_schema`` attribute. Contribution by Hiroyasu OHYAMA. #3094 * β Add support for ``st2 login`` and ``st2 whoami`` commands. These add some additional functionality beyond the existing ``st2 auth`` command and actually works with the local configuration so that users do not have to. * β Add support for complex rendering inside of array and object types. This allows the user to nest Jinja variables in array and object types. * β Add new ``-j`` flag to the ``st2-run-pack-tests`` script. When this flag is specified script will just try to run the tests and it won't set up the virtual environment and install the dependencies. This flag can be used when virtual environment for pack tests already exists and when you know dependencies are already installed and up to date. (new feature) π Changed
- β‘οΈ Mistral fork is updated to match the master branch at OpenStack Mistral. (improvement)
- π Update Python runner to throw a more user-friendly exception in case action metadata file references a script file which doesn't exist or which contains invalid syntax. (improvement)
- β‘οΈ Update
st2auth
service so it includes more context and throws a more user-friendly exception when retrieving an auth backend instance fails. This makes it easier to debug and spot various auth backend issues related to typos, misconfiguration and similar. (improvement) - π Let querier plugin decide whether to delete state object on error. Mistral querier will delete state object on workflow completion or when the workflow or task references no longer exists. (improvement)`
β Removed
* ``{{user.}}`` and ``{{system.}}`` notations to access user and system scoped items from datastore are now unsupported. Use ``{{st2kv.user.}}`` and ``{{st2kv.system.}}`` instead. Please update all your content (actions, rules and workflows) to use the new notation. (improvement) π Fixed ~~~~~ * π Fix returning a tuple from the Python runner so it also works correctly, even if action returns a complex type (e.g. Python class instance) as a result. (bug fix) Reported by skjbulcher #3133 * π Fix a bug with ``packs.download`` action and as such as ``pack install`` command not working with git repositories which used a default branch which was not ``master``. (bug fix) * π Fix a bug with not being able to apply some global permission types (permissions which are global and not specific to a resource) such as pack install, pack remove, pack search, etc. to a role using ``st2-apply-rbac-definitions``. (bug fix) * π Fix ``/v1/packs/views/files/<pack ref or id>`` and ``/v1/packs/views/file/<pack ref or id>/<file path>`` API endpoint so it works correctly for packs where pack name is not equal to the pack ref. (bug fix) Reported by skjbulcher #3128 * π Improve binary file detection and fix "pack files" API controller so it works correctly for new-style packs which are also git repositories. (bug fix) * π Fix cancellation specified in concurrency policies to cancel actions appropriately. Previously, mistral workflow is orphaned and left in a running state. (bug fix) * If a retry policy is defined, action executions under the context of a workflow will not be retried on timeout or failure. Previously, action execution will be retried but workflow is terminated. (bug fix) * π Fix how mistral client and resource managers are being used in the mistral runner. Authentication has changed in the mistral client. Fix unit test accordingly. (bug fix) * π Fix issue where passing a single integer member for an array parameter for an action would cause a type mismatch in the API (bug fix) * π Fix ``--config-file`` st2 CLI argument not correctly expanding the provided path if the path contained a reference to the user home directory (``~``, e.g. ``~/.st2/config.ini``) (bug fix) * π Fix action alias update API endpoint. (bug fix) * π Fix a bug with ``--api-token`` / ``-t`` and other CLI option values not getting correctly propagated to all the API calls issued in the ``st2 pack install``, ``st2 pack remove`` and ``st2 pack config`` commands. (bug fix)
-
v2.1.1 Changes
December 16, 2016β Added
* π ``core.http`` action now also supports HTTP basic auth and digest authentication by passing ``username`` and ``password`` parameter to the action. (new feature) * After running ``st2 pack install`` CLI command display which packs have been installed. (improvement) π Changed
- β‘οΈ Update
/v1/packs/register
API endpoint so it throws on failure (e.g. invalid pack or resource metadata). This way the default behavior is consistent with defaultst2ctl reload --register-all
behavior. If user doesn't want the API endpoint to fail on failure, they can pass"fail_on_failure": false
attribute in the request payload. (improvement) - π» Throw a more user-friendly exception when registering packs (
st2ctl reload
) if pack ref / name is invalid. (improvement) - β‘οΈ Update
packs.load
action to also register triggers by default. (improvement)
π Fixed
* π Fix ``GET /v1/packs/<pack ref or id>`` API endpoint - make sure pack object is correctly returned when pack ref doesn't match pack name. Previously, 404 not found was thrown. (bug fix) * β‘οΈ Update local action runner so it supports and works with non-ascii (unicode) parameter keys and values. (bug fix) Contribution by Hiroyasu OHYAMA. #3116 * β‘οΈ Update ``/v1/packs/register`` API endpoint so it registers resources in the correct order which is the same as order used in ``st2-register-content`` script. (bug fix)
- β‘οΈ Update
-
v2.1.0 Changes
December 05, 2016β Added
* π New pack management: - Add new ``stackstorm_version`` and ``system`` fields to the pack.yaml metadata file. Value of the first field can contain a specific StackStorm version with which the pack is designed to work with (e.g. ``>=1.6.0,<2.2.0`` or ``>2.0.0``). This field is checked when installing / registering a pack and installation is aborted if pack doesn't support the currently running StackStorm version. Second field can contain an object with optional system / OS level dependencies. (new feature) - Add new ``contributors`` field to the pack metadata file. This field can contain a list of people who have contributed to the pack. The format is ``Name <email>``, e.g. ``Tomaz Muraus <[email protected]>`` (new feature) - Add support for default values and dynamic config values for nested config objects. (new feature, improvement) - Add new ``st2-validate-pack-config`` tool for validating config file against a particular config schema file. (new-feature) * β Add new ``POST /v1/actionalias/match`` API endpoint which allows users to perform ChatOps action alias matching server-side. This makes it easier to build and maintain StackStorm ChatOps clients / adapters for various protocols and mediums. Clients can now be very thin wrappers around this new API endpoint. Also add two new corresponding CLI commands - ``st2 alias-execution match`` and ``st2 alias-execution execute``. Contribution by Anthony Shaw. (new feature) #2895. * β Adding ability to pass complex array types via CLI by first trying to seralize the array as JSON and then falling back to comma separated array. * β Add new ``core.pause`` action. This action behaves like sleep and can be used inside the action chain or Mistral workflows where waiting / sleeping is desired before proceeding with a next task. Contribution by Paul Mulvihill. (new feature) #2933. * π Allow user to supply multiple resource ids using ``?id`` query parameter when filtering "get all" API endpoint result set (e.g. ``?id=1,2,3,4``). This allows for a better client and servers performance when user is polling and interested in multiple resources such as polling on multiple action executions. (improvement) * Add support for ssh config file for ParamikoSSHrunner. Now ``ssh_config_file_path`` can be set in st2 config and can be used to access remote hosts when ``use_ssh_config`` is set to ``True``. However, to access remote hosts, action parameters like username and password/private_key, if provided with action, will have precedence over the config file entry for the host. #2941 #3032 #3058 [Eric Edgar] (improvement) π Changed
π Improved pack validation - now when the packs are registered we check that:
version
attribute in the pack metadata file matches valid semver format (e.g0.1.0
,2.0.0
, etc.)email
attribute (if specified) contains a valid email address. (improvement)- Only valid word characters (
a-z
,0-9
and_
) used for action parameter names. Previously, due to bug in the code, any character was allowed.
If validation fails, pack registration will fail. If you have an existing action or pack definition which uses invalid characters, pack registration will fail. You must update your packs.
- For consistency with new pack name validation changes, sample
hello-st2
pack has been renamed tohello_st2
. - β‘οΈ Update
packs.install
action (pack install
command) to only load resources from the packs which are being installed. Also update it and remove "restart sensor container" step from the install workflow. This step hasn't been needed for a while now because sensor container dynamically reads a list of available sensors from the database and starts the sub processes. (improvement) - π Improve API exception handling and make sure 400 status code is returned instead of 500 on mongoengine field validation error. (improvement)
- π§ Throw a more user-friendly exception if rendering a dynamic configuration value inside the config fails. (improvement)
- π Change st2api so that a full execution object is returned instead of an error message, when an API client requests cancellation of an execution that is already canceled
- Speed up short-lived Python runner actions by up to 70%. This way done by re-organizing and re-factoring code to avoid expensive imports such as jsonschema, jinja2, kombu and mongoengine in the places where those imports are not actually needed and by various other optimizations. (improvement)
- π Improve performance of
GET /executions/views/filters
by creating additional indexes on executions collection - β¬οΈ Upgrade various internal Python library dependencies to the latest stable versions (gunicorn, kombu, six, appscheduler, passlib, python-gnupg, semver, paramiko, python-keyczar, virtualenv).
β Removed
* β Remove ``packs.info`` action because ``.gitinfo`` file has been deprecated with the new pack management approach. Now pack directories are actual checkouts of the corresponding pack git repositories so this file is not needed anymore. π Fixed ~~~~~ * π Fix ``packs.uninstall`` action so it also deletes ``configs`` and ``policies`` which belong to the pack which is being uninstalled. (bug fix) * When a policy cancels a request due to concurrency, it leaves end_timestamp set to None which the notifier expects to be a date. This causes an exception in "isotime.format()". A patch was released that catches this exception, and populates payload['end_timestamp'] with the equivalent of "datetime.now()" when the exception occurs. * β Adding check for datastore Client expired tokens used in sensor container * π Fix python action runner actions and make sure that modules from ``st2common/st2common/runners`` directory don't pollute ``PYTHONPATH`` for python runner actions. (bug fix)
-
v2.0.1 Changes
September 30, 2016β Added
* π Allow users to specify sort order when listing traces using the API endpoint by specifying ``?sort_desc=True|False`` query parameters and by passing ``--sort=asc|desc`` parameter to the ``st2 trace list`` CLI command. (improvement) * Retry connecting to RabbitMQ on services start-up if connecting fails because of an intermediate network error or similar. (improvements) * π Allow jinja expressions ``{{st2kv.system.foo}}`` and ``{{st2kv.user.foo}}`` to access datastore items from workflows, actions and rules. This is in addition to supporting expressions ``{{system.foo}}`` and ``{{user.foo}}``. π Changed
- β‘οΈ Update traces list API endpoint and
st2 trace list
so the traces are sorted bystart_timestamp
in descending order by default. This way it's consistent with executions list and-n
CLI parameter works as expected. (improvement)
π Deprecated
* π In subsequent releases, the expressions ``{{system.}}`` and ``{{user.}}`` for accessing datastore items will be deprecated. It is recommended to switch to using ``{{st2kv.system.}}`` and ``{{st2kv.user.}}`` for your content. (improvement) π Fixed ~~~~~ * π Fix ``st2 execution get`` command so now ``--attr`` argument correctly works with child properties of the ``result`` and ``trigger_instance`` dictionary (e.g. ``--attr result.stdout result.stderr``). (bug fix) * π Fix a bug with action default parameter values not supporting Jinja template notation for parameters of type ``object``. (bug fix, improvement) * π Fix ``--user`` / ``-u`` argument in the ``st2 key delete`` CLI command.
- β‘οΈ Update traces list API endpoint and
-
v2.0.0 Changes
August 31, 2016β Added
* Implement custom Jinja filter functions ``to_json_string``, ``to_yaml_string``, ``to_human_time_from_seconds`` that can be used in actions and workflows. (improvement) * 0οΈβ£ Default chatops message to include time taken to complete an execution. This uses ``to_human_time_from_seconds`` function. (improvement) * π Allow user to cancel multiple executions using a single invocation of ``st2 execution cancel`` command by passing multiple ids to the command - ``st2 execution cancel <id 1> <id 2> <id n>`` (improvement) * We now execute --register-rules as part of st2ctl reload. PR raised by Vaishali: https://github.com/StackStorm/st2/issues/2861#issuecomment-239275641 * β‘οΈ Update ``packs.uninstall`` command to print a warning message if any rules in the system reference a trigger from a pack which is being uninstalled. (improvement) * π Allow user to list and view rules using the API even if a rule in the database references a non-existent trigger. This shouldn't happen during normal usage of StackStorm, but it makes it easier for the user to clean up in case database ends up in a inconsistent state. (improvement) π Changed
- π¨ Refactor Jinja filter functions into appropriate modules. (improvement)
- β¬οΈ Bump default timeout for
packs.load
command from60
to100
seconds. (improvement) - β¬οΈ Upgrade pip and virtualenv libraries used by StackStorm pack virtual environments to the latest versions (8.1.2 and 15.0.3).
- π Change Python runner action and sensor Python module loading so the module is still loaded even if
the module name clashes with another module which is already in
PYTHONPATH
(improvement)
π Fixed
* π Fix a bug when jinja templates with filters (for example, ``st2 run core.local cmd='echo {{"1.6.0" | version_bump_minor}}'``) in parameters wasn't rendered correctly when executing actions. (bug-fix) * π Fix validation of the action parameter ``type`` attribute provided in the YAML metadata. Previously we allowed any string value, now only valid types (object, string, number, integer, array, null) are allowed. (bug fix) * π Fix disabling and enabling of a sensor through an API and CLI. (bug-fix) * π Fix HTTP runner so it works correctly when body is provided with newer versions of requests library (>= 2.11.0). (bug-fix) #2880 Contribution by Shu Sugimoto.
-
v1.6.0 Changes
August 08, 2016β Added
* π Allow user to specify an action which is performed on an execution (``delay``, ``cancel``) when a concurrency policy is used and a defined threshold is reached. For backward compatibility, ``delay`` is the default behavior, but now users can also specify ``cancel`` and an execution will be canceled instead of delayed when a threshold is reached. * β Add support for sorting execution list results, allowing access to oldest items. (improvement) * π Allow administrator to configure maximum limit which can be specified using ``?limit`` query parameters when making API calls to get all / list endpoints. For backward compatibility and safety reasons, the default value still is ``100``. (improvement) * Include a chatops alias sample in ``examples`` pack that shows how to use ``format`` option to display chatops messages in custom formatted way. (improvement) * Include a field ``elapsed_seconds`` in execution API response for GET calls. The clients using the API can now use ``elapsed_seconds`` without having to repeat computation. (improvement) * Implement custom YAQL function ``st2kv`` in Mistral to get key-value pair from StackStorm's datastore. (new-feature) π Changed
- β¬οΈ Upgrade to pymongo 3.2.2 and mongoengine 0.10.6 so StackStorm now also supports and works with MongoDB 3.x. (improvement)
- β‘οΈ Update action runner to use two internal green thread pools - one for regular (non-workflow) and one for workflow actions. Both pool sizes are user-configurable. This should help increase the throughput of a single action runner when the system is not over-utilized. It can also help prevent deadlocks which may occur when using delay policies with action-chain workflows. (improvement)
- β‘οΈ Update CLI commands to make sure that all of them support
--api-key
option. (bug-fix) - β‘οΈ Update
st2-register-content
script to exit with non-zero on failure (e.g. invalid resource metadata, etc.) by default. For backward compatibility reasons,--register-fail-on-failure
flag was left there, but it now doesn't do anything since this is the default behavior. For ease of migrations, users can revert to the old behavior by using new--register-no-fail-on-failure
flag. (improvement) - π Allow Python runner actions to return execution status (success, failure) by returning a tuple
from the
run()
method. First item in the tuple is a flag indicating success (True
/False
) and the second one is the result. Previously, user could only cause action to fail by throwing an exception or exiting which didn't allow for a result to be returned. With this new approach, user can now also return an optional result with a failure. (new feature) - Include testing for chatops
format_execution_result
python action. The tests cover various action types. (improvement) - π
Update
st2-register-content
script so it validates new style configs in/opt/stackstorm/configs/
directory when using--register-configs
flag if a pack contains a config schema (config.schema.yaml
). (improvement)
π Fixed
* π Make sure policies which are disabled are not applied. (bug fix) Reported by Brian Martin. * π Fix ``Internal Server Error`` when an undefined jinja variable is used in action alias ack field. We now send a http status code ``201`` but also explicitly say we couldn't render the ``ack`` field. The ``ack`` is anyways a nice-to-have message which is not critical. Previously, we still kicked off the execution but sent out ``Internal Server Error`` which might confuse the user whether execution was kicked off or not. (bug-fix)