/AWS1/IF_SMS=>CREATEREPLICATIONJOB()¶
About CreateReplicationJob¶
Creates a replication job. The replication job schedules periodic replication runs to replicate your server to Amazon Web Services. Each replication run creates an Amazon Machine Image (AMI).
Method Signature¶
IMPORTING¶
Required arguments:¶
iv_serverid TYPE /AWS1/SMSSERVERID /AWS1/SMSSERVERID¶
The ID of the server.
iv_seedreplicationtime TYPE /AWS1/SMSTIMESTAMP /AWS1/SMSTIMESTAMP¶
The seed replication time.
Optional arguments:¶
iv_frequency TYPE /AWS1/SMSFREQUENCY /AWS1/SMSFREQUENCY¶
The time between consecutive replication runs, in hours.
iv_runonce TYPE /AWS1/SMSRUNONCE /AWS1/SMSRUNONCE¶
Indicates whether to run the replication job one time.
iv_licensetype TYPE /AWS1/SMSLICENSETYPE /AWS1/SMSLICENSETYPE¶
The license type to be used for the AMI created by a successful replication run.
iv_rolename TYPE /AWS1/SMSROLENAME /AWS1/SMSROLENAME¶
The name of the IAM role to be used by the Server Migration Service.
iv_description TYPE /AWS1/SMSDESCRIPTION /AWS1/SMSDESCRIPTION¶
The description of the replication job.
iv_numberofrecentamistokeep TYPE /AWS1/SMSNUMOFRECENTAMISTOKEEP /AWS1/SMSNUMOFRECENTAMISTOKEEP¶
The maximum number of SMS-created AMIs to retain. The oldest is deleted after the maximum number is reached and a new AMI is created.
iv_encrypted TYPE /AWS1/SMSENCRYPTED /AWS1/SMSENCRYPTED¶
Indicates whether the replication job produces encrypted AMIs.
iv_kmskeyid TYPE /AWS1/SMSKMSKEYID /AWS1/SMSKMSKEYID¶
The ID of the KMS key for replication jobs that produce encrypted AMIs. This value can be any of the following:
KMS key ID
KMS key alias
ARN referring to the KMS key ID
ARN referring to the KMS key alias
If encrypted is true but a KMS key ID is not specified, the customer's default KMS key for Amazon EBS is used.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_smscreaterepljobrsp /AWS1/CL_SMSCREATEREPLJOBRSP¶
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_sms~createreplicationjob(
iv_description = |string|
iv_encrypted = ABAP_TRUE
iv_frequency = 123
iv_kmskeyid = |string|
iv_licensetype = |string|
iv_numberofrecentamistokeep = 123
iv_rolename = |string|
iv_runonce = ABAP_TRUE
iv_seedreplicationtime = '20150101000000.0000000'
iv_serverid = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_replicationjobid = lo_result->get_replicationjobid( ).
ENDIF.