Class: Aws::MQ::Client

Inherits:
Seahorse::Client::Base show all
Includes:
ClientStubs
Defined in:
gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb

Overview

An API client for MQ. To construct a client, you need to configure a :region and :credentials.

client = Aws::MQ::Client.new(
  region: region_name,
  credentials: credentials,
  # ...
)

For details on configuring region and credentials see the developer guide.

See #initialize for a full list of supported configuration options.

Instance Attribute Summary

Attributes inherited from Seahorse::Client::Base

#config, #handlers

API Operations collapse

Instance Method Summary collapse

Methods included from ClientStubs

#api_requests, #stub_data, #stub_responses

Methods inherited from Seahorse::Client::Base

add_plugin, api, clear_plugins, define, new, #operation_names, plugins, remove_plugin, set_api, set_plugins

Methods included from Seahorse::Client::HandlerBuilder

#handle, #handle_request, #handle_response

Constructor Details

#initialize(options) ⇒ Client

Returns a new instance of Client.

Parameters:

  • options (Hash)

Options Hash (options):

  • :plugins (Array<Seahorse::Client::Plugin>) — default: []]

    A list of plugins to apply to the client. Each plugin is either a class name or an instance of a plugin class.

  • :credentials (required, Aws::CredentialProvider)

    Your AWS credentials. This can be an instance of any one of the following classes:

    • Aws::Credentials - Used for configuring static, non-refreshing credentials.

    • Aws::SharedCredentials - Used for loading static credentials from a shared file, such as ~/.aws/config.

    • Aws::AssumeRoleCredentials - Used when you need to assume a role.

    • Aws::AssumeRoleWebIdentityCredentials - Used when you need to assume a role after providing credentials via the web.

    • Aws::SSOCredentials - Used for loading credentials from AWS SSO using an access token generated from aws login.

    • Aws::ProcessCredentials - Used for loading credentials from a process that outputs to stdout.

    • Aws::InstanceProfileCredentials - Used for loading credentials from an EC2 IMDS on an EC2 instance.

    • Aws::ECSCredentials - Used for loading credentials from instances running in ECS.

    • Aws::CognitoIdentityCredentials - Used for loading credentials from the Cognito Identity service.

    When :credentials are not configured directly, the following locations will be searched for credentials:

    • Aws.config[:credentials]
    • The :access_key_id, :secret_access_key, :session_token, and :account_id options.
    • ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY'], ENV['AWS_SESSION_TOKEN'], and ENV['AWS_ACCOUNT_ID']
    • ~/.aws/credentials
    • ~/.aws/config
    • EC2/ECS IMDS instance profile - When used by default, the timeouts are very aggressive. Construct and pass an instance of Aws::InstanceProfileCredentials or Aws::ECSCredentials to enable retries and extended timeouts. Instance profile credential fetching can be disabled by setting ENV['AWS_EC2_METADATA_DISABLED'] to true.
  • :region (required, String)

    The AWS region to connect to. The configured :region is used to determine the service :endpoint. When not passed, a default :region is searched for in the following locations:

    • Aws.config[:region]
    • ENV['AWS_REGION']
    • ENV['AMAZON_REGION']
    • ENV['AWS_DEFAULT_REGION']
    • ~/.aws/credentials
    • ~/.aws/config
  • :access_key_id (String)
  • :account_id (String)
  • :active_endpoint_cache (Boolean) — default: false

    When set to true, a thread polling for endpoints will be running in the background every 60 secs (default). Defaults to false.

  • :adaptive_retry_wait_to_fill (Boolean) — default: true

    Used only in adaptive retry mode. When true, the request will sleep until there is sufficent client side capacity to retry the request. When false, the request will raise a RetryCapacityNotAvailableError and will not retry instead of sleeping.

  • :client_side_monitoring (Boolean) — default: false

    When true, client-side metrics will be collected for all API requests from this client.

  • :client_side_monitoring_client_id (String) — default: ""

    Allows you to provide an identifier for this client which will be attached to all generated client side metrics. Defaults to an empty string.

  • :client_side_monitoring_host (String) — default: "127.0.0.1"

    Allows you to specify the DNS hostname or IPv4 or IPv6 address that the client side monitoring agent is running on, where client metrics will be published via UDP.

  • :client_side_monitoring_port (Integer) — default: 31000

    Required for publishing client metrics. The port that the client side monitoring agent is running on, where client metrics will be published via UDP.

  • :client_side_monitoring_publisher (Aws::ClientSideMonitoring::Publisher) — default: Aws::ClientSideMonitoring::Publisher

    Allows you to provide a custom client-side monitoring publisher class. By default, will use the Client Side Monitoring Agent Publisher.

  • :convert_params (Boolean) — default: true

    When true, an attempt is made to coerce request parameters into the required types.

  • :correct_clock_skew (Boolean) — default: true

    Used only in standard and adaptive retry modes. Specifies whether to apply a clock skew correction and retry requests with skewed client clocks.

  • :defaults_mode (String) — default: "legacy"

    See DefaultsModeConfiguration for a list of the accepted modes and the configuration defaults that are included.

  • :disable_host_prefix_injection (Boolean) — default: false

    Set to true to disable SDK automatically adding host prefix to default service endpoint when available.

  • :disable_request_compression (Boolean) — default: false

    When set to 'true' the request body will not be compressed for supported operations.

  • :endpoint (String, URI::HTTPS, URI::HTTP)

    Normally you should not configure the :endpoint option directly. This is normally constructed from the :region option. Configuring :endpoint is normally reserved for connecting to test or custom endpoints. The endpoint should be a URI formatted like:

    'http://example.com'
    'https://example.com'
    'http://example.com:123'
    
  • :endpoint_cache_max_entries (Integer) — default: 1000

    Used for the maximum size limit of the LRU cache storing endpoints data for endpoint discovery enabled operations. Defaults to 1000.

  • :endpoint_cache_max_threads (Integer) — default: 10

    Used for the maximum threads in use for polling endpoints to be cached, defaults to 10.

  • :endpoint_cache_poll_interval (Integer) — default: 60

    When :endpoint_discovery and :active_endpoint_cache is enabled, Use this option to config the time interval in seconds for making requests fetching endpoints information. Defaults to 60 sec.

  • :endpoint_discovery (Boolean) — default: false

    When set to true, endpoint discovery will be enabled for operations when available.

  • :ignore_configured_endpoint_urls (Boolean)

    Setting to true disables use of endpoint URLs provided via environment variables and the shared configuration file.

  • :log_formatter (Aws::Log::Formatter) — default: Aws::Log::Formatter.default

    The log formatter.

  • :log_level (Symbol) — default: :info

    The log level to send messages to the :logger at.

  • :logger (Logger)

    The Logger instance to send log messages to. If this option is not set, logging will be disabled.

  • :max_attempts (Integer) — default: 3

    An integer representing the maximum number attempts that will be made for a single request, including the initial attempt. For example, setting this value to 5 will result in a request being retried up to 4 times. Used in standard and adaptive retry modes.

  • :profile (String) — default: "default"

    Used when loading credentials from the shared credentials file at HOME/.aws/credentials. When not specified, 'default' is used.

  • :request_min_compression_size_bytes (Integer) — default: 10240

    The minimum size in bytes that triggers compression for request bodies. The value must be non-negative integer value between 0 and 10485780 bytes inclusive.

  • :retry_backoff (Proc)

    A proc or lambda used for backoff. Defaults to 2**retries * retry_base_delay. This option is only used in the legacy retry mode.

  • :retry_base_delay (Float) — default: 0.3

    The base delay in seconds used by the default backoff function. This option is only used in the legacy retry mode.

  • :retry_jitter (Symbol) — default: :none

    A delay randomiser function used by the default backoff function. Some predefined functions can be referenced by name - :none, :equal, :full, otherwise a Proc that takes and returns a number. This option is only used in the legacy retry mode.

    @see https://www.awsarchitectureblog.com/2015/03/backoff.html

  • :retry_limit (Integer) — default: 3

    The maximum number of times to retry failed requests. Only ~ 500 level server errors and certain ~ 400 level client errors are retried. Generally, these are throttling errors, data checksum errors, networking errors, timeout errors, auth errors, endpoint discovery, and errors from expired credentials. This option is only used in the legacy retry mode.

  • :retry_max_delay (Integer) — default: 0

    The maximum number of seconds to delay between retries (0 for no limit) used by the default backoff function. This option is only used in the legacy retry mode.

  • :retry_mode (String) — default: "legacy"

    Specifies which retry algorithm to use. Values are:

    • legacy - The pre-existing retry behavior. This is default value if no retry mode is provided.

    • standard - A standardized set of retry rules across the AWS SDKs. This includes support for retry quotas, which limit the number of unsuccessful retries a client can make.

    • adaptive - An experimental retry mode that includes all the functionality of standard mode along with automatic client side throttling. This is a provisional mode that may change behavior in the future.

  • :sdk_ua_app_id (String)

    A unique and opaque application ID that is appended to the User-Agent header as app/sdk_ua_app_id. It should have a maximum length of 50. This variable is sourced from environment variable AWS_SDK_UA_APP_ID or the shared config profile attribute sdk_ua_app_id.

  • :secret_access_key (String)
  • :session_token (String)
  • :sigv4a_signing_region_set (Array)

    A list of regions that should be signed with SigV4a signing. When not passed, a default :sigv4a_signing_region_set is searched for in the following locations:

    • Aws.config[:sigv4a_signing_region_set]
    • ENV['AWS_SIGV4A_SIGNING_REGION_SET']
    • ~/.aws/config
  • :stub_responses (Boolean) — default: false

    Causes the client to return stubbed responses. By default fake responses are generated and returned. You can specify the response data to return or errors to raise by calling ClientStubs#stub_responses. See ClientStubs for more information.

    Please note When response stubbing is enabled, no HTTP requests are made, and retries are disabled.

  • :telemetry_provider (Aws::Telemetry::TelemetryProviderBase) — default: Aws::Telemetry::NoOpTelemetryProvider

    Allows you to provide a telemetry provider, which is used to emit telemetry data. By default, uses NoOpTelemetryProvider which will not record or emit any telemetry data. The SDK supports the following telemetry providers:

    • OpenTelemetry (OTel) - To use the OTel provider, install and require the opentelemetry-sdk gem and then, pass in an instance of a Aws::Telemetry::OTelProvider for telemetry provider.
  • :token_provider (Aws::TokenProvider)

    A Bearer Token Provider. This can be an instance of any one of the following classes:

    • Aws::StaticTokenProvider - Used for configuring static, non-refreshing tokens.

    • Aws::SSOTokenProvider - Used for loading tokens from AWS SSO using an access token generated from aws login.

    When :token_provider is not configured directly, the Aws::TokenProviderChain will be used to search for tokens configured for your profile in shared configuration files.

  • :use_dualstack_endpoint (Boolean)

    When set to true, dualstack enabled endpoints (with .aws TLD) will be used if available.

  • :use_fips_endpoint (Boolean)

    When set to true, fips compatible endpoints will be used if available. When a fips region is used, the region is normalized and this config is set to true.

  • :validate_params (Boolean) — default: true

    When true, request parameters are validated before sending the request.

  • :endpoint_provider (Aws::MQ::EndpointProvider)

    The endpoint provider used to resolve endpoints. Any object that responds to #resolve_endpoint(parameters) where parameters is a Struct similar to Aws::MQ::EndpointParameters.

  • :http_continue_timeout (Float) — default: 1

    The number of seconds to wait for a 100-continue response before sending the request body. This option has no effect unless the request has "Expect" header set to "100-continue". Defaults to nil which disables this behaviour. This value can safely be set per request on the session.

  • :http_idle_timeout (Float) — default: 5

    The number of seconds a connection is allowed to sit idle before it is considered stale. Stale connections are closed and removed from the pool before making a request.

  • :http_open_timeout (Float) — default: 15

    The default number of seconds to wait for response data. This value can safely be set per-request on the session.

  • :http_proxy (URI::HTTP, String)

    A proxy to send requests through. Formatted like 'http://proxy.com:123'.

  • :http_read_timeout (Float) — default: 60

    The default number of seconds to wait for response data. This value can safely be set per-request on the session.

  • :http_wire_trace (Boolean) — default: false

    When true, HTTP debug output will be sent to the :logger.

  • :on_chunk_received (Proc)

    When a Proc object is provided, it will be used as callback when each chunk of the response body is received. It provides three arguments: the chunk, the number of bytes received, and the total number of bytes in the response (or nil if the server did not send a content-length).

  • :on_chunk_sent (Proc)

    When a Proc object is provided, it will be used as callback when each chunk of the request body is sent. It provides three arguments: the chunk, the number of bytes read from the body, and the total number of bytes in the body.

  • :raise_response_errors (Boolean) — default: true

    When true, response errors are raised.

  • :ssl_ca_bundle (String)

    Full path to the SSL certificate authority bundle file that should be used when verifying peer certificates. If you do not pass :ssl_ca_bundle or :ssl_ca_directory the the system default will be used if available.

  • :ssl_ca_directory (String)

    Full path of the directory that contains the unbundled SSL certificate authority files for verifying peer certificates. If you do not pass :ssl_ca_bundle or :ssl_ca_directory the the system default will be used if available.

  • :ssl_ca_store (String)

    Sets the X509::Store to verify peer certificate.

  • :ssl_cert (OpenSSL::X509::Certificate)

    Sets a client certificate when creating http connections.

  • :ssl_key (OpenSSL::PKey)

    Sets a client key when creating http connections.

  • :ssl_timeout (Float)

    Sets the SSL timeout in seconds

  • :ssl_verify_peer (Boolean) — default: true

    When true, SSL peer certificates are verified when establishing a connection.



444
445
446
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 444

def initialize(*args)
  super
end

Instance Method Details

#create_broker(params = {}) ⇒ Types::CreateBrokerResponse

Creates a broker. Note: This API is asynchronous.

To create a broker, you must either use the AmazonMQFullAccess IAM policy or include the following EC2 permissions in your IAM policy.

  • ec2:CreateNetworkInterface

    This permission is required to allow Amazon MQ to create an elastic network interface (ENI) on behalf of your account.

  • ec2:CreateNetworkInterfacePermission

    This permission is required to attach the ENI to the broker instance.

  • ec2:DeleteNetworkInterface

  • ec2:DeleteNetworkInterfacePermission

  • ec2:DetachNetworkInterface

  • ec2:DescribeInternetGateways

  • ec2:DescribeNetworkInterfaces

  • ec2:DescribeNetworkInterfacePermissions

  • ec2:DescribeRouteTables

  • ec2:DescribeSecurityGroups

  • ec2:DescribeSubnets

  • ec2:DescribeVpcs

For more information, see Create an IAM User and Get Your Amazon Web Services Credentials and Never Modify or Delete the Amazon MQ Elastic Network Interface in the Amazon MQ Developer Guide.

Examples:

Request syntax with placeholder values


resp = client.create_broker({
  authentication_strategy: "SIMPLE", # accepts SIMPLE, LDAP
  auto_minor_version_upgrade: false,
  broker_name: "__string", # required
  configuration: {
    id: "__string", # required
    revision: 1,
  },
  creator_request_id: "__string",
  deployment_mode: "SINGLE_INSTANCE", # required, accepts SINGLE_INSTANCE, ACTIVE_STANDBY_MULTI_AZ, CLUSTER_MULTI_AZ
  encryption_options: {
    kms_key_id: "__string",
    use_aws_owned_key: false, # required
  },
  engine_type: "ACTIVEMQ", # required, accepts ACTIVEMQ, RABBITMQ
  engine_version: "__string",
  host_instance_type: "__string", # required
  ldap_server_metadata: {
    hosts: ["__string"], # required
    role_base: "__string", # required
    role_name: "__string",
    role_search_matching: "__string", # required
    role_search_subtree: false,
    service_account_password: "__string", # required
    service_account_username: "__string", # required
    user_base: "__string", # required
    user_role_name: "__string",
    user_search_matching: "__string", # required
    user_search_subtree: false,
  },
  logs: {
    audit: false,
    general: false,
  },
  maintenance_window_start_time: {
    day_of_week: "MONDAY", # required, accepts MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, SUNDAY
    time_of_day: "__string", # required
    time_zone: "__string",
  },
  publicly_accessible: false, # required
  security_groups: ["__string"],
  storage_type: "EBS", # accepts EBS, EFS
  subnet_ids: ["__string"],
  tags: {
    "__string" => "__string",
  },
  users: [ # required
    {
      console_access: false,
      groups: ["__string"],
      password: "__string", # required
      username: "__string", # required
      replication_user: false,
    },
  ],
  data_replication_mode: "NONE", # accepts NONE, CRDR
  data_replication_primary_broker_arn: "__string",
})

Response structure


resp.broker_arn #=> String
resp.broker_id #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :authentication_strategy (String)

    Optional. The authentication strategy used to secure the broker. The default is SIMPLE.

  • :auto_minor_version_upgrade (Boolean)
  • :broker_name (required, String)
  • :configuration (Types::ConfigurationId)

    A list of information about the configuration.

  • :creator_request_id (String)

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :deployment_mode (required, String)

    The broker's deployment mode.

  • :encryption_options (Types::EncryptionOptions)

    Encryption options for the broker.

  • :engine_type (required, String)

    The type of broker engine. Amazon MQ supports ActiveMQ and RabbitMQ.

  • :engine_version (String)
  • :host_instance_type (required, String)
  • :ldap_server_metadata (Types::LdapServerMetadataInput)

    Optional. The metadata of the LDAP server used to authenticate and authorize connections to the broker.

    Does not apply to RabbitMQ brokers.

  • :logs (Types::Logs)

    The list of information about logs to be enabled for the specified broker.

  • :maintenance_window_start_time (Types::WeeklyStartTime)

    The scheduled time period relative to UTC during which Amazon MQ begins to apply pending updates or patches to the broker.

  • :publicly_accessible (required, Boolean)
  • :security_groups (Array<String>)
  • :storage_type (String)

    The broker's storage type.

    EFS is not supported for RabbitMQ engine type.

  • :subnet_ids (Array<String>)
  • :tags (Hash<String,String>)
  • :users (required, Array<Types::User>)
  • :data_replication_mode (String)

    Specifies whether a broker is a part of a data replication pair.

  • :data_replication_primary_broker_arn (String)

Returns:

See Also:



631
632
633
634
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 631

def create_broker(params = {}, options = {})
  req = build_request(:create_broker, params)
  req.send_request(options)
end

#create_configuration(params = {}) ⇒ Types::CreateConfigurationResponse

Creates a new configuration for the specified configuration name. Amazon MQ uses the default configuration (the engine type and version).

Examples:

Request syntax with placeholder values


resp = client.create_configuration({
  authentication_strategy: "SIMPLE", # accepts SIMPLE, LDAP
  engine_type: "ACTIVEMQ", # required, accepts ACTIVEMQ, RABBITMQ
  engine_version: "__string",
  name: "__string", # required
  tags: {
    "__string" => "__string",
  },
})

Response structure


resp.arn #=> String
resp.authentication_strategy #=> String, one of "SIMPLE", "LDAP"
resp.created #=> Time
resp.id #=> String
resp.latest_revision.created #=> Time
resp.latest_revision.description #=> String
resp.latest_revision.revision #=> Integer
resp.name #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :authentication_strategy (String)

    Optional. The authentication strategy used to secure the broker. The default is SIMPLE.

  • :engine_type (required, String)

    The type of broker engine. Amazon MQ supports ActiveMQ and RabbitMQ.

  • :engine_version (String)
  • :name (required, String)
  • :tags (Hash<String,String>)

Returns:

See Also:



689
690
691
692
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 689

def create_configuration(params = {}, options = {})
  req = build_request(:create_configuration, params)
  req.send_request(options)
end

#create_tags(params = {}) ⇒ Struct

Add a tag to a resource.

Examples:

Request syntax with placeholder values


resp = client.create_tags({
  resource_arn: "__string", # required
  tags: {
    "__string" => "__string",
  },
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :resource_arn (required, String)
  • :tags (Hash<String,String>)

Returns:

  • (Struct)

    Returns an empty response.

See Also:



715
716
717
718
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 715

def create_tags(params = {}, options = {})
  req = build_request(:create_tags, params)
  req.send_request(options)
end

#create_user(params = {}) ⇒ Struct

Creates an ActiveMQ user.

Do not add personally identifiable information (PII) or other confidential or sensitive information in broker usernames. Broker usernames are accessible to other Amazon Web Services services, including CloudWatch Logs. Broker usernames are not intended to be used for private or sensitive data.

Examples:

Request syntax with placeholder values


resp = client.create_user({
  broker_id: "__string", # required
  console_access: false,
  groups: ["__string"],
  password: "__string", # required
  username: "__string", # required
  replication_user: false,
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :broker_id (required, String)
  • :console_access (Boolean)
  • :groups (Array<String>)
  • :password (required, String)
  • :username (required, String)
  • :replication_user (Boolean)

Returns:

  • (Struct)

    Returns an empty response.

See Also:



757
758
759
760
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 757

def create_user(params = {}, options = {})
  req = build_request(:create_user, params)
  req.send_request(options)
end

#delete_broker(params = {}) ⇒ Types::DeleteBrokerResponse

Deletes a broker. Note: This API is asynchronous.

Examples:

Request syntax with placeholder values


resp = client.delete_broker({
  broker_id: "__string", # required
})

Response structure


resp.broker_id #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :broker_id (required, String)

Returns:

See Also:



784
785
786
787
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 784

def delete_broker(params = {}, options = {})
  req = build_request(:delete_broker, params)
  req.send_request(options)
end

#delete_tags(params = {}) ⇒ Struct

Removes a tag from a resource.

Examples:

Request syntax with placeholder values


resp = client.delete_tags({
  resource_arn: "__string", # required
  tag_keys: ["__string"], # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :resource_arn (required, String)
  • :tag_keys (required, Array<String>)

Returns:

  • (Struct)

    Returns an empty response.

See Also:



808
809
810
811
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 808

def delete_tags(params = {}, options = {})
  req = build_request(:delete_tags, params)
  req.send_request(options)
end

#delete_user(params = {}) ⇒ Struct

Deletes an ActiveMQ user.

Examples:

Request syntax with placeholder values


resp = client.delete_user({
  broker_id: "__string", # required
  username: "__string", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :broker_id (required, String)
  • :username (required, String)

Returns:

  • (Struct)

    Returns an empty response.

See Also:



832
833
834
835
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 832

def delete_user(params = {}, options = {})
  req = build_request(:delete_user, params)
  req.send_request(options)
end

#describe_broker(params = {}) ⇒ Types::DescribeBrokerResponse

Returns information about the specified broker.

Examples:

Request syntax with placeholder values


resp = client.describe_broker({
  broker_id: "__string", # required
})

Response structure


resp.actions_required #=> Array
resp.actions_required[0].action_required_code #=> String
resp.actions_required[0].action_required_info #=> String
resp.authentication_strategy #=> String, one of "SIMPLE", "LDAP"
resp.auto_minor_version_upgrade #=> Boolean
resp.broker_arn #=> String
resp.broker_id #=> String
resp.broker_instances #=> Array
resp.broker_instances[0].console_url #=> String
resp.broker_instances[0].endpoints #=> Array
resp.broker_instances[0].endpoints[0] #=> String
resp.broker_instances[0].ip_address #=> String
resp.broker_name #=> String
resp.broker_state #=> String, one of "CREATION_IN_PROGRESS", "CREATION_FAILED", "DELETION_IN_PROGRESS", "RUNNING", "REBOOT_IN_PROGRESS", "CRITICAL_ACTION_REQUIRED", "REPLICA"
resp.configurations.current.id #=> String
resp.configurations.current.revision #=> Integer
resp.configurations.history #=> Array
resp.configurations.history[0].id #=> String
resp.configurations.history[0].revision #=> Integer
resp.configurations.pending.id #=> String
resp.configurations.pending.revision #=> Integer
resp.created #=> Time
resp.deployment_mode #=> String, one of "SINGLE_INSTANCE", "ACTIVE_STANDBY_MULTI_AZ", "CLUSTER_MULTI_AZ"
resp.encryption_options.kms_key_id #=> String
resp.encryption_options.use_aws_owned_key #=> Boolean
resp.engine_type #=> String, one of "ACTIVEMQ", "RABBITMQ"
resp.engine_version #=> String
resp.host_instance_type #=> String
resp..hosts #=> Array
resp..hosts[0] #=> String
resp..role_base #=> String
resp..role_name #=> String
resp..role_search_matching #=> String
resp..role_search_subtree #=> Boolean
resp.. #=> String
resp..user_base #=> String
resp..user_role_name #=> String
resp..user_search_matching #=> String
resp..user_search_subtree #=> Boolean
resp.logs.audit #=> Boolean
resp.logs.audit_log_group #=> String
resp.logs.general #=> Boolean
resp.logs.general_log_group #=> String
resp.logs.pending.audit #=> Boolean
resp.logs.pending.general #=> Boolean
resp.maintenance_window_start_time.day_of_week #=> String, one of "MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY", "SATURDAY", "SUNDAY"
resp.maintenance_window_start_time.time_of_day #=> String
resp.maintenance_window_start_time.time_zone #=> String
resp.pending_authentication_strategy #=> String, one of "SIMPLE", "LDAP"
resp.pending_engine_version #=> String
resp.pending_host_instance_type #=> String
resp..hosts #=> Array
resp..hosts[0] #=> String
resp..role_base #=> String
resp..role_name #=> String
resp..role_search_matching #=> String
resp..role_search_subtree #=> Boolean
resp.. #=> String
resp..user_base #=> String
resp..user_role_name #=> String
resp..user_search_matching #=> String
resp..user_search_subtree #=> Boolean
resp.pending_security_groups #=> Array
resp.pending_security_groups[0] #=> String
resp.publicly_accessible #=> Boolean
resp.security_groups #=> Array
resp.security_groups[0] #=> String
resp.storage_type #=> String, one of "EBS", "EFS"
resp.subnet_ids #=> Array
resp.subnet_ids[0] #=> String
resp.tags #=> Hash
resp.tags["__string"] #=> String
resp.users #=> Array
resp.users[0].pending_change #=> String, one of "CREATE", "UPDATE", "DELETE"
resp.users[0].username #=> String
resp..data_replication_counterpart.broker_id #=> String
resp..data_replication_counterpart.region #=> String
resp..data_replication_role #=> String
resp.data_replication_mode #=> String, one of "NONE", "CRDR"
resp..data_replication_counterpart.broker_id #=> String
resp..data_replication_counterpart.region #=> String
resp..data_replication_role #=> String
resp.pending_data_replication_mode #=> String, one of "NONE", "CRDR"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :broker_id (required, String)

Returns:

See Also:



973
974
975
976
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 973

def describe_broker(params = {}, options = {})
  req = build_request(:describe_broker, params)
  req.send_request(options)
end

#describe_broker_engine_types(params = {}) ⇒ Types::DescribeBrokerEngineTypesResponse

Describe available engine types and versions.

Examples:

Request syntax with placeholder values


resp = client.describe_broker_engine_types({
  engine_type: "__string",
  max_results: 1,
  next_token: "__string",
})

Response structure


resp.broker_engine_types #=> Array
resp.broker_engine_types[0].engine_type #=> String, one of "ACTIVEMQ", "RABBITMQ"
resp.broker_engine_types[0].engine_versions #=> Array
resp.broker_engine_types[0].engine_versions[0].name #=> String
resp.max_results #=> Integer
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :engine_type (String)
  • :max_results (Integer)
  • :next_token (String)

Returns:

See Also:



1013
1014
1015
1016
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1013

def describe_broker_engine_types(params = {}, options = {})
  req = build_request(:describe_broker_engine_types, params)
  req.send_request(options)
end

#describe_broker_instance_options(params = {}) ⇒ Types::DescribeBrokerInstanceOptionsResponse

Describe available broker instance options.

Examples:

Request syntax with placeholder values


resp = client.describe_broker_instance_options({
  engine_type: "__string",
  host_instance_type: "__string",
  max_results: 1,
  next_token: "__string",
  storage_type: "__string",
})

Response structure


resp.broker_instance_options #=> Array
resp.broker_instance_options[0].availability_zones #=> Array
resp.broker_instance_options[0].availability_zones[0].name #=> String
resp.broker_instance_options[0].engine_type #=> String, one of "ACTIVEMQ", "RABBITMQ"
resp.broker_instance_options[0].host_instance_type #=> String
resp.broker_instance_options[0].storage_type #=> String, one of "EBS", "EFS"
resp.broker_instance_options[0].supported_deployment_modes #=> Array
resp.broker_instance_options[0].supported_deployment_modes[0] #=> String, one of "SINGLE_INSTANCE", "ACTIVE_STANDBY_MULTI_AZ", "CLUSTER_MULTI_AZ"
resp.broker_instance_options[0].supported_engine_versions #=> Array
resp.broker_instance_options[0].supported_engine_versions[0] #=> String
resp.max_results #=> Integer
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :engine_type (String)
  • :host_instance_type (String)
  • :max_results (Integer)
  • :next_token (String)
  • :storage_type (String)

Returns:

See Also:



1065
1066
1067
1068
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1065

def describe_broker_instance_options(params = {}, options = {})
  req = build_request(:describe_broker_instance_options, params)
  req.send_request(options)
end

#describe_configuration(params = {}) ⇒ Types::DescribeConfigurationResponse

Returns information about the specified configuration.

Examples:

Request syntax with placeholder values


resp = client.describe_configuration({
  configuration_id: "__string", # required
})

Response structure


resp.arn #=> String
resp.authentication_strategy #=> String, one of "SIMPLE", "LDAP"
resp.created #=> Time
resp.description #=> String
resp.engine_type #=> String, one of "ACTIVEMQ", "RABBITMQ"
resp.engine_version #=> String
resp.id #=> String
resp.latest_revision.created #=> Time
resp.latest_revision.description #=> String
resp.latest_revision.revision #=> Integer
resp.name #=> String
resp.tags #=> Hash
resp.tags["__string"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :configuration_id (required, String)

Returns:

See Also:



1113
1114
1115
1116
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1113

def describe_configuration(params = {}, options = {})
  req = build_request(:describe_configuration, params)
  req.send_request(options)
end

#describe_configuration_revision(params = {}) ⇒ Types::DescribeConfigurationRevisionResponse

Returns the specified configuration revision for the specified configuration.

Examples:

Request syntax with placeholder values


resp = client.describe_configuration_revision({
  configuration_id: "__string", # required
  configuration_revision: "__string", # required
})

Response structure


resp.configuration_id #=> String
resp.created #=> Time
resp.data #=> String
resp.description #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :configuration_id (required, String)
  • :configuration_revision (required, String)

Returns:

See Also:



1150
1151
1152
1153
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1150

def describe_configuration_revision(params = {}, options = {})
  req = build_request(:describe_configuration_revision, params)
  req.send_request(options)
end

#describe_user(params = {}) ⇒ Types::DescribeUserResponse

Returns information about an ActiveMQ user.

Examples:

Request syntax with placeholder values


resp = client.describe_user({
  broker_id: "__string", # required
  username: "__string", # required
})

Response structure


resp.broker_id #=> String
resp.console_access #=> Boolean
resp.groups #=> Array
resp.groups[0] #=> String
resp.pending.console_access #=> Boolean
resp.pending.groups #=> Array
resp.pending.groups[0] #=> String
resp.pending.pending_change #=> String, one of "CREATE", "UPDATE", "DELETE"
resp.username #=> String
resp.replication_user #=> Boolean

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :broker_id (required, String)
  • :username (required, String)

Returns:

See Also:



1194
1195
1196
1197
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1194

def describe_user(params = {}, options = {})
  req = build_request(:describe_user, params)
  req.send_request(options)
end

#list_brokers(params = {}) ⇒ Types::ListBrokersResponse

Returns a list of all brokers.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_brokers({
  max_results: 1,
  next_token: "__string",
})

Response structure


resp.broker_summaries #=> Array
resp.broker_summaries[0].broker_arn #=> String
resp.broker_summaries[0].broker_id #=> String
resp.broker_summaries[0].broker_name #=> String
resp.broker_summaries[0].broker_state #=> String, one of "CREATION_IN_PROGRESS", "CREATION_FAILED", "DELETION_IN_PROGRESS", "RUNNING", "REBOOT_IN_PROGRESS", "CRITICAL_ACTION_REQUIRED", "REPLICA"
resp.broker_summaries[0].created #=> Time
resp.broker_summaries[0].deployment_mode #=> String, one of "SINGLE_INSTANCE", "ACTIVE_STANDBY_MULTI_AZ", "CLUSTER_MULTI_AZ"
resp.broker_summaries[0].engine_type #=> String, one of "ACTIVEMQ", "RABBITMQ"
resp.broker_summaries[0].host_instance_type #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :max_results (Integer)
  • :next_token (String)

Returns:

See Also:



1236
1237
1238
1239
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1236

def list_brokers(params = {}, options = {})
  req = build_request(:list_brokers, params)
  req.send_request(options)
end

#list_configuration_revisions(params = {}) ⇒ Types::ListConfigurationRevisionsResponse

Returns a list of all revisions for the specified configuration.

Examples:

Request syntax with placeholder values


resp = client.list_configuration_revisions({
  configuration_id: "__string", # required
  max_results: 1,
  next_token: "__string",
})

Response structure


resp.configuration_id #=> String
resp.max_results #=> Integer
resp.next_token #=> String
resp.revisions #=> Array
resp.revisions[0].created #=> Time
resp.revisions[0].description #=> String
resp.revisions[0].revision #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :configuration_id (required, String)
  • :max_results (Integer)
  • :next_token (String)

Returns:

See Also:



1278
1279
1280
1281
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1278

def list_configuration_revisions(params = {}, options = {})
  req = build_request(:list_configuration_revisions, params)
  req.send_request(options)
end

#list_configurations(params = {}) ⇒ Types::ListConfigurationsResponse

Returns a list of all configurations.

Examples:

Request syntax with placeholder values


resp = client.list_configurations({
  max_results: 1,
  next_token: "__string",
})

Response structure


resp.configurations #=> Array
resp.configurations[0].arn #=> String
resp.configurations[0].authentication_strategy #=> String, one of "SIMPLE", "LDAP"
resp.configurations[0].created #=> Time
resp.configurations[0].description #=> String
resp.configurations[0].engine_type #=> String, one of "ACTIVEMQ", "RABBITMQ"
resp.configurations[0].engine_version #=> String
resp.configurations[0].id #=> String
resp.configurations[0].latest_revision.created #=> Time
resp.configurations[0].latest_revision.description #=> String
resp.configurations[0].latest_revision.revision #=> Integer
resp.configurations[0].name #=> String
resp.configurations[0].tags #=> Hash
resp.configurations[0].tags["__string"] #=> String
resp.max_results #=> Integer
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :max_results (Integer)
  • :next_token (String)

Returns:

See Also:



1325
1326
1327
1328
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1325

def list_configurations(params = {}, options = {})
  req = build_request(:list_configurations, params)
  req.send_request(options)
end

#list_tags(params = {}) ⇒ Types::ListTagsResponse

Lists tags for a resource.

Examples:

Request syntax with placeholder values


resp = client.list_tags({
  resource_arn: "__string", # required
})

Response structure


resp.tags #=> Hash
resp.tags["__string"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :resource_arn (required, String)

Returns:

See Also:



1353
1354
1355
1356
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1353

def list_tags(params = {}, options = {})
  req = build_request(:list_tags, params)
  req.send_request(options)
end

#list_users(params = {}) ⇒ Types::ListUsersResponse

Returns a list of all ActiveMQ users.

Examples:

Request syntax with placeholder values


resp = client.list_users({
  broker_id: "__string", # required
  max_results: 1,
  next_token: "__string",
})

Response structure


resp.broker_id #=> String
resp.max_results #=> Integer
resp.next_token #=> String
resp.users #=> Array
resp.users[0].pending_change #=> String, one of "CREATE", "UPDATE", "DELETE"
resp.users[0].username #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :broker_id (required, String)
  • :max_results (Integer)
  • :next_token (String)

Returns:

See Also:



1394
1395
1396
1397
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1394

def list_users(params = {}, options = {})
  req = build_request(:list_users, params)
  req.send_request(options)
end

#promote(params = {}) ⇒ Types::PromoteResponse

Promotes a data replication replica broker to the primary broker role.

Examples:

Request syntax with placeholder values


resp = client.promote({
  broker_id: "__string", # required
  mode: "SWITCHOVER", # required, accepts SWITCHOVER, FAILOVER
})

Response structure


resp.broker_id #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :broker_id (required, String)
  • :mode (required, String)

    The Promote mode requested.

Returns:

See Also:



1425
1426
1427
1428
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1425

def promote(params = {}, options = {})
  req = build_request(:promote, params)
  req.send_request(options)
end

#reboot_broker(params = {}) ⇒ Struct

Reboots a broker. Note: This API is asynchronous.

Examples:

Request syntax with placeholder values


resp = client.reboot_broker({
  broker_id: "__string", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :broker_id (required, String)

Returns:

  • (Struct)

    Returns an empty response.

See Also:



1446
1447
1448
1449
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1446

def reboot_broker(params = {}, options = {})
  req = build_request(:reboot_broker, params)
  req.send_request(options)
end

#update_broker(params = {}) ⇒ Types::UpdateBrokerResponse

Adds a pending configuration change to a broker.

Examples:

Request syntax with placeholder values


resp = client.update_broker({
  authentication_strategy: "SIMPLE", # accepts SIMPLE, LDAP
  auto_minor_version_upgrade: false,
  broker_id: "__string", # required
  configuration: {
    id: "__string", # required
    revision: 1,
  },
  engine_version: "__string",
  host_instance_type: "__string",
  ldap_server_metadata: {
    hosts: ["__string"], # required
    role_base: "__string", # required
    role_name: "__string",
    role_search_matching: "__string", # required
    role_search_subtree: false,
    service_account_password: "__string", # required
    service_account_username: "__string", # required
    user_base: "__string", # required
    user_role_name: "__string",
    user_search_matching: "__string", # required
    user_search_subtree: false,
  },
  logs: {
    audit: false,
    general: false,
  },
  maintenance_window_start_time: {
    day_of_week: "MONDAY", # required, accepts MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, SUNDAY
    time_of_day: "__string", # required
    time_zone: "__string",
  },
  security_groups: ["__string"],
  data_replication_mode: "NONE", # accepts NONE, CRDR
})

Response structure


resp.authentication_strategy #=> String, one of "SIMPLE", "LDAP"
resp.auto_minor_version_upgrade #=> Boolean
resp.broker_id #=> String
resp.configuration.id #=> String
resp.configuration.revision #=> Integer
resp.engine_version #=> String
resp.host_instance_type #=> String
resp..hosts #=> Array
resp..hosts[0] #=> String
resp..role_base #=> String
resp..role_name #=> String
resp..role_search_matching #=> String
resp..role_search_subtree #=> Boolean
resp.. #=> String
resp..user_base #=> String
resp..user_role_name #=> String
resp..user_search_matching #=> String
resp..user_search_subtree #=> Boolean
resp.logs.audit #=> Boolean
resp.logs.general #=> Boolean
resp.maintenance_window_start_time.day_of_week #=> String, one of "MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY", "SATURDAY", "SUNDAY"
resp.maintenance_window_start_time.time_of_day #=> String
resp.maintenance_window_start_time.time_zone #=> String
resp.security_groups #=> Array
resp.security_groups[0] #=> String
resp..data_replication_counterpart.broker_id #=> String
resp..data_replication_counterpart.region #=> String
resp..data_replication_role #=> String
resp.data_replication_mode #=> String, one of "NONE", "CRDR"
resp..data_replication_counterpart.broker_id #=> String
resp..data_replication_counterpart.region #=> String
resp..data_replication_role #=> String
resp.pending_data_replication_mode #=> String, one of "NONE", "CRDR"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :authentication_strategy (String)

    Optional. The authentication strategy used to secure the broker. The default is SIMPLE.

  • :auto_minor_version_upgrade (Boolean)
  • :broker_id (required, String)
  • :configuration (Types::ConfigurationId)

    A list of information about the configuration.

  • :engine_version (String)
  • :host_instance_type (String)
  • :ldap_server_metadata (Types::LdapServerMetadataInput)

    Optional. The metadata of the LDAP server used to authenticate and authorize connections to the broker.

    Does not apply to RabbitMQ brokers.

  • :logs (Types::Logs)

    The list of information about logs to be enabled for the specified broker.

  • :maintenance_window_start_time (Types::WeeklyStartTime)

    The scheduled time period relative to UTC during which Amazon MQ begins to apply pending updates or patches to the broker.

  • :security_groups (Array<String>)
  • :data_replication_mode (String)

    Specifies whether a broker is a part of a data replication pair.

Returns:

See Also:



1582
1583
1584
1585
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1582

def update_broker(params = {}, options = {})
  req = build_request(:update_broker, params)
  req.send_request(options)
end

#update_configuration(params = {}) ⇒ Types::UpdateConfigurationResponse

Updates the specified configuration.

Examples:

Request syntax with placeholder values


resp = client.update_configuration({
  configuration_id: "__string", # required
  data: "__string", # required
  description: "__string",
})

Response structure


resp.arn #=> String
resp.created #=> Time
resp.id #=> String
resp.latest_revision.created #=> Time
resp.latest_revision.description #=> String
resp.latest_revision.revision #=> Integer
resp.name #=> String
resp.warnings #=> Array
resp.warnings[0].attribute_name #=> String
resp.warnings[0].element_name #=> String
resp.warnings[0].reason #=> String, one of "DISALLOWED_ELEMENT_REMOVED", "DISALLOWED_ATTRIBUTE_REMOVED", "INVALID_ATTRIBUTE_VALUE_REMOVED"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :configuration_id (required, String)
  • :data (required, String)
  • :description (String)

Returns:

See Also:



1630
1631
1632
1633
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1630

def update_configuration(params = {}, options = {})
  req = build_request(:update_configuration, params)
  req.send_request(options)
end

#update_user(params = {}) ⇒ Struct

Updates the information for an ActiveMQ user.

Examples:

Request syntax with placeholder values


resp = client.update_user({
  broker_id: "__string", # required
  console_access: false,
  groups: ["__string"],
  password: "__string",
  username: "__string", # required
  replication_user: false,
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :broker_id (required, String)
  • :console_access (Boolean)
  • :groups (Array<String>)
  • :password (String)
  • :username (required, String)
  • :replication_user (Boolean)

Returns:

  • (Struct)

    Returns an empty response.

See Also:



1666
1667
1668
1669
# File 'gems/aws-sdk-mq/lib/aws-sdk-mq/client.rb', line 1666

def update_user(params = {}, options = {})
  req = build_request(:update_user, params)
  req.send_request(options)
end