# 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
mysql_client = oci.mysql.MysqlaasClient(config)


# Send the request to service, some parameters are not required, see API
# doc for more info
create_configuration_response = mysql_client.create_configuration(
    create_configuration_details=oci.mysql.models.CreateConfigurationDetails(
        compartment_id="ocid1.test.oc1..<unique_ID>EXAMPLE-compartmentId-Value",
        shape_name="EXAMPLE-shapeName-Value",
        description="EXAMPLE-description-Value",
        display_name="EXAMPLE-displayName-Value",
        init_variables=oci.mysql.models.InitializationVariables(
            lower_case_table_names="CASE_SENSITIVE"),
        variables=oci.mysql.models.ConfigurationVariables(
            completion_type="CHAIN",
            big_tables=False,
            character_set_server="MACCE",
            collation_server="HEBREW_GENERAL_CI",
            connection_memory_chunk_size=357048240,
            connection_memory_limit=4715650165854973952,
            default_authentication_plugin="mysql_native_password",
            global_connection_memory_limit=2539253621885557760,
            global_connection_memory_tracking=False,
            transaction_isolation="READ-COMMITTED",
            innodb_ft_server_stopword_table="EXAMPLE-innodbFtServerStopwordTable-Value",
            mandatory_roles="EXAMPLE-mandatoryRoles-Value",
            autocommit=True,
            foreign_key_checks=True,
            group_replication_consistency="BEFORE_ON_PRIMARY_FAILOVER",
            group_concat_max_len=3534152947669888004,
            innodb_ft_enable_stopword=True,
            innodb_log_writer_threads=False,
            local_infile=False,
            mysql_firewall_mode=False,
            mysqlx_enable_hello_notice=False,
            sql_require_primary_key=True,
            sql_warnings=False,
            binlog_expire_logs_seconds=139,
            binlog_row_metadata="FULL",
            binlog_row_value_options="EXAMPLE-binlogRowValueOptions-Value",
            binlog_transaction_compression=True,
            innodb_buffer_pool_size=4826571239360691200,
            innodb_ft_result_cache_limit=3465868752,
            max_binlog_cache_size=36434469180241,
            max_connect_errors=8234578931715021825,
            max_heap_table_size=6168440960783158272,
            max_connections=13607,
            max_prepared_stmt_count=3274808,
            connect_timeout=28711536,
            cte_max_recursion_depth=2521138250,
            generated_random_password_length=88,
            information_schema_stats_expiry=26636598,
            innodb_buffer_pool_dump_pct=39,
            innodb_buffer_pool_instances=36,
            innodb_ddl_buffer_size=1206944139,
            innodb_ddl_threads=50,
            innodb_ft_max_token_size=27,
            innodb_ft_min_token_size=15,
            innodb_ft_num_word_optimize=448,
            innodb_lock_wait_timeout=415399307,
            innodb_max_purge_lag=1044157311,
            innodb_max_purge_lag_delay=835668,
            interactive_timeout=4966201,
            innodb_stats_persistent_sample_pages=3565185913712074753,
            innodb_stats_transient_sample_pages=4562656875017678849,
            innodb_strict_mode=True,
            max_allowed_packet=903509813,
            max_execution_time=3976834339941426176,
            mysqlx_connect_timeout=965769647,
            mysqlx_document_id_unique_prefix=40677,
            mysqlx_idle_worker_thread_timeout=166,
            mysqlx_interactive_timeout=1983713,
            mysqlx_max_allowed_packet=585943040,
            mysqlx_min_worker_threads=96,
            mysqlx_read_timeout=595981,
            mysqlx_wait_timeout=1971583,
            mysqlx_write_timeout=1111068,
            net_read_timeout=14280650,
            net_write_timeout=29119882,
            parser_max_mem_size=8652508376244121216,
            query_alloc_block_size=370343010,
            query_prealloc_size=1600383674330611200,
            regexp_time_limit=1296662766,
            sql_mode="EXAMPLE-sqlMode-Value",
            tmp_table_size=7011350006638650368,
            mysqlx_deflate_default_compression_level=2,
            mysqlx_deflate_max_client_compression_level=4,
            mysqlx_lz4_max_client_compression_level=6,
            mysqlx_lz4_default_compression_level=7,
            mysqlx_zstd_max_client_compression_level=12,
            mysqlx_zstd_default_compression_level=11,
            mysql_zstd_default_compression_level=10,
            sort_buffer_size=4227610739885425152,
            wait_timeout=1582470,
            thread_pool_dedicated_listeners=True,
            thread_pool_max_transactions_limit=30880,
            time_zone="EXAMPLE-timeZone-Value",
            block_encryption_mode="EXAMPLE-blockEncryptionMode-Value",
            binlog_group_commit_sync_delay=586563,
            binlog_group_commit_sync_no_delay_count=3261,
            replica_net_timeout=1677903,
            require_secure_transport=True,
            innodb_redo_log_capacity=57959185063,
            thread_pool_transaction_delay=21951,
            thread_pool_query_threads_per_group=2514,
            explain_format="TRADITIONAL",
            explicit_defaults_for_timestamp=False,
            sql_generate_invisible_primary_key=False,
            temptable_max_ram=4209119086841171456,
            innodb_change_buffering="NONE",
            innodb_adaptive_hash_index=True,
            innodb_undo_log_truncate=False,
            table_definition_cache=18944,
            table_open_cache=223565,
            relay_log_space_limit=523561086131816448,
            optimizer_switch="EXAMPLE-optimizerSwitch-Value",
            replica_type_conversions="EXAMPLE-replicaTypeConversions-Value",
            replica_parallel_workers=653,
            skip_name_resolve=True,
            max_user_connections=3371703752,
            join_buffer_size=3197995930910485632,
            max_seeks_for_key=9127631160543476737,
            range_optimizer_max_mem_size=5279452403220576256,
            auto_increment_increment=38810,
            auto_increment_offset=3243,
            innodb_autoinc_lock_mode=281,
            innodb_rollback_on_timeout=False,
            innodb_online_alter_log_max_size=7383666005136447488,
            innodb_sort_buffer_size=14602320,
            innodb_numa_interleave=True,
            thread_pool_size=342,
            long_query_time=9018970),
        parent_configuration_id="ocid1.test.oc1..<unique_ID>EXAMPLE-parentConfigurationId-Value",
        freeform_tags={
            'EXAMPLE_KEY_k5vPD': 'EXAMPLE_VALUE_ySOijvCZKG1PagnyJx2Z'},
        defined_tags={
            'EXAMPLE_KEY_XEBVv': {
                'EXAMPLE_KEY_W2tRj': 'EXAMPLE--Value'}}),
    opc_request_id="SOLEJYQGFVVMMVA5W8WE<unique_ID>",
    opc_retry_token="EXAMPLE-opcRetryToken-Value")

# Get the data from response
print(create_configuration_response.data)

Was this article helpful?