AWS Systems Manager for SAP

2024/05/10 - AWS Systems Manager for SAP - 3 new api methods

Changes  Added support for application-aware start/stop of SAP applications running on EC2 instances, with SSM for SAP

StartApplication (new) Link ¶

Request is an operation which starts an application.

Parameter ApplicationId is required.

See also: AWS API Documentation

Request Syntax

client.start_application(
    ApplicationId='string'
)
type ApplicationId:

string

param ApplicationId:

[REQUIRED]

The ID of the application.

rtype:

dict

returns:

Response Syntax

{
    'OperationId': 'string'
}

Response Structure

  • (dict) --

    • OperationId (string) --

      The ID of the operation.

ListOperationEvents (new) Link ¶

Returns a list of operations events.

Available parameters include OperationID, as well as optional parameters MaxResults, NextToken, and Filters.

See also: AWS API Documentation

Request Syntax

client.list_operation_events(
    OperationId='string',
    MaxResults=123,
    NextToken='string',
    Filters=[
        {
            'Name': 'string',
            'Value': 'string',
            'Operator': 'Equals'|'GreaterThanOrEquals'|'LessThanOrEquals'
        },
    ]
)
type OperationId:

string

param OperationId:

[REQUIRED]

The ID of the operation.

type MaxResults:

integer

param MaxResults:

The maximum number of results to return with a single call. To retrieve the remaining results, make another call with the returned nextToken value.

If you do not specify a value for MaxResults, the request returns 50 items per page by default.

type NextToken:

string

param NextToken:

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

type Filters:

list

param Filters:

Optionally specify filters to narrow the returned operation event items.

Valid filter names include status, resourceID, and resourceType. The valid operator for all three filters is Equals.

  • (dict) --

    A specific result obtained by specifying the name, value, and operator.

    • Name (string) -- [REQUIRED]

      The name of the filter. Filter names are case-sensitive.

    • Value (string) -- [REQUIRED]

      The filter values. Filter values are case-sensitive. If you specify multiple values for a filter, the values are joined with an OR, and the request returns all results that match any of the specified values

    • Operator (string) -- [REQUIRED]

      The operator for the filter.

rtype:

dict

returns:

Response Syntax

{
    'OperationEvents': [
        {
            'Description': 'string',
            'Resource': {
                'ResourceArn': 'string',
                'ResourceType': 'string'
            },
            'Status': 'IN_PROGRESS'|'COMPLETED'|'FAILED',
            'StatusMessage': 'string',
            'Timestamp': datetime(2015, 1, 1)
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • OperationEvents (list) --

      A returned list of operation events that meet the filter criteria.

      • (dict) --

        An operation event returns details for an operation, including key milestones which can be used to monitor and track operations in progress.

        Operation events contain:

        • Description string

        • Resource, including its ARN and type

        • Status

        • StatusMessage string

        • TimeStamp

        Operation event examples include StartApplication or StopApplication.

        • Description (string) --

          A description of the operation event. For example, "Stop the EC2 instance i-abcdefgh987654321".

        • Resource (dict) --

          The resource involved in the operations event.

          Contains ResourceArn ARN and ResourceType.

          • ResourceArn (string) --

            The Amazon Resource Name (ARN) of the source resource.

            Example of ResourceArn: " arn:aws:ec2:us-east-1:111111111111:instance/i-abcdefgh987654321"

          • ResourceType (string) --

            The resource type.

            Example of ResourceType: " AWS::SystemsManagerSAP::Component" or " AWS::EC2::Instance".

        • Status (string) --

          The status of the operation event. The possible statuses are: IN_PROGRESS, COMPLETED, and FAILED.

        • StatusMessage (string) --

          The status message relating to a specific operation event.

        • Timestamp (datetime) --

          The timestamp of the specified operation event.

    • NextToken (string) --

      The token to use to retrieve the next page of results. This value is null when there are no more results to return.

StopApplication (new) Link ¶

Request is an operation to stop an application.

Parameter ApplicationId is required. Parameters StopConnectedEntity and IncludeEc2InstanceShutdown are optional.

See also: AWS API Documentation

Request Syntax

client.stop_application(
    ApplicationId='string',
    StopConnectedEntity='DBMS',
    IncludeEc2InstanceShutdown=True|False
)
type ApplicationId:

string

param ApplicationId:

[REQUIRED]

The ID of the application.

type StopConnectedEntity:

string

param StopConnectedEntity:

Specify the ConnectedEntityType. Accepted type is DBMS.

If this parameter is included, the connected DBMS (Database Management System) will be stopped.

type IncludeEc2InstanceShutdown:

boolean

param IncludeEc2InstanceShutdown:

Boolean. If included and if set to True, the StopApplication operation will shut down the associated Amazon EC2 instance in addition to the application.

rtype:

dict

returns:

Response Syntax

{
    'OperationId': 'string'
}

Response Structure

  • (dict) --

    • OperationId (string) --

      The ID of the operation.