Class: AWSCDK::Athena::CfnWorkGroup::ResultConfigurationProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
athena/cfn_work_group.rb

Overview

The location in Amazon S3 where query and calculation results are stored and the encryption option, if any, used for query and calculation results.

These are known as "client-side settings". If workgroup settings override client-side settings, then the query uses the workgroup settings.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(acl_configuration: nil, encryption_configuration: nil, expected_bucket_owner: nil, output_location: nil) ⇒ ResultConfigurationProperty

Returns a new instance of ResultConfigurationProperty.

Parameters:

  • acl_configuration (AWSCDK::IResolvable, AWSCDK::Athena::CfnWorkGroup::AclConfigurationProperty, nil) (defaults to: nil)

    Indicates that an Amazon S3 canned ACL should be set to control ownership of stored query results.

  • encryption_configuration (AWSCDK::IResolvable, AWSCDK::Athena::CfnWorkGroup::EncryptionConfigurationProperty, nil) (defaults to: nil)

    If query results are encrypted in Amazon S3, indicates the encryption option used (for example, SSE_KMS or CSE_KMS ) and key information.

  • expected_bucket_owner (String, nil) (defaults to: nil)

    The account ID that you expect to be the owner of the Amazon S3 bucket specified by ResultConfiguration:OutputLocation .

  • output_location (String, nil) (defaults to: nil)

    The location in Amazon S3 where your query results are stored, such as s3://path/to/query/bucket/ .



1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
# File 'athena/cfn_work_group.rb', line 1181

def initialize(acl_configuration: nil, encryption_configuration: nil, expected_bucket_owner: nil, output_location: nil)
  @acl_configuration = acl_configuration.is_a?(Hash) ? ::AWSCDK::Athena::CfnWorkGroup::AclConfigurationProperty.new(**acl_configuration.transform_keys(&:to_sym)) : acl_configuration
  Jsii::Type.check_type(@acl_configuration, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19hdGhlbmEuQ2ZuV29ya0dyb3VwLkFjbENvbmZpZ3VyYXRpb25Qcm9wZXJ0eSJ9XX19")), "aclConfiguration") unless @acl_configuration.nil?
  @encryption_configuration = encryption_configuration.is_a?(Hash) ? ::AWSCDK::Athena::CfnWorkGroup::EncryptionConfigurationProperty.new(**encryption_configuration.transform_keys(&:to_sym)) : encryption_configuration
  Jsii::Type.check_type(@encryption_configuration, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19hdGhlbmEuQ2ZuV29ya0dyb3VwLkVuY3J5cHRpb25Db25maWd1cmF0aW9uUHJvcGVydHkifV19fQ==")), "encryptionConfiguration") unless @encryption_configuration.nil?
  @expected_bucket_owner = expected_bucket_owner
  Jsii::Type.check_type(@expected_bucket_owner, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "expectedBucketOwner") unless @expected_bucket_owner.nil?
  @output_location = output_location
  Jsii::Type.check_type(@output_location, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "outputLocation") unless @output_location.nil?
end

Instance Attribute Details

#acl_configurationAWSCDK::IResolvable, ... (readonly)

Indicates that an Amazon S3 canned ACL should be set to control ownership of stored query results.

Currently the only supported canned ACL is BUCKET_OWNER_FULL_CONTROL . This is a client-side setting. If workgroup settings override client-side settings, then the query uses the ACL configuration that is specified for the workgroup, and also uses the location for storing query results specified in the workgroup. See EnforceWorkGroupConfiguration .



1198
1199
1200
# File 'athena/cfn_work_group.rb', line 1198

def acl_configuration
  @acl_configuration
end

#encryption_configurationAWSCDK::IResolvable, ... (readonly)

If query results are encrypted in Amazon S3, indicates the encryption option used (for example, SSE_KMS or CSE_KMS ) and key information.

This is a client-side setting. If workgroup settings override client-side settings, then the query uses the encryption configuration that is specified for the workgroup, and also uses the location for storing query results specified in the workgroup. See EnforceWorkGroupConfiguration and Override client-side settings .



1205
1206
1207
# File 'athena/cfn_work_group.rb', line 1205

def encryption_configuration
  @encryption_configuration
end

#expected_bucket_ownerString? (readonly)

The account ID that you expect to be the owner of the Amazon S3 bucket specified by ResultConfiguration:OutputLocation .

If set, Athena uses the value for ExpectedBucketOwner when it makes Amazon S3 calls to your specified output location. If the ExpectedBucketOwner account ID does not match the actual owner of the Amazon S3 bucket, the call fails with a permissions error.

This is a client-side setting. If workgroup settings override client-side settings, then the query uses the ExpectedBucketOwner setting that is specified for the workgroup, and also uses the location for storing query results specified in the workgroup. See EnforceWorkGroupConfiguration .



1214
1215
1216
# File 'athena/cfn_work_group.rb', line 1214

def expected_bucket_owner
  @expected_bucket_owner
end

#output_locationString? (readonly)

The location in Amazon S3 where your query results are stored, such as s3://path/to/query/bucket/ .

To run a query, you must specify the query results location using either a client-side setting for individual queries or a location specified by the workgroup. If workgroup settings override client-side settings, then the query uses the location specified for the workgroup. If no query location is set, Athena issues an error. For more information, see Work with query results and recent queries and EnforceWorkGroupConfiguration .



1221
1222
1223
# File 'athena/cfn_work_group.rb', line 1221

def output_location
  @output_location
end

Class Method Details

.jsii_propertiesObject



1223
1224
1225
1226
1227
1228
1229
1230
# File 'athena/cfn_work_group.rb', line 1223

def self.jsii_properties
  {
    :acl_configuration => "aclConfiguration",
    :encryption_configuration => "encryptionConfiguration",
    :expected_bucket_owner => "expectedBucketOwner",
    :output_location => "outputLocation",
  }
end

Instance Method Details

#to_jsiiObject



1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
# File 'athena/cfn_work_group.rb', line 1232

def to_jsii
  result = {}
  result.merge!({
    "aclConfiguration" => @acl_configuration,
    "encryptionConfiguration" => @encryption_configuration,
    "expectedBucketOwner" => @expected_bucket_owner,
    "outputLocation" => @output_location,
  })
  result.compact
end