Skip to content

/AWS1/CL_DRS=>UPDATELAUNCHCONFIGURATION()

About UpdateLaunchConfiguration

Updates a LaunchConfiguration by Source Server ID.

Method Signature

IMPORTING

Required arguments:

iv_sourceserverid TYPE /AWS1/DRSSOURCESERVERID /AWS1/DRSSOURCESERVERID

The ID of the Source Server that we want to retrieve a Launch Configuration for.

Optional arguments:

iv_name TYPE /AWS1/DRSSMALLBOUNDEDSTRING /AWS1/DRSSMALLBOUNDEDSTRING

The name of the launch configuration.

iv_launchdisposition TYPE /AWS1/DRSLAUNCHDISPOSITION /AWS1/DRSLAUNCHDISPOSITION

The state of the Recovery Instance in EC2 after the recovery operation.

iv_tgtinsttyperightsizingmth TYPE /AWS1/DRSTGTINSTTYPERIGHTSIZ00 /AWS1/DRSTGTINSTTYPERIGHTSIZ00

Whether Elastic Disaster Recovery should try to automatically choose the instance type that best matches the OS, CPU, and RAM of your Source Server.

iv_copyprivateip TYPE /AWS1/DRSBOOLEAN /AWS1/DRSBOOLEAN

Whether we should copy the Private IP of the Source Server to the Recovery Instance.

iv_copytags TYPE /AWS1/DRSBOOLEAN /AWS1/DRSBOOLEAN

Whether we want to copy the tags of the Source Server to the EC2 machine of the Recovery Instance.

io_licensing TYPE REF TO /AWS1/CL_DRSLICENSING /AWS1/CL_DRSLICENSING

The licensing configuration to be used for this launch configuration.

iv_postlaunchenabled TYPE /AWS1/DRSBOOLEAN /AWS1/DRSBOOLEAN

Whether we want to enable post-launch actions for the Source Server.

io_launchintoinstanceprps TYPE REF TO /AWS1/CL_DRSLAUNCHINTOINSTPRPS /AWS1/CL_DRSLAUNCHINTOINSTPRPS

Launch into existing instance properties.

RETURNING

oo_output TYPE REF TO /aws1/cl_drslaunchconf /AWS1/CL_DRSLAUNCHCONF

Domain /AWS1/RT_ACCOUNT_ID
Primitive Type NUMC

Examples

Syntax Example

This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.

DATA(lo_result) = lo_client->/aws1/if_drs~updatelaunchconfiguration(
  io_launchintoinstanceprps = new /aws1/cl_drslaunchintoinstprps( |string| )
  io_licensing = new /aws1/cl_drslicensing( ABAP_TRUE )
  iv_copyprivateip = ABAP_TRUE
  iv_copytags = ABAP_TRUE
  iv_launchdisposition = |string|
  iv_name = |string|
  iv_postlaunchenabled = ABAP_TRUE
  iv_sourceserverid = |string|
  iv_tgtinsttyperightsizingmth = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  lv_sourceserverid = lo_result->get_sourceserverid( ).
  lv_smallboundedstring = lo_result->get_name( ).
  lv_boundedstring = lo_result->get_ec2launchtemplateid( ).
  lv_launchdisposition = lo_result->get_launchdisposition( ).
  lv_targetinstancetyperight = lo_result->get_tgtinsttyperightsizing00( ).
  lv_boolean = lo_result->get_copyprivateip( ).
  lv_boolean = lo_result->get_copytags( ).
  lo_licensing = lo_result->get_licensing( ).
  IF lo_licensing IS NOT INITIAL.
    lv_boolean = lo_licensing->get_osbyol( ).
  ENDIF.
  lv_boolean = lo_result->get_postlaunchenabled( ).
  lo_launchintoinstanceprope = lo_result->get_launchintoinstanceprps( ).
  IF lo_launchintoinstanceprope IS NOT INITIAL.
    lv_ec2instanceid = lo_launchintoinstanceprope->get_launchintoec2instanceid( ).
  ENDIF.
ENDIF.