# This is an automatically generated code sample.
# To make this code sample work in your Oracle Cloud tenancy,
# please replace the values for any parameters whose current values do not fit
# your use case (such as resource IDs, strings containing ‘EXAMPLE’ or ‘unique_id’, and
# boolean, number, and enum parameters with values not fitting your use case).
import oci
# Create a default config using DEFAULT profile in default location
# Refer to
# https://docs.cloud.oracle.com/en-us/iaas/Content/API/Concepts/sdkconfig.htm#SDK_and_CLI_Configuration_File
# for more info
config = oci.config.from_file()
# Initialize service client with default config file
cloud_migrations_client = oci.cloud_migrations.MigrationClient(config)
# Send the request to service, some parameters are not required, see API
# doc for more info
update_migration_plan_response = cloud_migrations_client.update_migration_plan(
migration_plan_id="ocid1.test.oc1..<unique_ID>EXAMPLE-migrationPlanId-Value",
update_migration_plan_details=oci.cloud_migrations.models.UpdateMigrationPlanDetails(
display_name="EXAMPLE-displayName-Value",
strategies=[
oci.cloud_migrations.models.PeakResourceAssessmentStrategy(
strategy_type="PEAK",
resource_type="MEMORY",
adjustment_multiplier=3375.9607,
metric_type="RUNTIME",
metric_time_window="1d")],
target_environments=[
oci.cloud_migrations.models.OlvmTargetEnvironment(
target_environment_type="OLVM_TARGET_ENV",
cluster_asset_id="ocid1.test.oc1..<unique_ID>EXAMPLE-clusterAssetId-Value",
vnic_profile_asset_id="ocid1.test.oc1..<unique_ID>EXAMPLE-vnicProfileAssetId-Value",
target_compartment_id="ocid1.test.oc1..<unique_ID>EXAMPLE-targetCompartmentId-Value",
olvm_templates={
'EXAMPLE_KEY_EUG39': 'EXAMPLE_VALUE_SE9IZhDeyybAcg52aD23'},
preferred_shape_type="VM_AMD_Standard")],
freeform_tags={
'EXAMPLE_KEY_FTNJM': 'EXAMPLE_VALUE_wqs2HxrRcEYtATzx8dwW'},
defined_tags={
'EXAMPLE_KEY_lWju7': {
'EXAMPLE_KEY_1m5TY': 'EXAMPLE--Value'}}),
opc_retry_token="EXAMPLE-opcRetryToken-Value",
if_match="EXAMPLE-ifMatch-Value",
opc_request_id="VJRD3YMB0LJJ75KMGI2D<unique_ID>")
# Get the data from response
print(update_migration_plan_response.headers)