Skip to content

v3.0.0

Compare
Choose a tag to compare
@Kami Kami released this 26 Apr 07:14
· 4749 commits to master since this release

Added

  • Allow access to user-scoped datastore items using {{ st2kv.user.<key name> }} Jinja template
    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
    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