Class: Aws::LakeFormation::Client

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

Overview

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

client = Aws::LakeFormation::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):

  • :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, and :session_token options.
    • ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY']
    • ~/.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::InstanceProfileCredentails 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)
  • :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.

  • :disable_host_prefix_injection (Boolean) — default: false

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

  • :endpoint (String)

    The client endpoint is normally constructed from the :region option. You should only configure an :endpoint when connecting to test or custom endpoints. This should be a valid HTTP(S) URI.

  • :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.

  • :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.

  • :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.

  • :secret_access_key (String)
  • :session_token (String)
  • :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.

  • :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.

  • :http_proxy (URI::HTTP, String)

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

  • :http_open_timeout (Float) — default: 15

    The number of seconds to wait when opening a HTTP session before raising a Timeout::Error.

  • :http_read_timeout (Integer) — default: 60

    The default number of seconds to wait for response data. 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_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_wire_trace (Boolean) — default: false

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

  • :ssl_verify_peer (Boolean) — default: true

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

  • :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.



335
336
337
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 335

def initialize(*args)
  super
end

Instance Method Details

#add_lf_tags_to_resource(params = {}) ⇒ Types::AddLFTagsToResourceResponse

Attaches one or more LF-tags to an existing resource.

Examples:

Request syntax with placeholder values


resp = client.add_lf_tags_to_resource({
  catalog_id: "CatalogIdString",
  resource: { # required
    catalog: {
    },
    database: {
      catalog_id: "CatalogIdString",
      name: "NameString", # required
    },
    table: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString",
      table_wildcard: {
      },
    },
    table_with_columns: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString", # required
      column_names: ["NameString"],
      column_wildcard: {
        excluded_column_names: ["NameString"],
      },
    },
    data_location: {
      catalog_id: "CatalogIdString",
      resource_arn: "ResourceArnString", # required
    },
    data_cells_filter: {
      table_catalog_id: "CatalogIdString",
      database_name: "NameString",
      table_name: "NameString",
      name: "NameString",
    },
    lf_tag: {
      catalog_id: "CatalogIdString",
      tag_key: "NameString", # required
      tag_values: ["LFTagValue"], # required
    },
    lf_tag_policy: {
      catalog_id: "CatalogIdString",
      resource_type: "DATABASE", # required, accepts DATABASE, TABLE
      expression: [ # required
        {
          tag_key: "LFTagKey", # required
          tag_values: ["LFTagValue"], # required
        },
      ],
    },
  },
  lf_tags: [ # required
    {
      catalog_id: "CatalogIdString",
      tag_key: "LFTagKey", # required
      tag_values: ["LFTagValue"], # required
    },
  ],
})

Response structure


resp.failures #=> Array
resp.failures[0].lf_tag.catalog_id #=> String
resp.failures[0].lf_tag.tag_key #=> String
resp.failures[0].lf_tag.tag_values #=> Array
resp.failures[0].lf_tag.tag_values[0] #=> String
resp.failures[0].error.error_code #=> String
resp.failures[0].error.error_message #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :resource (required, Types::Resource)

    The database, table, or column resource to which to attach an LF-tag.

  • :lf_tags (required, Array<Types::LFTagPair>)

    The LF-tags to attach to the resource.

Returns:

See Also:



435
436
437
438
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 435

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

#batch_grant_permissions(params = {}) ⇒ Types::BatchGrantPermissionsResponse

Batch operation to grant permissions to the principal.

Examples:

Request syntax with placeholder values


resp = client.batch_grant_permissions({
  catalog_id: "CatalogIdString",
  entries: [ # required
    {
      id: "Identifier", # required
      principal: {
        data_lake_principal_identifier: "DataLakePrincipalString",
      },
      resource: {
        catalog: {
        },
        database: {
          catalog_id: "CatalogIdString",
          name: "NameString", # required
        },
        table: {
          catalog_id: "CatalogIdString",
          database_name: "NameString", # required
          name: "NameString",
          table_wildcard: {
          },
        },
        table_with_columns: {
          catalog_id: "CatalogIdString",
          database_name: "NameString", # required
          name: "NameString", # required
          column_names: ["NameString"],
          column_wildcard: {
            excluded_column_names: ["NameString"],
          },
        },
        data_location: {
          catalog_id: "CatalogIdString",
          resource_arn: "ResourceArnString", # required
        },
        data_cells_filter: {
          table_catalog_id: "CatalogIdString",
          database_name: "NameString",
          table_name: "NameString",
          name: "NameString",
        },
        lf_tag: {
          catalog_id: "CatalogIdString",
          tag_key: "NameString", # required
          tag_values: ["LFTagValue"], # required
        },
        lf_tag_policy: {
          catalog_id: "CatalogIdString",
          resource_type: "DATABASE", # required, accepts DATABASE, TABLE
          expression: [ # required
            {
              tag_key: "LFTagKey", # required
              tag_values: ["LFTagValue"], # required
            },
          ],
        },
      },
      permissions: ["ALL"], # accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
      permissions_with_grant_option: ["ALL"], # accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
    },
  ],
})

Response structure


resp.failures #=> Array
resp.failures[0].request_entry.id #=> String
resp.failures[0].request_entry.principal.data_lake_principal_identifier #=> String
resp.failures[0].request_entry.resource.database.catalog_id #=> String
resp.failures[0].request_entry.resource.database.name #=> String
resp.failures[0].request_entry.resource.table.catalog_id #=> String
resp.failures[0].request_entry.resource.table.database_name #=> String
resp.failures[0].request_entry.resource.table.name #=> String
resp.failures[0].request_entry.resource.table_with_columns.catalog_id #=> String
resp.failures[0].request_entry.resource.table_with_columns.database_name #=> String
resp.failures[0].request_entry.resource.table_with_columns.name #=> String
resp.failures[0].request_entry.resource.table_with_columns.column_names #=> Array
resp.failures[0].request_entry.resource.table_with_columns.column_names[0] #=> String
resp.failures[0].request_entry.resource.table_with_columns.column_wildcard.excluded_column_names #=> Array
resp.failures[0].request_entry.resource.table_with_columns.column_wildcard.excluded_column_names[0] #=> String
resp.failures[0].request_entry.resource.data_location.catalog_id #=> String
resp.failures[0].request_entry.resource.data_location.resource_arn #=> String
resp.failures[0].request_entry.resource.data_cells_filter.table_catalog_id #=> String
resp.failures[0].request_entry.resource.data_cells_filter.database_name #=> String
resp.failures[0].request_entry.resource.data_cells_filter.table_name #=> String
resp.failures[0].request_entry.resource.data_cells_filter.name #=> String
resp.failures[0].request_entry.resource.lf_tag.catalog_id #=> String
resp.failures[0].request_entry.resource.lf_tag.tag_key #=> String
resp.failures[0].request_entry.resource.lf_tag.tag_values #=> Array
resp.failures[0].request_entry.resource.lf_tag.tag_values[0] #=> String
resp.failures[0].request_entry.resource.lf_tag_policy.catalog_id #=> String
resp.failures[0].request_entry.resource.lf_tag_policy.resource_type #=> String, one of "DATABASE", "TABLE"
resp.failures[0].request_entry.resource.lf_tag_policy.expression #=> Array
resp.failures[0].request_entry.resource.lf_tag_policy.expression[0].tag_key #=> String
resp.failures[0].request_entry.resource.lf_tag_policy.expression[0].tag_values #=> Array
resp.failures[0].request_entry.resource.lf_tag_policy.expression[0].tag_values[0] #=> String
resp.failures[0].request_entry.permissions #=> Array
resp.failures[0].request_entry.permissions[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.failures[0].request_entry.permissions_with_grant_option #=> Array
resp.failures[0].request_entry.permissions_with_grant_option[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.failures[0].error.error_code #=> String
resp.failures[0].error.error_message #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :entries (required, Array<Types::BatchPermissionsRequestEntry>)

    A list of up to 20 entries for resource permissions to be granted by batch operation to the principal.

Returns:

See Also:



565
566
567
568
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 565

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

#batch_revoke_permissions(params = {}) ⇒ Types::BatchRevokePermissionsResponse

Batch operation to revoke permissions from the principal.

Examples:

Request syntax with placeholder values


resp = client.batch_revoke_permissions({
  catalog_id: "CatalogIdString",
  entries: [ # required
    {
      id: "Identifier", # required
      principal: {
        data_lake_principal_identifier: "DataLakePrincipalString",
      },
      resource: {
        catalog: {
        },
        database: {
          catalog_id: "CatalogIdString",
          name: "NameString", # required
        },
        table: {
          catalog_id: "CatalogIdString",
          database_name: "NameString", # required
          name: "NameString",
          table_wildcard: {
          },
        },
        table_with_columns: {
          catalog_id: "CatalogIdString",
          database_name: "NameString", # required
          name: "NameString", # required
          column_names: ["NameString"],
          column_wildcard: {
            excluded_column_names: ["NameString"],
          },
        },
        data_location: {
          catalog_id: "CatalogIdString",
          resource_arn: "ResourceArnString", # required
        },
        data_cells_filter: {
          table_catalog_id: "CatalogIdString",
          database_name: "NameString",
          table_name: "NameString",
          name: "NameString",
        },
        lf_tag: {
          catalog_id: "CatalogIdString",
          tag_key: "NameString", # required
          tag_values: ["LFTagValue"], # required
        },
        lf_tag_policy: {
          catalog_id: "CatalogIdString",
          resource_type: "DATABASE", # required, accepts DATABASE, TABLE
          expression: [ # required
            {
              tag_key: "LFTagKey", # required
              tag_values: ["LFTagValue"], # required
            },
          ],
        },
      },
      permissions: ["ALL"], # accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
      permissions_with_grant_option: ["ALL"], # accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
    },
  ],
})

Response structure


resp.failures #=> Array
resp.failures[0].request_entry.id #=> String
resp.failures[0].request_entry.principal.data_lake_principal_identifier #=> String
resp.failures[0].request_entry.resource.database.catalog_id #=> String
resp.failures[0].request_entry.resource.database.name #=> String
resp.failures[0].request_entry.resource.table.catalog_id #=> String
resp.failures[0].request_entry.resource.table.database_name #=> String
resp.failures[0].request_entry.resource.table.name #=> String
resp.failures[0].request_entry.resource.table_with_columns.catalog_id #=> String
resp.failures[0].request_entry.resource.table_with_columns.database_name #=> String
resp.failures[0].request_entry.resource.table_with_columns.name #=> String
resp.failures[0].request_entry.resource.table_with_columns.column_names #=> Array
resp.failures[0].request_entry.resource.table_with_columns.column_names[0] #=> String
resp.failures[0].request_entry.resource.table_with_columns.column_wildcard.excluded_column_names #=> Array
resp.failures[0].request_entry.resource.table_with_columns.column_wildcard.excluded_column_names[0] #=> String
resp.failures[0].request_entry.resource.data_location.catalog_id #=> String
resp.failures[0].request_entry.resource.data_location.resource_arn #=> String
resp.failures[0].request_entry.resource.data_cells_filter.table_catalog_id #=> String
resp.failures[0].request_entry.resource.data_cells_filter.database_name #=> String
resp.failures[0].request_entry.resource.data_cells_filter.table_name #=> String
resp.failures[0].request_entry.resource.data_cells_filter.name #=> String
resp.failures[0].request_entry.resource.lf_tag.catalog_id #=> String
resp.failures[0].request_entry.resource.lf_tag.tag_key #=> String
resp.failures[0].request_entry.resource.lf_tag.tag_values #=> Array
resp.failures[0].request_entry.resource.lf_tag.tag_values[0] #=> String
resp.failures[0].request_entry.resource.lf_tag_policy.catalog_id #=> String
resp.failures[0].request_entry.resource.lf_tag_policy.resource_type #=> String, one of "DATABASE", "TABLE"
resp.failures[0].request_entry.resource.lf_tag_policy.expression #=> Array
resp.failures[0].request_entry.resource.lf_tag_policy.expression[0].tag_key #=> String
resp.failures[0].request_entry.resource.lf_tag_policy.expression[0].tag_values #=> Array
resp.failures[0].request_entry.resource.lf_tag_policy.expression[0].tag_values[0] #=> String
resp.failures[0].request_entry.permissions #=> Array
resp.failures[0].request_entry.permissions[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.failures[0].request_entry.permissions_with_grant_option #=> Array
resp.failures[0].request_entry.permissions_with_grant_option[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.failures[0].error.error_code #=> String
resp.failures[0].error.error_message #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :entries (required, Array<Types::BatchPermissionsRequestEntry>)

    A list of up to 20 entries for resource permissions to be revoked by batch operation to the principal.

Returns:

See Also:



695
696
697
698
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 695

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

#cancel_transaction(params = {}) ⇒ Struct

Attempts to cancel the specified transaction. Returns an exception if the transaction was previously committed.

Examples:

Request syntax with placeholder values


resp = client.cancel_transaction({
  transaction_id: "TransactionIdString", # required
})

Parameters:

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

    ({})

Options Hash (params):

  • :transaction_id (required, String)

    The transaction to cancel.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



718
719
720
721
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 718

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

#commit_transaction(params = {}) ⇒ Types::CommitTransactionResponse

Attempts to commit the specified transaction. Returns an exception if the transaction was previously aborted. This API action is idempotent if called multiple times for the same transaction.

Examples:

Request syntax with placeholder values


resp = client.commit_transaction({
  transaction_id: "TransactionIdString", # required
})

Response structure


resp.transaction_status #=> String, one of "ACTIVE", "COMMITTED", "ABORTED", "COMMIT_IN_PROGRESS"

Parameters:

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

    ({})

Options Hash (params):

  • :transaction_id (required, String)

    The transaction to commit.

Returns:

See Also:



748
749
750
751
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 748

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

#create_data_cells_filter(params = {}) ⇒ Struct

Creates a data cell filter to allow one to grant access to certain columns on certain rows.

Examples:

Request syntax with placeholder values


resp = client.create_data_cells_filter({
  table_data: { # required
    table_catalog_id: "CatalogIdString", # required
    database_name: "NameString", # required
    table_name: "NameString", # required
    name: "NameString", # required
    row_filter: {
      filter_expression: "PredicateString",
      all_rows_wildcard: {
      },
    },
    column_names: ["NameString"],
    column_wildcard: {
      excluded_column_names: ["NameString"],
    },
  },
})

Parameters:

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

    ({})

Options Hash (params):

  • :table_data (required, Types::DataCellsFilter)

    A DataCellsFilter structure containing information about the data cells filter.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



786
787
788
789
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 786

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

#create_lf_tag(params = {}) ⇒ Struct

Creates an LF-tag with the specified name and values.

Examples:

Request syntax with placeholder values


resp = client.create_lf_tag({
  catalog_id: "CatalogIdString",
  tag_key: "LFTagKey", # required
  tag_values: ["LFTagValue"], # required
})

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :tag_key (required, String)

    The key-name for the LF-tag.

  • :tag_values (required, Array<String>)

    A list of possible values an attribute can take.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



819
820
821
822
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 819

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

#delete_data_cells_filter(params = {}) ⇒ Struct

Deletes a data cell filter.

Examples:

Request syntax with placeholder values


resp = client.delete_data_cells_filter({
  table_catalog_id: "CatalogIdString",
  database_name: "NameString",
  table_name: "NameString",
  name: "NameString",
})

Parameters:

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

    ({})

Options Hash (params):

  • :table_catalog_id (String)

    The ID of the catalog to which the table belongs.

  • :database_name (String)

    A database in the Glue Data Catalog.

  • :table_name (String)

    A table in the database.

  • :name (String)

    The name given by the user to the data filter cell.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



853
854
855
856
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 853

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

#delete_lf_tag(params = {}) ⇒ Struct

Deletes the specified LF-tag key name. If the attribute key does not exist or the LF-tag does not exist, then the operation will not do anything. If the attribute key exists, then the operation checks if any resources are tagged with this attribute key, if yes, the API throws a 400 Exception with the message "Delete not allowed" as the LF-tag key is still attached with resources. You can consider untagging resources with this LF-tag key.

Examples:

Request syntax with placeholder values


resp = client.delete_lf_tag({
  catalog_id: "CatalogIdString",
  tag_key: "LFTagKey", # required
})

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :tag_key (required, String)

    The key-name for the LF-tag to delete.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



888
889
890
891
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 888

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

#delete_objects_on_cancel(params = {}) ⇒ Struct

For a specific governed table, provides a list of Amazon S3 objects that will be written during the current transaction and that can be automatically deleted if the transaction is canceled. Without this call, no Amazon S3 objects are automatically deleted when a transaction cancels.

The Glue ETL library function write_dynamic_frame.from_catalog() includes an option to automatically call DeleteObjectsOnCancel before writes. For more information, see Rolling Back Amazon S3 Writes.

Examples:

Request syntax with placeholder values


resp = client.delete_objects_on_cancel({
  catalog_id: "CatalogIdString",
  database_name: "NameString", # required
  table_name: "NameString", # required
  transaction_id: "TransactionIdString", # required
  objects: [ # required
    {
      uri: "URI", # required
      etag: "ETagString",
    },
  ],
})

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The Glue data catalog that contains the governed table. Defaults to the current account ID.

  • :database_name (required, String)

    The database that contains the governed table.

  • :table_name (required, String)

    The name of the governed table.

  • :transaction_id (required, String)

    ID of the transaction that the writes occur in.

  • :objects (required, Array<Types::VirtualObject>)

    A list of VirtualObject structures, which indicates the Amazon S3 objects to be deleted if the transaction cancels.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



946
947
948
949
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 946

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

#deregister_resource(params = {}) ⇒ Struct

Deregisters the resource as managed by the Data Catalog.

When you deregister a path, Lake Formation removes the path from the inline policy attached to your service-linked role.

Examples:

Request syntax with placeholder values


resp = client.deregister_resource({
  resource_arn: "ResourceArnString", # required
})

Parameters:

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

    ({})

Options Hash (params):

  • :resource_arn (required, String)

    The Amazon Resource Name (ARN) of the resource that you want to deregister.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



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

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

#describe_resource(params = {}) ⇒ Types::DescribeResourceResponse

Retrieves the current data access role for the given resource registered in Lake Formation.

Examples:

Request syntax with placeholder values


resp = client.describe_resource({
  resource_arn: "ResourceArnString", # required
})

Response structure


resp.resource_info.resource_arn #=> String
resp.resource_info.role_arn #=> String
resp.resource_info.last_modified #=> Time

Parameters:

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

    ({})

Options Hash (params):

  • :resource_arn (required, String)

    The resource ARN.

Returns:

See Also:



1003
1004
1005
1006
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1003

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

#describe_transaction(params = {}) ⇒ Types::DescribeTransactionResponse

Returns the details of a single transaction.

Examples:

Request syntax with placeholder values


resp = client.describe_transaction({
  transaction_id: "TransactionIdString", # required
})

Response structure


resp.transaction_description.transaction_id #=> String
resp.transaction_description.transaction_status #=> String, one of "ACTIVE", "COMMITTED", "ABORTED", "COMMIT_IN_PROGRESS"
resp.transaction_description.transaction_start_time #=> Time
resp.transaction_description.transaction_end_time #=> Time

Parameters:

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

    ({})

Options Hash (params):

  • :transaction_id (required, String)

    The transaction for which to return status.

Returns:

See Also:



1034
1035
1036
1037
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1034

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

#extend_transaction(params = {}) ⇒ Struct

Indicates to the service that the specified transaction is still active and should not be treated as idle and aborted.

Write transactions that remain idle for a long period are automatically aborted unless explicitly extended.

Examples:

Request syntax with placeholder values


resp = client.extend_transaction({
  transaction_id: "TransactionIdString",
})

Parameters:

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

    ({})

Options Hash (params):

  • :transaction_id (String)

    The transaction to extend.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



1060
1061
1062
1063
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1060

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

#get_data_lake_settings(params = {}) ⇒ Types::GetDataLakeSettingsResponse

Retrieves the list of the data lake administrators of a Lake Formation-managed data lake.

Examples:

Request syntax with placeholder values


resp = client.get_data_lake_settings({
  catalog_id: "CatalogIdString",
})

Response structure


resp.data_lake_settings.data_lake_admins #=> Array
resp.data_lake_settings.data_lake_admins[0].data_lake_principal_identifier #=> String
resp.data_lake_settings.create_database_default_permissions #=> Array
resp.data_lake_settings.create_database_default_permissions[0].principal.data_lake_principal_identifier #=> String
resp.data_lake_settings.create_database_default_permissions[0].permissions #=> Array
resp.data_lake_settings.create_database_default_permissions[0].permissions[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.data_lake_settings.create_table_default_permissions #=> Array
resp.data_lake_settings.create_table_default_permissions[0].principal.data_lake_principal_identifier #=> String
resp.data_lake_settings.create_table_default_permissions[0].permissions #=> Array
resp.data_lake_settings.create_table_default_permissions[0].permissions[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.data_lake_settings.trusted_resource_owners #=> Array
resp.data_lake_settings.trusted_resource_owners[0] #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

Returns:

See Also:



1103
1104
1105
1106
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1103

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

#get_effective_permissions_for_path(params = {}) ⇒ Types::GetEffectivePermissionsForPathResponse

Returns the Lake Formation permissions for a specified table or database resource located at a path in Amazon S3. GetEffectivePermissionsForPath will not return databases and tables if the catalog is encrypted.

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

Examples:

Request syntax with placeholder values


resp = client.get_effective_permissions_for_path({
  catalog_id: "CatalogIdString",
  resource_arn: "ResourceArnString", # required
  next_token: "Token",
  max_results: 1,
})

Response structure


resp.permissions #=> Array
resp.permissions[0].principal.data_lake_principal_identifier #=> String
resp.permissions[0].resource.database.catalog_id #=> String
resp.permissions[0].resource.database.name #=> String
resp.permissions[0].resource.table.catalog_id #=> String
resp.permissions[0].resource.table.database_name #=> String
resp.permissions[0].resource.table.name #=> String
resp.permissions[0].resource.table_with_columns.catalog_id #=> String
resp.permissions[0].resource.table_with_columns.database_name #=> String
resp.permissions[0].resource.table_with_columns.name #=> String
resp.permissions[0].resource.table_with_columns.column_names #=> Array
resp.permissions[0].resource.table_with_columns.column_names[0] #=> String
resp.permissions[0].resource.table_with_columns.column_wildcard.excluded_column_names #=> Array
resp.permissions[0].resource.table_with_columns.column_wildcard.excluded_column_names[0] #=> String
resp.permissions[0].resource.data_location.catalog_id #=> String
resp.permissions[0].resource.data_location.resource_arn #=> String
resp.permissions[0].resource.data_cells_filter.table_catalog_id #=> String
resp.permissions[0].resource.data_cells_filter.database_name #=> String
resp.permissions[0].resource.data_cells_filter.table_name #=> String
resp.permissions[0].resource.data_cells_filter.name #=> String
resp.permissions[0].resource.lf_tag.catalog_id #=> String
resp.permissions[0].resource.lf_tag.tag_key #=> String
resp.permissions[0].resource.lf_tag.tag_values #=> Array
resp.permissions[0].resource.lf_tag.tag_values[0] #=> String
resp.permissions[0].resource.lf_tag_policy.catalog_id #=> String
resp.permissions[0].resource.lf_tag_policy.resource_type #=> String, one of "DATABASE", "TABLE"
resp.permissions[0].resource.lf_tag_policy.expression #=> Array
resp.permissions[0].resource.lf_tag_policy.expression[0].tag_key #=> String
resp.permissions[0].resource.lf_tag_policy.expression[0].tag_values #=> Array
resp.permissions[0].resource.lf_tag_policy.expression[0].tag_values[0] #=> String
resp.permissions[0].permissions #=> Array
resp.permissions[0].permissions[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.permissions[0].permissions_with_grant_option #=> Array
resp.permissions[0].permissions_with_grant_option[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.permissions[0].additional_details.resource_share #=> Array
resp.permissions[0].additional_details.resource_share[0] #=> String
resp.next_token #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :resource_arn (required, String)

    The Amazon Resource Name (ARN) of the resource for which you want to get permissions.

  • :next_token (String)

    A continuation token, if this is not the first call to retrieve this list.

  • :max_results (Integer)

    The maximum number of results to return.

Returns:

See Also:



1190
1191
1192
1193
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1190

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

#get_lf_tag(params = {}) ⇒ Types::GetLFTagResponse

Returns an LF-tag definition.

Examples:

Request syntax with placeholder values


resp = client.get_lf_tag({
  catalog_id: "CatalogIdString",
  tag_key: "LFTagKey", # required
})

Response structure


resp.catalog_id #=> String
resp.tag_key #=> String
resp.tag_values #=> Array
resp.tag_values[0] #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :tag_key (required, String)

    The key-name for the LF-tag.

Returns:

See Also:



1230
1231
1232
1233
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1230

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

#get_query_state(params = {}) ⇒ Types::GetQueryStateResponse

Returns the state of a query previously submitted. Clients are expected to poll GetQueryState to monitor the current state of the planning before retrieving the work units. A query state is only visible to the principal that made the initial call to StartQueryPlanning.

Examples:

Request syntax with placeholder values


resp = client.get_query_state({
  query_id: "GetQueryStateRequestQueryIdString", # required
})

Response structure


resp.error #=> String
resp.state #=> String, one of "PENDING", "WORKUNITS_AVAILABLE", "ERROR", "FINISHED", "EXPIRED"

Parameters:

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

    ({})

Options Hash (params):

  • :query_id (required, String)

    The ID of the plan query operation.

Returns:

See Also:



1264
1265
1266
1267
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1264

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

#get_query_statistics(params = {}) ⇒ Types::GetQueryStatisticsResponse

Retrieves statistics on the planning and execution of a query.

Examples:

Request syntax with placeholder values


resp = client.get_query_statistics({
  query_id: "GetQueryStatisticsRequestQueryIdString", # required
})

Response structure


resp.execution_statistics.average_execution_time_millis #=> Integer
resp.execution_statistics.data_scanned_bytes #=> Integer
resp.execution_statistics.work_units_executed_count #=> Integer
resp.planning_statistics.estimated_data_to_scan_bytes #=> Integer
resp.planning_statistics.planning_time_millis #=> Integer
resp.planning_statistics.queue_time_millis #=> Integer
resp.planning_statistics.work_units_generated_count #=> Integer
resp.query_submission_time #=> Time

Parameters:

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

    ({})

Options Hash (params):

  • :query_id (required, String)

    The ID of the plan query operation.

Returns:

See Also:



1301
1302
1303
1304
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1301

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

#get_resource_lf_tags(params = {}) ⇒ Types::GetResourceLFTagsResponse

Returns the LF-tags applied to a resource.

Examples:

Request syntax with placeholder values


resp = client.get_resource_lf_tags({
  catalog_id: "CatalogIdString",
  resource: { # required
    catalog: {
    },
    database: {
      catalog_id: "CatalogIdString",
      name: "NameString", # required
    },
    table: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString",
      table_wildcard: {
      },
    },
    table_with_columns: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString", # required
      column_names: ["NameString"],
      column_wildcard: {
        excluded_column_names: ["NameString"],
      },
    },
    data_location: {
      catalog_id: "CatalogIdString",
      resource_arn: "ResourceArnString", # required
    },
    data_cells_filter: {
      table_catalog_id: "CatalogIdString",
      database_name: "NameString",
      table_name: "NameString",
      name: "NameString",
    },
    lf_tag: {
      catalog_id: "CatalogIdString",
      tag_key: "NameString", # required
      tag_values: ["LFTagValue"], # required
    },
    lf_tag_policy: {
      catalog_id: "CatalogIdString",
      resource_type: "DATABASE", # required, accepts DATABASE, TABLE
      expression: [ # required
        {
          tag_key: "LFTagKey", # required
          tag_values: ["LFTagValue"], # required
        },
      ],
    },
  },
  show_assigned_lf_tags: false,
})

Response structure


resp.lf_tag_on_database #=> Array
resp.lf_tag_on_database[0].catalog_id #=> String
resp.lf_tag_on_database[0].tag_key #=> String
resp.lf_tag_on_database[0].tag_values #=> Array
resp.lf_tag_on_database[0].tag_values[0] #=> String
resp.lf_tags_on_table #=> Array
resp.lf_tags_on_table[0].catalog_id #=> String
resp.lf_tags_on_table[0].tag_key #=> String
resp.lf_tags_on_table[0].tag_values #=> Array
resp.lf_tags_on_table[0].tag_values[0] #=> String
resp.lf_tags_on_columns #=> Array
resp.lf_tags_on_columns[0].name #=> String
resp.lf_tags_on_columns[0].lf_tags #=> Array
resp.lf_tags_on_columns[0].lf_tags[0].catalog_id #=> String
resp.lf_tags_on_columns[0].lf_tags[0].tag_key #=> String
resp.lf_tags_on_columns[0].lf_tags[0].tag_values #=> Array
resp.lf_tags_on_columns[0].lf_tags[0].tag_values[0] #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :resource (required, Types::Resource)

    The database, table, or column resource for which you want to return LF-tags.

  • :show_assigned_lf_tags (Boolean)

    Indicates whether to show the assigned LF-tags.

Returns:

See Also:



1407
1408
1409
1410
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1407

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

#get_table_objects(params = {}) ⇒ Types::GetTableObjectsResponse

Returns the set of Amazon S3 objects that make up the specified governed table. A transaction ID or timestamp can be specified for time-travel queries.

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

Examples:

Request syntax with placeholder values


resp = client.get_table_objects({
  catalog_id: "CatalogIdString",
  database_name: "NameString", # required
  table_name: "NameString", # required
  transaction_id: "TransactionIdString",
  query_as_of_time: Time.now,
  partition_predicate: "PredicateString",
  max_results: 1,
  next_token: "TokenString",
})

Response structure


resp.objects #=> Array
resp.objects[0].partition_values #=> Array
resp.objects[0].partition_values[0] #=> String
resp.objects[0].objects #=> Array
resp.objects[0].objects[0].uri #=> String
resp.objects[0].objects[0].etag #=> String
resp.objects[0].objects[0].size #=> Integer
resp.next_token #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The catalog containing the governed table. Defaults to the caller’s account.

  • :database_name (required, String)

    The database containing the governed table.

  • :table_name (required, String)

    The governed table for which to retrieve objects.

  • :transaction_id (String)

    The transaction ID at which to read the governed table contents. If this transaction has aborted, an error is returned. If not set, defaults to the most recent committed transaction. Cannot be specified along with QueryAsOfTime.

  • :query_as_of_time (Time, DateTime, Date, Integer, String)

    The time as of when to read the governed table contents. If not set, the most recent transaction commit time is used. Cannot be specified along with TransactionId.

  • :partition_predicate (String)

    A predicate to filter the objects returned based on the partition keys defined in the governed table.

    • The comparison operators supported are: =, >, <, >=, <=

    • The logical operators supported are: AND

    • The data types supported are integer, long, date(yyyy-MM-dd), timestamp(yyyy-MM-dd HH:mm:ssXXX or yyyy-MM-dd HH:mm:ss"), string and decimal.

  • :max_results (Integer)

    Specifies how many values to return in a page.

  • :next_token (String)

    A continuation token if this is not the first call to retrieve these objects.

Returns:

See Also:



1491
1492
1493
1494
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1491

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

#get_work_unit_results(params = {}) ⇒ Types::GetWorkUnitResultsResponse

Returns the work units resulting from the query. Work units can be executed in any order and in parallel.

Examples:

Request syntax with placeholder values


resp = client.get_work_unit_results({
  query_id: "GetWorkUnitResultsRequestQueryIdString", # required
  work_unit_id: 1, # required
  work_unit_token: "SyntheticGetWorkUnitResultsRequestWorkUnitTokenString", # required
})

Response structure


resp.result_stream #=> IO

Parameters:

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

    ({})

Options Hash (params):

  • :query_id (required, String)

    The ID of the plan query operation for which to get results.

  • :work_unit_id (required, Integer)

    The work unit ID for which to get results. Value generated by enumerating WorkUnitIdMin to WorkUnitIdMax (inclusive) from the WorkUnitRange in the output of GetWorkUnits.

  • :work_unit_token (required, String)

    A work token used to query the execution service. Token output from GetWorkUnits.

Returns:

See Also:



1531
1532
1533
1534
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1531

def get_work_unit_results(params = {}, options = {}, &block)
  req = build_request(:get_work_unit_results, params)
  req.send_request(options, &block)
end

#get_work_units(params = {}) ⇒ Types::GetWorkUnitsResponse

Retrieves the work units generated by the StartQueryPlanning operation.

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

Examples:

Request syntax with placeholder values


resp = client.get_work_units({
  next_token: "Token",
  page_size: 1,
  query_id: "GetWorkUnitsRequestQueryIdString", # required
})

Response structure


resp.next_token #=> String
resp.query_id #=> String
resp.work_unit_ranges #=> Array
resp.work_unit_ranges[0].work_unit_id_max #=> Integer
resp.work_unit_ranges[0].work_unit_id_min #=> Integer
resp.work_unit_ranges[0].work_unit_token #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :next_token (String)

    A continuation token, if this is a continuation call.

  • :page_size (Integer)

    The size of each page to get in the Amazon Web Services service call. This does not affect the number of items returned in the command's output. Setting a smaller page size results in more calls to the Amazon Web Services service, retrieving fewer items in each call. This can help prevent the Amazon Web Services service calls from timing out.

  • :query_id (required, String)

    The ID of the plan query operation.

Returns:

See Also:



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

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

#grant_permissions(params = {}) ⇒ Struct

Grants permissions to the principal to access metadata in the Data Catalog and data organized in underlying data storage such as Amazon S3.

For information about permissions, see Security and Access Control to Metadata and Data.

Examples:

Request syntax with placeholder values


resp = client.grant_permissions({
  catalog_id: "CatalogIdString",
  principal: { # required
    data_lake_principal_identifier: "DataLakePrincipalString",
  },
  resource: { # required
    catalog: {
    },
    database: {
      catalog_id: "CatalogIdString",
      name: "NameString", # required
    },
    table: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString",
      table_wildcard: {
      },
    },
    table_with_columns: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString", # required
      column_names: ["NameString"],
      column_wildcard: {
        excluded_column_names: ["NameString"],
      },
    },
    data_location: {
      catalog_id: "CatalogIdString",
      resource_arn: "ResourceArnString", # required
    },
    data_cells_filter: {
      table_catalog_id: "CatalogIdString",
      database_name: "NameString",
      table_name: "NameString",
      name: "NameString",
    },
    lf_tag: {
      catalog_id: "CatalogIdString",
      tag_key: "NameString", # required
      tag_values: ["LFTagValue"], # required
    },
    lf_tag_policy: {
      catalog_id: "CatalogIdString",
      resource_type: "DATABASE", # required, accepts DATABASE, TABLE
      expression: [ # required
        {
          tag_key: "LFTagKey", # required
          tag_values: ["LFTagValue"], # required
        },
      ],
    },
  },
  permissions: ["ALL"], # required, accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
  permissions_with_grant_option: ["ALL"], # accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
})

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :principal (required, Types::DataLakePrincipal)

    The principal to be granted the permissions on the resource. Supported principals are IAM users or IAM roles, and they are defined by their principal type and their ARN.

    Note that if you define a resource with a particular ARN, then later delete, and recreate a resource with that same ARN, the resource maintains the permissions already granted.

  • :resource (required, Types::Resource)

    The resource to which permissions are to be granted. Resources in Lake Formation are the Data Catalog, databases, and tables.

  • :permissions (required, Array<String>)

    The permissions granted to the principal on the resource. Lake Formation defines privileges to grant and revoke access to metadata in the Data Catalog and data organized in underlying data storage such as Amazon S3. Lake Formation requires that each principal be authorized to perform a specific task on Lake Formation resources.

  • :permissions_with_grant_option (Array<String>)

    Indicates a list of the granted permissions that the principal may pass to other users. These permissions may only be a subset of the permissions granted in the Privileges.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



1695
1696
1697
1698
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1695

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

#list_data_cells_filter(params = {}) ⇒ Types::ListDataCellsFilterResponse

Lists all the data cell filters on a table.

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_data_cells_filter({
  table: {
    catalog_id: "CatalogIdString",
    database_name: "NameString", # required
    name: "NameString",
    table_wildcard: {
    },
  },
  next_token: "Token",
  max_results: 1,
})

Response structure


resp.data_cells_filters #=> Array
resp.data_cells_filters[0].table_catalog_id #=> String
resp.data_cells_filters[0].database_name #=> String
resp.data_cells_filters[0].table_name #=> String
resp.data_cells_filters[0].name #=> String
resp.data_cells_filters[0].row_filter.filter_expression #=> String
resp.data_cells_filters[0].column_names #=> Array
resp.data_cells_filters[0].column_names[0] #=> String
resp.data_cells_filters[0].column_wildcard.excluded_column_names #=> Array
resp.data_cells_filters[0].column_wildcard.excluded_column_names[0] #=> String
resp.next_token #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :table (Types::TableResource)

    A table in the Glue Data Catalog.

  • :next_token (String)

    A continuation token, if this is a continuation call.

  • :max_results (Integer)

    The maximum size of the response.

Returns:

See Also:



1750
1751
1752
1753
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1750

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

#list_lf_tags(params = {}) ⇒ Types::ListLFTagsResponse

Lists LF-tags that the requester has permission to view.

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_lf_tags({
  catalog_id: "CatalogIdString",
  resource_share_type: "FOREIGN", # accepts FOREIGN, ALL
  max_results: 1,
  next_token: "Token",
})

Response structure


resp.lf_tags #=> Array
resp.lf_tags[0].catalog_id #=> String
resp.lf_tags[0].tag_key #=> String
resp.lf_tags[0].tag_values #=> Array
resp.lf_tags[0].tag_values[0] #=> String
resp.next_token #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :resource_share_type (String)

    If resource share type is ALL, returns both in-account LF-tags and shared LF-tags that the requester has permission to view. If resource share type is FOREIGN, returns all share LF-tags that the requester can view. If no resource share type is passed, lists LF-tags in the given catalog ID that the requester has permission to view.

  • :max_results (Integer)

    The maximum number of results to return.

  • :next_token (String)

    A continuation token, if this is not the first call to retrieve this list.

Returns:

See Also:



1806
1807
1808
1809
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1806

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

#list_permissions(params = {}) ⇒ Types::ListPermissionsResponse

Returns a list of the principal permissions on the resource, filtered by the permissions of the caller. For example, if you are granted an ALTER permission, you are able to see only the principal permissions for ALTER.

This operation returns only those permissions that have been explicitly granted.

For information about permissions, see Security and Access Control to Metadata and Data.

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_permissions({
  catalog_id: "CatalogIdString",
  principal: {
    data_lake_principal_identifier: "DataLakePrincipalString",
  },
  resource_type: "CATALOG", # accepts CATALOG, DATABASE, TABLE, DATA_LOCATION, LF_TAG, LF_TAG_POLICY, LF_TAG_POLICY_DATABASE, LF_TAG_POLICY_TABLE
  resource: {
    catalog: {
    },
    database: {
      catalog_id: "CatalogIdString",
      name: "NameString", # required
    },
    table: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString",
      table_wildcard: {
      },
    },
    table_with_columns: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString", # required
      column_names: ["NameString"],
      column_wildcard: {
        excluded_column_names: ["NameString"],
      },
    },
    data_location: {
      catalog_id: "CatalogIdString",
      resource_arn: "ResourceArnString", # required
    },
    data_cells_filter: {
      table_catalog_id: "CatalogIdString",
      database_name: "NameString",
      table_name: "NameString",
      name: "NameString",
    },
    lf_tag: {
      catalog_id: "CatalogIdString",
      tag_key: "NameString", # required
      tag_values: ["LFTagValue"], # required
    },
    lf_tag_policy: {
      catalog_id: "CatalogIdString",
      resource_type: "DATABASE", # required, accepts DATABASE, TABLE
      expression: [ # required
        {
          tag_key: "LFTagKey", # required
          tag_values: ["LFTagValue"], # required
        },
      ],
    },
  },
  next_token: "Token",
  max_results: 1,
  include_related: "TrueFalseString",
})

Response structure


resp.principal_resource_permissions #=> Array
resp.principal_resource_permissions[0].principal.data_lake_principal_identifier #=> String
resp.principal_resource_permissions[0].resource.database.catalog_id #=> String
resp.principal_resource_permissions[0].resource.database.name #=> String
resp.principal_resource_permissions[0].resource.table.catalog_id #=> String
resp.principal_resource_permissions[0].resource.table.database_name #=> String
resp.principal_resource_permissions[0].resource.table.name #=> String
resp.principal_resource_permissions[0].resource.table_with_columns.catalog_id #=> String
resp.principal_resource_permissions[0].resource.table_with_columns.database_name #=> String
resp.principal_resource_permissions[0].resource.table_with_columns.name #=> String
resp.principal_resource_permissions[0].resource.table_with_columns.column_names #=> Array
resp.principal_resource_permissions[0].resource.table_with_columns.column_names[0] #=> String
resp.principal_resource_permissions[0].resource.table_with_columns.column_wildcard.excluded_column_names #=> Array
resp.principal_resource_permissions[0].resource.table_with_columns.column_wildcard.excluded_column_names[0] #=> String
resp.principal_resource_permissions[0].resource.data_location.catalog_id #=> String
resp.principal_resource_permissions[0].resource.data_location.resource_arn #=> String
resp.principal_resource_permissions[0].resource.data_cells_filter.table_catalog_id #=> String
resp.principal_resource_permissions[0].resource.data_cells_filter.database_name #=> String
resp.principal_resource_permissions[0].resource.data_cells_filter.table_name #=> String
resp.principal_resource_permissions[0].resource.data_cells_filter.name #=> String
resp.principal_resource_permissions[0].resource.lf_tag.catalog_id #=> String
resp.principal_resource_permissions[0].resource.lf_tag.tag_key #=> String
resp.principal_resource_permissions[0].resource.lf_tag.tag_values #=> Array
resp.principal_resource_permissions[0].resource.lf_tag.tag_values[0] #=> String
resp.principal_resource_permissions[0].resource.lf_tag_policy.catalog_id #=> String
resp.principal_resource_permissions[0].resource.lf_tag_policy.resource_type #=> String, one of "DATABASE", "TABLE"
resp.principal_resource_permissions[0].resource.lf_tag_policy.expression #=> Array
resp.principal_resource_permissions[0].resource.lf_tag_policy.expression[0].tag_key #=> String
resp.principal_resource_permissions[0].resource.lf_tag_policy.expression[0].tag_values #=> Array
resp.principal_resource_permissions[0].resource.lf_tag_policy.expression[0].tag_values[0] #=> String
resp.principal_resource_permissions[0].permissions #=> Array
resp.principal_resource_permissions[0].permissions[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.principal_resource_permissions[0].permissions_with_grant_option #=> Array
resp.principal_resource_permissions[0].permissions_with_grant_option[0] #=> String, one of "ALL", "SELECT", "ALTER", "DROP", "DELETE", "INSERT", "DESCRIBE", "CREATE_DATABASE", "CREATE_TABLE", "DATA_LOCATION_ACCESS", "CREATE_TAG", "ALTER_TAG", "DELETE_TAG", "DESCRIBE_TAG", "ASSOCIATE_TAG"
resp.principal_resource_permissions[0].additional_details.resource_share #=> Array
resp.principal_resource_permissions[0].additional_details.resource_share[0] #=> String
resp.next_token #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :principal (Types::DataLakePrincipal)

    Specifies a principal to filter the permissions returned.

  • :resource_type (String)

    Specifies a resource type to filter the permissions returned.

  • :resource (Types::Resource)

    A resource where you will get a list of the principal permissions.

    This operation does not support getting privileges on a table with columns. Instead, call this operation on the table, and the operation returns the table and the table w columns.

  • :next_token (String)

    A continuation token, if this is not the first call to retrieve this list.

  • :max_results (Integer)

    The maximum number of results to return.

  • :include_related (String)

    Indicates that related permissions should be included in the results.

Returns:

See Also:



1968
1969
1970
1971
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 1968

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

#list_resources(params = {}) ⇒ Types::ListResourcesResponse

Lists the resources registered to be managed by the Data Catalog.

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_resources({
  filter_condition_list: [
    {
      field: "RESOURCE_ARN", # accepts RESOURCE_ARN, ROLE_ARN, LAST_MODIFIED
      comparison_operator: "EQ", # accepts EQ, NE, LE, LT, GE, GT, CONTAINS, NOT_CONTAINS, BEGINS_WITH, IN, BETWEEN
      string_value_list: ["StringValue"],
    },
  ],
  max_results: 1,
  next_token: "Token",
})

Response structure


resp.resource_info_list #=> Array
resp.resource_info_list[0].resource_arn #=> String
resp.resource_info_list[0].role_arn #=> String
resp.resource_info_list[0].last_modified #=> Time
resp.next_token #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :filter_condition_list (Array<Types::FilterCondition>)

    Any applicable row-level and/or column-level filtering conditions for the resources.

  • :max_results (Integer)

    The maximum number of resource results.

  • :next_token (String)

    A continuation token, if this is not the first call to retrieve these resources.

Returns:

See Also:



2019
2020
2021
2022
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2019

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

#list_table_storage_optimizers(params = {}) ⇒ Types::ListTableStorageOptimizersResponse

Returns the configuration of all storage optimizers associated with a specified table.

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_table_storage_optimizers({
  catalog_id: "CatalogIdString",
  database_name: "NameString", # required
  table_name: "NameString", # required
  storage_optimizer_type: "COMPACTION", # accepts COMPACTION, GARBAGE_COLLECTION, ALL
  max_results: 1,
  next_token: "Token",
})

Response structure


resp.storage_optimizer_list #=> Array
resp.storage_optimizer_list[0].storage_optimizer_type #=> String, one of "COMPACTION", "GARBAGE_COLLECTION", "ALL"
resp.storage_optimizer_list[0].config #=> Hash
resp.storage_optimizer_list[0].config["StorageOptimizerConfigKey"] #=> String
resp.storage_optimizer_list[0].error_message #=> String
resp.storage_optimizer_list[0].warnings #=> String
resp.storage_optimizer_list[0].last_run_details #=> String
resp.next_token #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The Catalog ID of the table.

  • :database_name (required, String)

    Name of the database where the table is present.

  • :table_name (required, String)

    Name of the table.

  • :storage_optimizer_type (String)

    The specific type of storage optimizers to list. The supported value is compaction.

  • :max_results (Integer)

    The number of storage optimizers to return on each call.

  • :next_token (String)

    A continuation token, if this is a continuation call.

Returns:

See Also:



2079
2080
2081
2082
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2079

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

#list_transactions(params = {}) ⇒ Types::ListTransactionsResponse

Returns metadata about transactions and their status. To prevent the response from growing indefinitely, only uncommitted transactions and those available for time-travel queries are returned.

This operation can help you identify uncommitted transactions or to get information about transactions.

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_transactions({
  catalog_id: "CatalogIdString",
  status_filter: "ALL", # accepts ALL, COMPLETED, ACTIVE, COMMITTED, ABORTED
  max_results: 1,
  next_token: "TokenString",
})

Response structure


resp.transactions #=> Array
resp.transactions[0].transaction_id #=> String
resp.transactions[0].transaction_status #=> String, one of "ACTIVE", "COMMITTED", "ABORTED", "COMMIT_IN_PROGRESS"
resp.transactions[0].transaction_start_time #=> Time
resp.transactions[0].transaction_end_time #=> Time
resp.next_token #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The catalog for which to list transactions. Defaults to the account ID of the caller.

  • :status_filter (String)

    A filter indicating the status of transactions to return. Options are ALL | COMPLETED | COMMITTED | ABORTED | ACTIVE. The default is ALL.

  • :max_results (Integer)

    The maximum number of transactions to return in a single call.

  • :next_token (String)

    A continuation token if this is not the first call to retrieve transactions.

Returns:

See Also:



2136
2137
2138
2139
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2136

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

#put_data_lake_settings(params = {}) ⇒ Struct

Sets the list of data lake administrators who have admin privileges on all resources managed by Lake Formation. For more information on admin privileges, see Granting Lake Formation Permissions.

This API replaces the current list of data lake admins with the new list being passed. To add an admin, fetch the current list and add the new admin to that list and pass that list in this API.

Examples:

Request syntax with placeholder values


resp = client.put_data_lake_settings({
  catalog_id: "CatalogIdString",
  data_lake_settings: { # required
    data_lake_admins: [
      {
        data_lake_principal_identifier: "DataLakePrincipalString",
      },
    ],
    create_database_default_permissions: [
      {
        principal: {
          data_lake_principal_identifier: "DataLakePrincipalString",
        },
        permissions: ["ALL"], # accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
      },
    ],
    create_table_default_permissions: [
      {
        principal: {
          data_lake_principal_identifier: "DataLakePrincipalString",
        },
        permissions: ["ALL"], # accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
      },
    ],
    trusted_resource_owners: ["CatalogIdString"],
  },
})

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :data_lake_settings (required, Types::DataLakeSettings)

    A structure representing a list of Lake Formation principals designated as data lake administrators.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2199
2200
2201
2202
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2199

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

#register_resource(params = {}) ⇒ Struct

Registers the resource as managed by the Data Catalog.

To add or update data, Lake Formation needs read/write access to the chosen Amazon S3 path. Choose a role that you know has permission to do this, or choose the AWSServiceRoleForLakeFormationDataAccess service-linked role. When you register the first Amazon S3 path, the service-linked role and a new inline policy are created on your behalf. Lake Formation adds the first path to the inline policy and attaches it to the service-linked role. When you register subsequent paths, Lake Formation adds the path to the existing policy.

The following request registers a new location and gives Lake Formation permission to use the service-linked role to access that location.

ResourceArn = arn:aws:s3:::my-bucket UseServiceLinkedRole = true

If UseServiceLinkedRole is not set to true, you must provide or set the RoleArn:

arn:aws:iam::12345:role/my-data-access-role

Examples:

Request syntax with placeholder values


resp = client.register_resource({
  resource_arn: "ResourceArnString", # required
  use_service_linked_role: false,
  role_arn: "IAMRoleArn",
})

Parameters:

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

    ({})

Options Hash (params):

  • :resource_arn (required, String)

    The Amazon Resource Name (ARN) of the resource that you want to register.

  • :use_service_linked_role (Boolean)

    Designates an Identity and Access Management (IAM) service-linked role by registering this role with the Data Catalog. A service-linked role is a unique type of IAM role that is linked directly to Lake Formation.

    For more information, see Using Service-Linked Roles for Lake Formation.

  • :role_arn (String)

    The identifier for the role that registers the resource.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2260
2261
2262
2263
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2260

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

#remove_lf_tags_from_resource(params = {}) ⇒ Types::RemoveLFTagsFromResourceResponse

Removes an LF-tag from the resource. Only database, table, or tableWithColumns resource are allowed. To tag columns, use the column inclusion list in tableWithColumns to specify column input.

Examples:

Request syntax with placeholder values


resp = client.remove_lf_tags_from_resource({
  catalog_id: "CatalogIdString",
  resource: { # required
    catalog: {
    },
    database: {
      catalog_id: "CatalogIdString",
      name: "NameString", # required
    },
    table: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString",
      table_wildcard: {
      },
    },
    table_with_columns: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString", # required
      column_names: ["NameString"],
      column_wildcard: {
        excluded_column_names: ["NameString"],
      },
    },
    data_location: {
      catalog_id: "CatalogIdString",
      resource_arn: "ResourceArnString", # required
    },
    data_cells_filter: {
      table_catalog_id: "CatalogIdString",
      database_name: "NameString",
      table_name: "NameString",
      name: "NameString",
    },
    lf_tag: {
      catalog_id: "CatalogIdString",
      tag_key: "NameString", # required
      tag_values: ["LFTagValue"], # required
    },
    lf_tag_policy: {
      catalog_id: "CatalogIdString",
      resource_type: "DATABASE", # required, accepts DATABASE, TABLE
      expression: [ # required
        {
          tag_key: "LFTagKey", # required
          tag_values: ["LFTagValue"], # required
        },
      ],
    },
  },
  lf_tags: [ # required
    {
      catalog_id: "CatalogIdString",
      tag_key: "LFTagKey", # required
      tag_values: ["LFTagValue"], # required
    },
  ],
})

Response structure


resp.failures #=> Array
resp.failures[0].lf_tag.catalog_id #=> String
resp.failures[0].lf_tag.tag_key #=> String
resp.failures[0].lf_tag.tag_values #=> Array
resp.failures[0].lf_tag.tag_values[0] #=> String
resp.failures[0].error.error_code #=> String
resp.failures[0].error.error_message #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :resource (required, Types::Resource)

    The database, table, or column resource where you want to remove an LF-tag.

  • :lf_tags (required, Array<Types::LFTagPair>)

    The LF-tags to be removed from the resource.

Returns:

See Also:



2362
2363
2364
2365
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2362

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

#revoke_permissions(params = {}) ⇒ Struct

Revokes permissions to the principal to access metadata in the Data Catalog and data organized in underlying data storage such as Amazon S3.

Examples:

Request syntax with placeholder values


resp = client.revoke_permissions({
  catalog_id: "CatalogIdString",
  principal: { # required
    data_lake_principal_identifier: "DataLakePrincipalString",
  },
  resource: { # required
    catalog: {
    },
    database: {
      catalog_id: "CatalogIdString",
      name: "NameString", # required
    },
    table: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString",
      table_wildcard: {
      },
    },
    table_with_columns: {
      catalog_id: "CatalogIdString",
      database_name: "NameString", # required
      name: "NameString", # required
      column_names: ["NameString"],
      column_wildcard: {
        excluded_column_names: ["NameString"],
      },
    },
    data_location: {
      catalog_id: "CatalogIdString",
      resource_arn: "ResourceArnString", # required
    },
    data_cells_filter: {
      table_catalog_id: "CatalogIdString",
      database_name: "NameString",
      table_name: "NameString",
      name: "NameString",
    },
    lf_tag: {
      catalog_id: "CatalogIdString",
      tag_key: "NameString", # required
      tag_values: ["LFTagValue"], # required
    },
    lf_tag_policy: {
      catalog_id: "CatalogIdString",
      resource_type: "DATABASE", # required, accepts DATABASE, TABLE
      expression: [ # required
        {
          tag_key: "LFTagKey", # required
          tag_values: ["LFTagValue"], # required
        },
      ],
    },
  },
  permissions: ["ALL"], # required, accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
  permissions_with_grant_option: ["ALL"], # accepts ALL, SELECT, ALTER, DROP, DELETE, INSERT, DESCRIBE, CREATE_DATABASE, CREATE_TABLE, DATA_LOCATION_ACCESS, CREATE_TAG, ALTER_TAG, DELETE_TAG, DESCRIBE_TAG, ASSOCIATE_TAG
})

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :principal (required, Types::DataLakePrincipal)

    The principal to be revoked permissions on the resource.

  • :resource (required, Types::Resource)

    The resource to which permissions are to be revoked.

  • :permissions (required, Array<String>)

    The permissions revoked to the principal on the resource. For information about permissions, see Security and Access Control to Metadata and Data.

  • :permissions_with_grant_option (Array<String>)

    Indicates a list of permissions for which to revoke the grant option allowing the principal to pass permissions to other principals.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2462
2463
2464
2465
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2462

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

#search_databases_by_lf_tags(params = {}) ⇒ Types::SearchDatabasesByLFTagsResponse

This operation allows a search on DATABASE resources by TagCondition. This operation is used by admins who want to grant user permissions on certain TagConditions. Before making a grant, the admin can use SearchDatabasesByTags to find all resources where the given TagConditions are valid to verify whether the returned resources can be shared.

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

Examples:

Request syntax with placeholder values


resp = client.search_databases_by_lf_tags({
  next_token: "Token",
  max_results: 1,
  catalog_id: "CatalogIdString",
  expression: [ # required
    {
      tag_key: "LFTagKey", # required
      tag_values: ["LFTagValue"], # required
    },
  ],
})

Response structure


resp.next_token #=> String
resp.database_list #=> Array
resp.database_list[0].database.catalog_id #=> String
resp.database_list[0].database.name #=> String
resp.database_list[0].lf_tags #=> Array
resp.database_list[0].lf_tags[0].catalog_id #=> String
resp.database_list[0].lf_tags[0].tag_key #=> String
resp.database_list[0].lf_tags[0].tag_values #=> Array
resp.database_list[0].lf_tags[0].tag_values[0] #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :next_token (String)

    A continuation token, if this is not the first call to retrieve this list.

  • :max_results (Integer)

    The maximum number of results to return.

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :expression (required, Array<Types::LFTag>)

    A list of conditions (LFTag structures) to search for in database resources.

Returns:

See Also:



2528
2529
2530
2531
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2528

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

#search_tables_by_lf_tags(params = {}) ⇒ Types::SearchTablesByLFTagsResponse

This operation allows a search on TABLE resources by LFTags. This will be used by admins who want to grant user permissions on certain LF-tags. Before making a grant, the admin can use SearchTablesByLFTags to find all resources where the given LFTags are valid to verify whether the returned resources can be shared.

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

Examples:

Request syntax with placeholder values


resp = client.search_tables_by_lf_tags({
  next_token: "Token",
  max_results: 1,
  catalog_id: "CatalogIdString",
  expression: [ # required
    {
      tag_key: "LFTagKey", # required
      tag_values: ["LFTagValue"], # required
    },
  ],
})

Response structure


resp.next_token #=> String
resp.table_list #=> Array
resp.table_list[0].table.catalog_id #=> String
resp.table_list[0].table.database_name #=> String
resp.table_list[0].table.name #=> String
resp.table_list[0].lf_tag_on_database #=> Array
resp.table_list[0].lf_tag_on_database[0].catalog_id #=> String
resp.table_list[0].lf_tag_on_database[0].tag_key #=> String
resp.table_list[0].lf_tag_on_database[0].tag_values #=> Array
resp.table_list[0].lf_tag_on_database[0].tag_values[0] #=> String
resp.table_list[0].lf_tags_on_table #=> Array
resp.table_list[0].lf_tags_on_table[0].catalog_id #=> String
resp.table_list[0].lf_tags_on_table[0].tag_key #=> String
resp.table_list[0].lf_tags_on_table[0].tag_values #=> Array
resp.table_list[0].lf_tags_on_table[0].tag_values[0] #=> String
resp.table_list[0].lf_tags_on_columns #=> Array
resp.table_list[0].lf_tags_on_columns[0].name #=> String
resp.table_list[0].lf_tags_on_columns[0].lf_tags #=> Array
resp.table_list[0].lf_tags_on_columns[0].lf_tags[0].catalog_id #=> String
resp.table_list[0].lf_tags_on_columns[0].lf_tags[0].tag_key #=> String
resp.table_list[0].lf_tags_on_columns[0].lf_tags[0].tag_values #=> Array
resp.table_list[0].lf_tags_on_columns[0].lf_tags[0].tag_values[0] #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :next_token (String)

    A continuation token, if this is not the first call to retrieve this list.

  • :max_results (Integer)

    The maximum number of results to return.

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :expression (required, Array<Types::LFTag>)

    A list of conditions (LFTag structures) to search for in table resources.

Returns:

See Also:



2606
2607
2608
2609
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2606

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

#start_query_planning(params = {}) ⇒ Types::StartQueryPlanningResponse

Submits a request to process a query statement.

This operation generates work units that can be retrieved with the GetWorkUnits operation as soon as the query state is WORKUNITS_AVAILABLE or FINISHED.

Examples:

Request syntax with placeholder values


resp = client.start_query_planning({
  query_planning_context: { # required
    catalog_id: "CatalogIdString",
    database_name: "QueryPlanningContextDatabaseNameString", # required
    query_as_of_time: Time.now,
    query_parameters: {
      "String" => "String",
    },
    transaction_id: "TransactionIdString",
  },
  query_string: "SyntheticStartQueryPlanningRequestQueryString", # required
})

Response structure


resp.query_id #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :query_planning_context (required, Types::QueryPlanningContext)

    A structure containing information about the query plan.

  • :query_string (required, String)

    A PartiQL query statement used as an input to the planner service.

Returns:

See Also:



2650
2651
2652
2653
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2650

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

#start_transaction(params = {}) ⇒ Types::StartTransactionResponse

Starts a new transaction and returns its transaction ID. Transaction IDs are opaque objects that you can use to identify a transaction.

Examples:

Request syntax with placeholder values


resp = client.start_transaction({
  transaction_type: "READ_AND_WRITE", # accepts READ_AND_WRITE, READ_ONLY
})

Response structure


resp.transaction_id #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :transaction_type (String)

    Indicates whether this transaction should be read only or read and write. Writes made using a read-only transaction ID will be rejected. Read-only transactions do not need to be committed.

Returns:

See Also:



2681
2682
2683
2684
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2681

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

#update_lf_tag(params = {}) ⇒ Struct

Updates the list of possible values for the specified LF-tag key. If the LF-tag does not exist, the operation throws an EntityNotFoundException. The values in the delete key values will be deleted from list of possible values. If any value in the delete key values is attached to a resource, then API errors out with a 400 Exception - "Update not allowed". Untag the attribute before deleting the LF-tag key's value.

Examples:

Request syntax with placeholder values


resp = client.update_lf_tag({
  catalog_id: "CatalogIdString",
  tag_key: "LFTagKey", # required
  tag_values_to_delete: ["LFTagValue"],
  tag_values_to_add: ["LFTagValue"],
})

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.

  • :tag_key (required, String)

    The key-name for the LF-tag for which to add or delete values.

  • :tag_values_to_delete (Array<String>)

    A list of LF-tag values to delete from the LF-tag.

  • :tag_values_to_add (Array<String>)

    A list of LF-tag values to add from the LF-tag.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2724
2725
2726
2727
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2724

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

#update_resource(params = {}) ⇒ Struct

Updates the data access role used for vending access to the given (registered) resource in Lake Formation.

Examples:

Request syntax with placeholder values


resp = client.update_resource({
  role_arn: "IAMRoleArn", # required
  resource_arn: "ResourceArnString", # required
})

Parameters:

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

    ({})

Options Hash (params):

  • :role_arn (required, String)

    The new role to use for the given resource registered in Lake Formation.

  • :resource_arn (required, String)

    The resource ARN.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2752
2753
2754
2755
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2752

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

#update_table_objects(params = {}) ⇒ Struct

Updates the manifest of Amazon S3 objects that make up the specified governed table.

Examples:

Request syntax with placeholder values


resp = client.update_table_objects({
  catalog_id: "CatalogIdString",
  database_name: "NameString", # required
  table_name: "NameString", # required
  transaction_id: "TransactionIdString", # required
  write_operations: [ # required
    {
      add_object: {
        uri: "URI", # required
        etag: "ETagString", # required
        size: 1, # required
        partition_values: ["PartitionValueString"],
      },
      delete_object: {
        uri: "URI", # required
        etag: "ETagString",
        partition_values: ["PartitionValueString"],
      },
    },
  ],
})

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The catalog containing the governed table to update. Defaults to the caller’s account ID.

  • :database_name (required, String)

    The database containing the governed table to update.

  • :table_name (required, String)

    The governed table to update.

  • :transaction_id (required, String)

    The transaction at which to do the write.

  • :write_operations (required, Array<Types::WriteOperation>)

    A list of WriteOperation objects that define an object to add to or delete from the manifest for a governed table.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2807
2808
2809
2810
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2807

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

#update_table_storage_optimizer(params = {}) ⇒ Types::UpdateTableStorageOptimizerResponse

Updates the configuration of the storage optimizers for a table.

Examples:

Request syntax with placeholder values


resp = client.update_table_storage_optimizer({
  catalog_id: "CatalogIdString",
  database_name: "NameString", # required
  table_name: "NameString", # required
  storage_optimizer_config: { # required
    "COMPACTION" => {
      "StorageOptimizerConfigKey" => "StorageOptimizerConfigValue",
    },
  },
})

Response structure


resp.result #=> String

Parameters:

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

    ({})

Options Hash (params):

  • :catalog_id (String)

    The Catalog ID of the table.

  • :database_name (required, String)

    Name of the database where the table is present.

  • :table_name (required, String)

    Name of the table for which to enable the storage optimizer.

  • :storage_optimizer_config (required, Hash<String,Hash>)

    Name of the table for which to enable the storage optimizer.

Returns:

See Also:



2851
2852
2853
2854
# File 'gems/aws-sdk-lakeformation/lib/aws-sdk-lakeformation/client.rb', line 2851

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