Releases: StackStorm/st2
v2.9.0
Added
-
Add new runners:
winrm-cmd
,winrm-ps-cmd
andwinrm-ps-script
.
Thewinrm-cmd
runner executes Command Prompt commands remotely on Windows hosts using the
WinRM protocol. Thewinrm-ps-cmd
andwinrm-ps-script
runners execute PowerShell commands
and scripts on remote Windows hosts using the WinRM protocol.To accompany these new runners, there are two new actions
core.winrm_cmd
that executes remote
Command Prompt commands along withcore.winrm_ps_cmd
that executes remote PowerShell commands.
(new feature) #1636Contributed by Nick Maludy (Encore Technologies).
-
Add new
?tags
, query param filter to the/v1/actions
API endpoint. This query parameter
allows users to filter out actions based on the tag name . By default, when no filter values are
provided, all actions are returned. (new feature) #4219 -
Add a new standalone standalone
st2-pack-install
CLI command. This command installs a pack
(and sets up the pack virtual environment) on the server where it runs. It doesn't register the
content. It only depends on the Python, git and pip binary andst2common
Python package to be
installed on the system where it runs. It doesn't depend on the database (MongoDB) and message
bus (RabbitMQ).It's primary meant to be used in scenarios where the content (packs) are baked into the base
container / VM image which is deployed to the cluster.Keep in mind that the content itself still needs to be registered with StackStorm at some later
point when access to RabbitMQ and MongoDB is available by running
st2ctl reload --register-all
. (new feature) #3912 #4256 -
Add new
/v1/stream/executions/<id>/output[?output_type=all|stdout|stderr]
stream API
endpoint.This API endpoint returns event source compatible response format.
For running executions it returns any output produced so far and any new output as it's produced.
Once the execution finishes, the connection is automatically closed.For completed executions it returns all the output produced by the execution. (new feature)
-
Add new
core.inject_trigger
action for injecting a trigger instance into the system.Keep in mind that the trigger which is to be injected must be registered and exist in the system.
(new feature) #4231 #4259 -
Add support for
?include_attributes
query param filter to all the content pack resource
get all (list) API endpoints (actions, rules, trigger, executions, etc.). With this query
parameter user can control which API model attributes (fields) to receive in the response. In
situations where user is only interested in a subset of the model attributes, this allows for a
significantly reduced response size and for a better performance. (new feature) (improvement)
#4300 -
Add new
action_sensor.emit_when
config option which allows user to specify action status for
which actiontrigger is emitted. For backward compatibility reasons it defaults to all the action
completed states. (improvement) #4312 #4315Contributed by Shu Sugimoto.
-
Improve performance of schedule action execution (
POST /v1/executions
) API endpoint.Performance was improved by reducing the number of duplicated database queries, using atomic
partial document updates instead of full document updates and by improving database document
serialization and de-serialization performance. (improvement) #4030 #4331 -
Ported existing YAQL and Jinja functions from st2common to Orquesta. (new feature)
-
Add error entry in Orquesta workflow result on action execution failure. (improvement)
Changed
-
st2 key list
command now defaults to--scope=all
aka displaying all the datastore values
(system and current user scoped) . If you only want to display system scoped values (old behavior)
you can do that by passing--scope=system
argument to thest2 key list
command
(st2 key list --scope=system
). (improvement) #4221 -
The orquesta conductor implemented event based state machines to manage state transition of
workflow execution. Interfaces to set workflow state and update task on action execution
completion have changed and calls to those interfaces are changed accordingly. (improvement) -
Change
GET /v1/executions/<id>/output
API endpoint so it never blocks and returns data
produced so far for running executions. Behavior for completed executions is the same and didn't
change - all data produced by the execution is returned in the raw format.The streaming (block until execution has finished for running executions) behavior has been moved
to the new/stream/v1/executions/<id>/output
API endpoint.This way we are not mixing non-streaming (short lived) and streaming (long lived) connections
inside a single service (st2api). (improvement) -
Upgrade
mongoengine
(0.15.3) andpymongo
(3.7.1) to the latest stable version. Those
changes will allow us to support MongoDB 3.6 in the near future.New version of
mongoengine
should also offer better performance when inserting and updating
larger database objects (e.g. executions). (improvement) #4292 -
Trigger parameters and payload schema validation is now enabled by default
(system.validate_trigger_parameters
andsystem.validate_trigger_payload
config options
now default toTrue
).This means that trigger parameters are now validated against the
parameters_schema
defined on
the trigger type when creating a rule and trigger payload is validated againstpayload_schema
when dispatching a trigger via the sensor or via the webhooks API endpoint.This provides a much safer and user-friendly default value. Previously we didn't validate trigger
payload for custom (non-system) triggers when dispatching a trigger via webhook which meant that
webhooks API endpoint would silently accept an invalid trigger (e.g. referenced trigger doesn't
exist in the database or the payload doesn't validate against thepayload_schema
), but
TriggerInstanceDB
object would never be created because creation failed inside the
st2rulesengine
service. This would make such issues very hard to troubleshoot because only
way to find out about this failure would be to inspect thest2rulesengine
service logs.
(improvement) #4231 -
Improve code metric instrumentation and instrument code and various services with more metrics.
Also document various exposed metrics. Documentation can be found at
https://docs.stackstorm.com/latest/reference/metrics.html (improvement) #4310 -
Add new
metrics.prefix
config option. With this option user can specify an optional prefix
which is prepended to each metric key (name). This comes handy in scenarios where user wants to
submit metrics from multiple environments / deployments (e.g. testing, staging, dev) to the same
backend instance. (improvement) #4310 -
Improve
st2 execution tail
CLI command so it also supports Orquesta workflows and arbitrarily
nested workflows. Also fix the command so it doesn't include data from other unrelated running
executions. (improvement) #4328 -
Change default NGINX configuration to use HTTP 308 redirect, rather than 301, for plaintext requests.
#4335 -
Improve performance of the
GET /v1/actions/views/overview
API endpoint. (improvement) #4337
Fixed
-
Fix an issue with
AttributeError: module 'enum' has no attribute 'IntFlag'
error which would
appear when using Python 3 for a particular pack virtual environment and running on RHEL /
CentOS. (bug fix) #4297 -
Fix a bug with action runner throwing an exception and failing to run an action if there was an
empty pack config inside/opt/stackstorm/configs/
. (bug fix) #4325 -
Fix
action_sensor.enable
config option so it works correctly if user sets this option to a
non-default value ofTrue
. (bug fix) #4312 #4315Contributed by Shu Sugimoto.
-
Update
GET /v1/actions/views/entry_point/<action ref>
to return correctContent-Type
response header based on the entry point type / file extension. Previously it would always
incorrectly returnapplication/json
. (improvement) #4327
Deprecated
- The CloudSlang runner is now deprecated. In StackStorm 3.1 it will be removed from the core
StackStorm codebase. The runner code will be moved to a separate repository, and no longer
maintained by the core StackStorm team. Users will still be able to install and use this runner,
but it will require additional steps to install. - The
winexe
-based Windows runners are now deprecated. They will be removed in StackStorm 3.1.
They have been replaced bypywinrm
-based Windows runners. See
https://docs.stackstorm.com/latest/reference/runners.html#winrm-command-runner-winrm-cmd
for more on using these new runners.
v2.8.1
Added
-
Update
st2
CLI to inspectCOLUMNS
environment variable first when determining the
terminal size. Previously this environment variable was checked second last (after trying to
retrieve terminal size using various OS specific methods and before falling back to the default
value).This approach is more performant and allows user to easily overwrite the default value or value
returned by the operating system checks - e.g. by runningCOLUMNS=200 st2 action list
.
(improvement) #4242
Changed
-
Update
st2client/setup.py
file to dynamically load requirements from
st2client/requirements.txt
file. The code works with pip >= 6.0.0, although using pip 9.0.0
or higher is strongly recommended. (improvement) #4209 -
Update
st2
CLI to use a more sensible default terminal size for table formatting purposes if
we are unable to retrieve terminal size using various system-specific approaches.Previously we would fall back to a very unfriendly default of 20 columns for a total terminal
width. This would cause every table column to wrap and make output impossible / hard to read.
(improvement) #4242
Fixed
-
Fixed a bug where
secret: true
was not applying to full object and array trees. (bugfix) #4234
Reported by @jjmContributed by Nick Maludy (Encore Technologies).
-
Mark
password
http-runner
parameter as a secret. (bug fix) #4245Reported by @daniel-mckenna
v2.8.0
Added
-
Orchestra - new StackStorm-native workflow engine. This is currently in beta. (new feature)
-
Added metrics for collecting performance and health information about the various ST2 services and functions. (new feature) #4004 #2974
-
When running a dev (unstable) release include git revision hash in the output when using st2 --version CLI command. (new feature) #4117
-
Update rules engine to also create rule enforcement object when trigger instances fails to match a rule during the rule matching / filtering phase due to an exception in the rule criteria (e.g. invalid Jinja expression, etc.).
-
This change increases visibility into rules which didn't match due to an exception. Previously this was only visible / reflected in the rules engine log file. (improvement) #4134
-
Add new GET /v1/ruleenforcements/views[/] API endpoints which allow user to retrieve RuleEnforcement objects with the corresponding TriggerInstance and Execution objects. (new feature) #4134
-
Add new status field to the RuleEnforcement model. This field can contain the following values - succeeded (trigger instance matched a rule and action execution was triggered successfully), failed (trigger instance matched a rule, but it didn't result in an action execution due to Jinja rendering failure or other exception). (improvement) #4134 #4152
-
Add trigger type reference based filtering to the /v1/triggerinstances API endpoint - e.g. /v1/triggerinstances?trigger_type=core.st2.webhook. (new feature) #4151
-
Add new --python3 flag to st2 pack install CLI command and python3 parameter to packs.{install,setup_virtualenv} actions. When the value of this parameter is True, it uses python3 binary when creating virtual environment for that pack (based on the value of actionrunner.python3_binary config option).
Note 1: For this feature to work, Python 3 needs to be installed on the system, virtualenv package installed on the system needs to support Python 3 (it needs to be a recent version) and pack in question needs to support Python 3.
Note 2: This feature is experimental and opt-in. (new feature) #4016 #3922 #4149
-
Add two new Jinja filters - basename (os.path.basename) and dirname (os.path.dirname). #4184
Contributed by Florian Reisinger (@reisingerf).
Changed
-
Update st2 CLI to create the configuration directory and file, and authentication tokens with secure permissions (eg: readable only to owner) #4173
-
Refactor the callback module for the post run in runner to be more generic. (improvement)
-
Update various Python dependencies to the latest stable versions (gunicorn, gitpython, python-gnupg, tooz, flex). #4110
-
Update all the service and script entry points to use /etc/st2/st2.conf as a default value for the config file location.
-
This way users don't need to explicitly provide --config-file CLI argument when running various scripts (e.g. st2-track-result, st2-apply-rbac-definitions, etc.) and when they just want to use a default config file. (improvement) #4111
-
Update st2 CLI to print a warning if a non-unicode system locale which would prevent StackStorm to function correctly in some scenarios is used. (improvement) #4127 #4120
-
Upgrade various internal Python library dependencies to the latest stable versions (kombu, amqp, gitpython, pytz, semver, oslo.utils). (improvement) #4162
-
Move from keyczar library to cryptography library for handling symmetric encryption and decryption (secret datastore values).
Note: This change is fully backward compatible since it just changes the underlying backend and implementation details. The same underlying encryption algorithm is used (AES256 in CBC mode with HMAC signature). (improvement) #4165
Fixed
-
Fixed a bug where secrets in pack configs weren't being masked.
Recently we introduced support for nested objects and arrays. Secret parameters within these nested objects and arrays were not being masked. The fix involves us fully traversing deeply nested objects and arrays and masking out any variables marked as secret. This means we now support pack config JSON schemas with type: object and its corresponding parameters: {} stanza, along with type: array and its corresponding items: {} stanza. We still do NOT support JSON schema combinations that includes the anyOf, allOf, oneOf, and not keywords. (bug fix) #4139
Contributed by Nick Maludy (Encore Technologies).
-
Style clean up to transport queues module and various config modules. (improvement)
-
Fixed CLI help for st2 action-alias match and execute. (#4174).
-
Fix regression in ?include_attributes query param filter in the /v1/executions API endpoint. (bug fix) #4226
v2.7.2
Changed
-
Reduce load on LDAP server and cache user groups response in an in-memory cache when RBAC
remote LDAP group to local RBAC role synchronization feature is enabled.Previously on authentication the code would hit LDAP server multiple times to retrieve user
groups. With this change, user LDAP groups are only retrieved once upon authentication and
cached and re-used in-memory by default for 120 seconds.This reduces load on LDAP server and improves performance upon regular and concurrent user
authentication.This functionality can be disabled by setting
cache_user_groups_response
LDAP
authentication backend kwarg tofalse
.Note: This change only affects users which utilize RBAC with remote LDAP groups to local RBAC
roles synchronization feature enabled. (enterprise) (bug fix) #4103 #4105
Fixed
-
Fix an issue (race condition) which would result in not all the remote LDAP groups being
synchronized with local RBAC roles if a user tried to authenticate with the same auth token
concurrently in a short time frame.Note: This issue only affects users which utilize RBAC with remote LDAP groups to local RBAC
roles synchronization feature enabled. (enterprise) (bug fix) #4103 #4105 -
Fix an issue with some sensors which rely on
select.poll()
(FileWatch, GithubSensor, etc.)
stopped working with StackStorm >= 2.7.0.StackStorm v2.7.0 inadvertently introduced a change which broke a small set of sensors which
rely onselect.poll()
functionality. (bug fix) #4118 -
Throw if
id
CLI argument is not passed to thest2-track-result
script. (bug fix) #4115 -
Fixed pack config's not properly rendering Jinja expressions within lists. (bugfix) #4121
Contributed by Nick Maludy (Encore Technologies).
-
Fixed pack config rendering error throw meaningful message when a Jinja syntax error is
encountered. (bugfix) #4123Contributed by Nick Maludy (Encore Technologies).
v2.7.1
Changed
-
When creating a pack environment during the pack installation, we now pass
--no-download
flag
to thevirtualenv
binary. This way version of pip, wheel and distutils which is enforced by
virtualenv is used instead of downloading the latest stable versions from PyPi.This results in more reproducible pack virtual environments and we also ensure pip 9.0 is used (
there are some known issues with pip 10.0).If for some reason you want to revert to the old behavior, you can do that by passing
no_download=False
parameter to thepacks.setup_virtualenv
action. #4085
Fixed
- Fix
st2 pack search
andPOST /api/v1/packs/index/search
API endpoint so it doesn't
return internal server error when a single pack search term is provided. (bug fix) #4083
v2.7.0
Added
-
Update
st2 execution tail
command so it supports double nested workflows (workflow ->
workflow -> execution). Previously, only top-level executions and single nested workflows
(workflow -> execution) were supported. (improvement) #3962 #3960 -
Add support for utf-8 / unicode characters in the pack config files. (improvement) #3980 #3989
Contributed by @sumkire.
-
Added the ability of
st2ctl
to utilize environment variables from/etc/default/st2ctl
(for Ubuntu/Debian) and/etc/sysconfig/st2ctl
(RHEL/CentOS). This allows
deployments to overrideCOMPONENTS
andST2_CONF
in a global location
sost2ctl
can start/stop/restart selected components and utilize a non-default
location forst2.conf
.
(new feature) #4027Contributed by Nick Maludy (Encore Technologies).
-
Add support for new optional
content_version
runner parameter to the Python and Local Shell
Script runner. This parameter can contain a git commit hash / tag / branch from a pack git
repository and runner will ensure this revision of the pack content (Python action / local shell
script action) is used for a particular action execution.Keep in mind that providing this parameter only ensures a particular revision of the pack content
is used. Python runner virtual environment and dependencies are outside of this scope.Note: To be able to utilize this functionality, git version >= 2.5.0 must be installed on the
system.
(new feature) #3997 -
Update windows runner to correctly handle and use
timeout
action execution status.
(improvement) #4047 -
Add missing
scope
,decrypt
andencrypt
arguments to the datastore management
related methods on the SensorService class. (improvement) #3895 #4057 #4058
Changed
-
Modified RabbitMQ connection error message to make clear that it is an MQ connection issue. #3992
-
Additional refactor which makes action runners fully standalone and re-distributable Python
packages. Also add support for multiple runners (runner modules) inside a single Python package
and consolidate Python packages from two to one for the following runners: local runners, remote
runners, windows runners. (improvement) #3999 -
Upgrade eventlet library to the latest stable version (0.22.1) (improvement) #4007 #3968
-
Increase maximum retry delay for
action.retry
policy from 5 seconds to 120 seconds. Because
of the way retries are currently implemented (they are not st2notifier service restart safe),
long retry delays are not recommended. For more information on this limitation please refer to
the documentation - https://docs.stackstorm.com/reference/policies.html#retry. #3630 #3637 -
Update Python runner so it throws a more user-friendly exception in case Python script tries to
access a key inself.config
dictionary which doesn't exist. (improvement) #4014 -
Update various Python dependencies to the latest stable versions (apscheduler, gitpython,
pymongo, stevedore, paramiko, tooz, flex, webob, prance). -
Refactored mistral runner to support callback from mistral instead of relying on st2resultstracker.
This reduces the unnecessary traffic and CPU time by querying the mistral API. Included a command to
manually add a state entry for Mistral workflow execution to recover from any callback failures.
(improvement) -
Throw a more user-friendly error when writing pack data files to disk and when an invalid file
path is provided (e.g. path is outside the pack directory, etc.). (improvement) #4039 #4046 -
Change the output object returned by Windows runners so it matches the format from the local and
remote runner.Note: This change is backward incompatible -
result
attribute has been removed (same
information is available instdout
attribute),exit_code
renamed toreturn_code
and
two new attributes added -succeeded
andfailed
.For more information, please refer to the upgrade notes. #4044 #4047
Fixed
-
Fix Python runner actions and
Argument list too long
error when very large parameters are
passed into the action. The fix utilizesstdin
to pass parameters to the Python action wrapper
process instead of CLI argument list. (bug fix) #1598 #3976 -
Fix a regression in
POST /v1/webhooks/<webhook name>
API endpoint introduced in v2.4.0
and add back support for arrays. In 2.4.0 support for arrays was inadvertently removed and
only objects were supported. Keep in mind that this only applies to custom user-defined
webhooks and systemst2
webhook still requires input to be an object (dictionary).
(bug fix) #3956 #3955 -
Fix a bug in the CLI causing
st2 execution pause
andst2 execution resume
to not work. (bugfix) #4001Contributed by Nick Maludy (Encore Technologies).
-
Fixed missing "paused" status option from "st2 execution list" help output. (bugfix) #4037
Contributed by Ben Hohnke (NTT Communications ICT Solutions)
-
Fix "st2 pack install" command so it doesn't require access to pack index (index.stackstorm.org)
when installing a local pack (pack name starting with "file://"). (bug fix) #3771 #3772 -
Fix rules engine so it correctly handles and renders action parameters which contain Jinja
expressions and default values. (bug fix) #4050 #4050Reported by @rakeshrm.
-
Make sure
observer
system role also grantspack_search
permission. (bug fix) #4063 #4064Reported by @SURAJTHEGREAT.
-
Fix st2 webhook get -h which was asking for a name or id as opposed to the URL of the webhook.
Also, fix st2 webhook list to explicitly add a webhook column. (bugfix) #4048
v2.6.0
https://stackstorm.com/2018/01/25/new-year-new-stackstorm-v2-6-released/
Added
-
Add new
get_user_info
method to action and sensor service. With this method, user can
retrieve information about the user account which is used to perform datastore operations inside
the action and sensor service. (new feature) #3831 -
Add new
/api/v1/user
API endpoint. This API endpoint is only available to the authenticated
users and returns various metadata on the authenticated user (which method did the user use to
authenticate, under which username the user is authenticated, which RBAC roles are assignment to
this user in case RBAC is enabled, etc.) (new feature) #3831 -
The
/api/v1/match_and_execute
API endpoint matches a single alias and executes multiple times
if the alias format has amatch_multiple
key set totrue
. Please refer to the
documentation for usage. #3884Contributed by @ahubl-mz.
-
Add ability to share common code between python sensors and python actions. You can now place
common code inside alib
directory inside a pack (with an__init__.py
insidelib
directory to declare it a python package). You can then import the common code in sensors and
actions. Please refer to documentation for samples and guidelines. #3490 -
Add support for password protected sudo to the local and remote runner. Password can be provided
via the newsudo_password
runner parameter. (new feature) #3867 -
Add new
--tail
flag to thest2 run
/st2 action execute
andst2 execution re-run
CLI command. When this flag is provided, new execution will automatically be followed and tailed
after it has been scheduled. (new feature) #3867 -
Added flag
--auto-dict
tost2 run
andst2 execution re-run
commands. This flag must now
be specified in order to automatically convert list items to dicts based on presence of colon
(:
) in all of the list items (new feature) #3909 -
Allow user to set default log level used by all the Python runner actions by setting
actionrunner.pythonrunner```` option in
st2.conf`` (new feature) #3929 -
Update
st2client
package which is also utilized by the CLI so it also works under Python 3.Note: Python 2.7 is only officially supported and tested Python version. Using Python 3 is at
your own risk - they are likely still many bugs related to Python 3 compatibility. You have been warned.
(new feature) #3929 #3932Contributed by Anthony Shaw.
-
Add
?limit=-1
support for the API to fetch full result set (CLI equivalent flag
--last/-n
). Post error message forlimit=0
and fix corner case where negative values for
limit query param were not handled correctly. #3761 #3708 #3735 -
Only allow RBAC admins to retrieve all the results at once using
?limit=-1
query param, upate
the code soapi.max_page_size
config option only applies to non-admin users, meaning users
with admin permission can specify arbitrary value for?limit
query param which can also be
larger thanapi.max_page_size
. (improvement) #3939 -
Add new
?include_attributes
query param filter to/v1/executions/
API endpoint
With this filter user can select which fields to include in the response (whitelist approach,
opposite of the existing?exclude_attributes
filter).For example, if you only want to retrieve
id
andstatus
field, the URL would look like
this -/v1/executions?include_attributes=id,status
. (new feature) #3953 #3858 #3856
Changed
st2actions.runners.pythonrunner.Action
class path for base Python runner actions has been
deprecated since StackStorm v1.6.0 and will be fully removed in StackStorm v2.7.0. If you have
any actions still using this path you are encouraged to update them to use
st2common.runners.base_action.Action
path. #3803- Refactor
st2common
Python package so it's fully self sustaining and can be used in a
standalone manner. (improvement) #3803 - Refactor Python action runner so it only depends on
st2common
Python package (previously it
also depended onst2actions
) and can be used in a standalone mode. Previously pack config and
and some other parameters were retrieved inside the Python process wrapper, but now they are
retrieved inside the runner container and passed to the runner. This also makes it easier to add
support for pack configs to other runners in the future. (improvement) #3803 - Update various Python dependencies to the latest stable versions (kombu, amqp, apscheduler,
gitpython, pymongo, stevedore, paramiko, prompt-toolkit, flex). #3830 - Mask values in an Inquiry response displayed to the user that were marked as "secret" in the
inquiry's response schema. #3825 - Real-time action output streaming is now enabled by default. For more information on this
feature, please refer to the documentation - https://docs.stackstorm.com/latest/reference/action_output_streaming.html.
You can disable this functionality by settingactionrunner.stream_output
config option in
st2.conf
toFalse
and restart the services (sudo st2ctl restart
).
Fixed
-
Fully fix performance regressions for short Python runner actions introduced in the past and
partially fixed in #3809. (bug fix) #3803 -
Fix 'NameError: name 'cmd' is not defined' error when using
linux.service
with CentOS systems.
#3843. Contributed by @shkadov -
Fix bugs with newlines in execution formatter (client) (bug fix) #3872
-
Fixed
st2ctl status
to use better match when checking running process status. #3920 -
Removed invalid
st2ctl
option to re-open Mistral log files. #3920 -
Update garbage collection service and
st2-purge-executions
CLI tool and make deletion more
efficient. Previously we incorrectly loaded all the execution fields in memory, but there was no
need for that and now we only retrieve and load id which is the only field we need. #3936Reported by @Kevin-vH.
v2.5.1
https://stackstorm.com/2017/12/19/early-christmas-stackstorm-patch-release-2-5-1/
Added
-
Add new
log_level
runner parameter to Python runner. With this parameter, user can control which log messages generated by Python runner actions are output to actionstderr
. For backward compatibility reasons it defaults todebug
.
This functionality comes handy in situations when an action depends on an external library which logs a lot of information underdebug
, but you only want to see messages with log levelerror
or higher (or similar). (new feature) #3824 -
Add stevedore related metadata to Python package setup.py files for runner packages. This way runners can be installed using pip and dynamically enumerated and loaded using stevedore and corresponding helper functions.
All runners are now also fully fledged Python packages (previously they were single module
Python packages which caused various install and distribution related issues when installing
them via pip) (new feature) -
Add new
search
rule criteria comparison operator. Please refer to the documentation for
usage. (new feature) #3833Contributed by @ahubl-mz.
-
Added flag
--auto-dict
tost2 run
andst2 execution re-run
commands. This flag must now
be specified in order to automatically convert list items to dicts based on presence of colon
(:
) in all of the list items (new feature) #3909
Changed
-
Update the output of
st2 execution {run,get}
CLI command to colorize the value of the
status
attribute (green forsucceeded
, red forfailed
, etc. aka the same as for the
output ofst2 execution list
command). (improvement) #3810Contributed by Nick Maludy (Encore Technologies).
-
Update log messages in the datastore service to correctly use
DEBUG
log level instead of
AUDIT
. #3845
Fixed
- Fix log messages generated by Python runner actions to include the correct action class name.
Previously they always incorrectly used "ABCMeta" instead of the actual action class name. (bug fix) #3824 - Fix
st2 execution tail [last]
CLI command so it doesn't throw an exception if there are no executions in the database. (bug fix) #3760 #3802 - Fix a bug with datastore service used inside the Python runner actions not correctly scoping the auth token to the user who triggered the action. Token was incorrectly scoped to
api_service
user without any permissions. (bug fix) #3823 #3535 - Fix edge case for workflows stuck in running state. When Mistral receives a connection error from the st2 API on requesting action execution, there's a duplicate action execution stuck in requested state. This leads to the st2resultstracker assuming the workflow is still running.
- Fix a regression and a bug with no API validation being performed and API returning 500 instead of 400 status code if user didn't include any request payload (body) when hitting POST and PUT API endpoints where body is mandatory. (bug fix) #3864
- Fix a bug in Python runner which would cause action log messages to be duplicated in action stderr output when utilizing action service / datastore service inside actions. (bug fix) #3893
v2.5.0
https://stackstorm.com/2017/10/26/stackstorm-2-5-hit-streets/
Added
-
Add new feature which allows runner action output (stdout and stderr) to be streamed
and consumed in real-time by using one of the following approaches:/v1/executions/<execution id>/output[?type=stdout/stderr]
API endpoint./v1/stream/
stream endpoint and listening forst2.execution.stdout__create
and
st2.execution.output__create
/v1/stream
stream API endpoint events.st2 execution tail <execution id> [--type=stdout/stderr]
CLI command (underneath it uses
stream API endpoint).
Right now this functionality is available for the following runners:
- local command runner
- local script runner
- remote command runner
- remote script runner
- python runner
Note: This feature is still experimental and it's disabled by default (opt-in). To enable it,
setactionrunner.stream_output
config option toTrue
. -
Update
st2 role-assignment list
RBAC CLI command to include information about where a
particular assignment comes from (from which local assignment or mapping file). (improvement)
#3763 -
Add support for overlapping RBAC role assignments for assignments via remote LDAP group to
StackStorm role mappings. This means that the same role can now be granted via multiple RBAC
mapping files.
#3763 -
Add new Jinja filters
from_json_string
,from_yaml_string
, andjsonpath_query
.
#3763 -
Add new "Inquiry" capability, which adds ability to "ask a question", usually in a workflow.
Create a new runner type: "inquirer" to support this, as well as new API endpoints and
client commands for interacting with InquiriesContributed by mierdin. #3653
-
Added two new rule operators,
inside
andninside
which allow for the reverse intent of
thecontains
andncontains
operators. #3781Contributed by @lampwins.
-
Allow user to use more expressive regular expressions inside action alias format string by
allowing them to specify start (^
) and end ($
) anchors. Previously, those anchors were
automatically added at the beginning and end of the alias format string. Now they are only added
if a format string doesn't already contain them. #3789Contributed by @ahubl-mz.
-
Add new
POST /v1/aliasexecution/match_and_execute
API endpoint which allows user to
schedule an execution based on a command string if a matching alias is found in the database.This API endpoint is meant to be used with chat bot plugins. It allows them to be simple thin
wrappers around this API endpoint which send each chat line to this API endpoint and handle the
response. #3773 -
Add several improvements to the installation scripts: They support using proxy servers.
~stanley
no longer has to be/home/stanley
. In addition to the on-screen display, the
output from the installation script is now logged to a file beginning withst2-install
under
/var/log/st2/
. Furthermore, the script handles re-runs better, although it's
not fully idempotent yet. More improvements are expected in the near future.
st2-packages: #505, #506, #507, #508, #509, #510, #512, #517.
Fixed
-
Fix a bug where sensor watch queues were not deleted after sensor container process was shut
down. This resulted in spurious queues left behind. This should not have caused performance
impact but just messes with rabbitmqadmin output and maybe tedious for operators. (bug fix) #3628Reported by Igor.
-
Make sure all the temporary RabbitMQ queues used by the stream service are deleted once the
connection to RabbitMQ is closed. Those queues are temporary and unique in nature and new ones
are created on each service start-up so we need to make sure to correctly clean up old queues. #3746 -
Fix cancellation of subworkflow and subchain. Cancel of Mistral workflow or Action Chain is
cascaded down to subworkflows appropriately. Cancel from tasks in the workflow or chain is
cascaded up to the parent. (bug fix) -
Fix delays in st2resultstracker on querying workflow status from Mistral. Make sleep time for
empty queue and no workers configurable. Reduce the default sleep times to 5 seconds. StackStorm
instances that handle more workflows should consider increasing the query interval for better
CPU utilization. -
Fix missing type for the parameters with enum in the core st2 packs.(bug fix) #3737
Reported by Nick Maludy.
-
Add missing
-h
/--help
CLI flag to the following execution CLI commands: cancel, pause,
resume. (bug fix) #3750 -
Fix execution cancel and pause CLI commands and make id a required argument. (bug fix) #3750
-
Fix
st2 role-assignment list
CLI command and allow--user
,--remote
and--role
arguments to be used together. Previously they were mutually exclusive so it wasn't possible to
use them together. (bug fix) #3763 -
Update default event name whitelist for
/v1/stream
API endpoint and make sure
st2.announcement__errbot
and other event names starting withst2.announcement__*
prefix
are not filtered out. #3769 (bug fix)Reported by Carlos.
-
Fix action-alias execute response to show execution id and matching action-alias #3231 (bug fix)
Reported by Carlos. -
Fix
st2 apikey load
command to update an existing entry if items in input file containid
attribute and item already exists on the server. This way the behavior is consistent with
st2 key load
command and the command is idempotent if each item containsid
attribute.
#3748 #3786Reported by Christopher Baklid.
-
Don't log MongoDB database password if user specifies URI for
database.db_host
config
parameter and that URI also includes a password. Default and a common scenario is specifying
password as a separatedatabase.password
config parameter. #3797Reported by Igor Cherkaev.
-
Fix
POST /v1/actionalias/match
API endpoint to correctly return a dictionary instead of an
array. We had a correct OpenAPI definition for the response, but the code incorrectly returned
an array instead of a dictionary.Note: This is a breaking change so if your code utilizes this API endpoint you need to update
to treat response as a dictionary and not as an array with a single item. #377 -
Partially fix performance overhead and regression for short and simple Python runner actions.
Full / complete fix will be included in v2.6.0. #3809
Changed
- Minor language and style tidy up of help strings and error messages #3782
v2.4.1
https://stackstorm.com/2017/09/18/quick-one-st2-2-4-1-released/
Fixed
-
Fix a bug with
/v1/packs/install
and/v1/packs/uninstall
API endpoints incorrectly using
system user for scheduled pack install and pack uninstall executions instead of the user which
performed the API operation.(bug fix) #3693 #3696Reported by theuiz.
-
Fix mistral callback failure when result contains unicode. (bug fix)
-
Fix cancellation of delayed action execution for tasks in workflow. (bug fix)
-
Fix timeout of mistral shutdown in systemd service. The fix is done upstream.
https://review.openstack.org/#/c/499853/ (bug fix)