StackStorm v3.0.0 Release Notes

Release Date: 2019-04-26 // almost 5 years ago
  • โž• Added

    ๐Ÿ‘ Allow access to user-scoped datastore items using {{ st2kv.user.<key name> }} Jinja template
    0๏ธโƒฃ notation inside the action parameter default values. (improvement) #4463

    Contributed by Hiroyasu OHYAMA (@userlocalhost).

    โž• Add support for new python_versions (list of string) attribute to pack metadata file
    ๐Ÿ‘ (pack.yaml). With this attribute pack declares which major Python versions it supports and
    works with (e.g. 2 and 3).

    ๐Ÿ“‡ For backward compatibility reasons, if pack metadata file doesn't contain that attribute, it's
    assumed it only works with Python 2. (new feature) #4474

    โšก๏ธ Update service bootstrap code and make sure all the services register in a service registry once
    they come online and become available.

    ๐Ÿ”ง This functionality is only used internally and will only work if configuration backend is
    ๐Ÿ”ง correctly configured in st2.conf (new feature) #4548

    โž• Add new GET /v1/service_registry/groups and
    GET /v1/service_registry/groups/<group_id>/members API endpoint for listing available service
    registry groups and members.

    Also add corresponding CLI commands - st2 service-registry group list, st2 service registry member list [--group-id=<group id>]

    NOTE: This API endpoint is behind an RBAC wall and can only be viewed by the admins. (new feature)
    #4548

    Add support for ?include_attributes and ?exclude_attributes query param filter to the
    โšก๏ธ GET /api/v1/executions/{id} API endpoint. Also update st2 execution get CLI command so it
    only retrieves attributes which are displayed. (new feature) #4497

    Contributed by Nick Maludy (@nmaludy Encore Technologies)

    โž• Add new --encrypted flag to st2 key set CLI command that allows users to pass in values
    which are already encrypted.

    ๐Ÿšฆ This attribute signals the API that the value is already encrypted and should be used as-is.

    โšก๏ธ st2 key load CLI command has also been updated so it knows how to work with values which are
    already encrypted. This means that st2 key list -n 100 -j < data.json ; st2 key load data.json will now also work out of the box for encrypted datastore values (values which have
    encrypted: True and secret: True attribute will be treated as already encrypted and used
    as-is).

    The most common use case for this feature is migrating / restoring datastore values from one
    StackStorm instance to another which uses the same crypto key.

    Contributed by Nick Maludy (Encore Technologies) #4547

    โž• Add source_channel to Orquesta st2() context for workflows called via ChatOps. #4600

    ๐Ÿ”„ Changed

    ๐Ÿ”„ Changed the inquiries API path from /exp to /api/v1. #4495

    ๐Ÿ”จ Refactored workflow state in orquesta workflow engine. Previously, state in the workflow engine
    is not status to be consistent with st2. Other terminologies used in the engine are also revised
    to make it easier for developers to understand. (improvement)

    โšก๏ธ Update Python runner code so it prioritizes libraries from pack virtual environment over StackStorm
    system dependencies.

    For example, if pack depends on six==1.11.0 in pack requirements.txt, but StackStorm depends
    on six==1.10.0, six==1.11.0 will be used when running Python actions from that pack.

    Keep in mind that will not work correctly if pack depends on a library which brakes functionality used
    by Python action wrapper code.

    Contributed by Hiroyasu OHYAMA (@userlocalhost). #4571

    ๐Ÿ‘Œ Improved the way that the winrm-ps-script runner sends scripts to the target Windows
    host. Previously the script was read from the local filesystem and serialized as one long
    ๐Ÿ’ป command executed on the command line. This failed when the script was longer than either
    ๐Ÿ 2047 or 8191 bytes (depending on Windows version) as the Windows command line uses this
    as its maximum length. To overcome this, the winrm-ps-script runner now uploads the
    script into a temporary directory on the target host, then executes the script.
    (improvement) #4514

    Contributed by Nick Maludy (Encore Technologies)

    โšก๏ธ Update various internal dependencies to latest stable versions (apscheduler, pyyaml, kombu,
    mongoengine, pytz, stevedore, python-editor, jinja2). #4637

    โšก๏ธ Update logging code so we exclude log messages with log level AUDIT from a default service
    ๐ŸŒฒ log file (e.g. st2api.log). Log messages with level AUDIT are already logged in a
    ๐ŸŒฒ dedicated service audit log file (e.g. st2api.audit.log) so there is no need for them to also
    ๐ŸŒฒ be duplicated and included in regular service log file.

    ๐ŸŒฒ NOTE: To aid with debugging, audit log messages are also included in a regular log file when log
    level is set to DEBUG or system.debug config option is set to True.

    Reported by Nick Maludy. (improvement) #4538 #4502 #4621

    โž• Add missing --user argument to st2 execution list CLI command. (improvement) #4632

    Contributed by Tristan Struthers (@trstruth).

    โšก๏ธ Update decrypt_kv Jinja template filter so it to throws a more user-friendly error message
    when decryption fails because the variable references a datastore value which doesn't exist.
    (improvement) #4634

    โšก๏ธ Updated orquesta to v0.5. (improvement)

    ๐Ÿ›  Fixed

    ๐ŸŽ Refactored orquesta execution graph to fix performance issue for workflows with many references
    ๐Ÿ”จ to non-join tasks. st2workflowengine and DB models are refactored accordingly. (improvement)
    StackStorm/orquesta#122.

    ๐Ÿ›  Fix orquesta workflow stuck in running status when one or more items failed execution for a with
    items task. (bug fix) #4523

    ๐Ÿ›  Fix orquesta workflow bug where context variables are being overwritten on task join. (bug fix)
    StackStorm/orquesta#112

    ๐Ÿ›  Fix orquesta with items task performance issue. Workflow runtime increase significantly when a
    ๐Ÿ”’ with items task has many items and result in many retries on write conflicts. A distributed lock
    is acquired before write operations to avoid write conflicts. (bug fix) StackStorm/orquesta#125

    ๐Ÿ›  Fix a bug with some API endpoints returning 500 internal server error when an exception contained
    unicode data. (bug fix) #4598

    ๐Ÿ›  Fix the st2 workflow inspect command so it correctly passes authentication token. (bug fix)
    #4615

    ๐Ÿ›  Fix an issue with new line characters (\n) being converted to \r\n in remote shell
    command and script actions which use sudo. (bug fix) #4623

    โšก๏ธ Update service bootstrap and st2-register-content script code so non-fatal errors are
    0๏ธโƒฃ suppressed by default and only logged under DEBUG log level. (bug fix) #3933 #4626 #4630

    ๐Ÿ›  Fix a bug with not being able to decrypt user-scoped datastore values inside Jinja expressions
    using decrypt_kv Jinja filter. (bug fix) #4634

    Contributed by Hiroyasu OHYAMA (@userlocalhost).

    ๐Ÿ›  Fix a bug with user-scoped datastore values not working inside action-chain workflows. (bug fix)
    #4634

    Added missing parameter types to linux.wait_for_ssh action metadata. (bug fix) #4611

    ๐Ÿ›  Fix HTTP runner (http-request) so it works correctly with unicode (non-ascii) body payloads.
    (bug fix) #4601 #4599

    Reported by Carlos Santana (@kknyxkk) and Rafael Martins (@rsmartins78).

    ๐Ÿ›  Fix st2-self-check so it sets correct permissions on pack directories which it copies over
    to /opt/stackstorm/packs. (bug fix) #4645

    ๐Ÿ›  Fix POST /v1/actions API endpoint to throw a more user-friendly error when writing data file
    to disk fails because of incorrect permissions. (bug fix) #4645