Class CfnPermissions
- All Implemented Interfaces:
IConstruct
,IDependable
,IInspectable
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
AWS::LakeFormation::Permissions
.
The AWS::LakeFormation::Permissions
resource represents the permissions that a principal has on an AWS Glue Data Catalog resource (such as AWS Glue database or AWS Glue tables). When you upload a permissions stack, the permissions are granted to the principal and when you remove the stack, the permissions are revoked from the principal. If you remove a stack, and the principal does not have the permissions referenced in the stack then AWS Lake Formation will throw an error because you can’t call revoke on non-existing permissions. To successfully remove the stack, you’ll need to regrant those permissions and then remove the stack.
New versions of AWS Lake Formation permission resources are now available. For more information, see: AWS:LakeFormation::PrincipalPermissions
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.lakeformation.*; CfnPermissions cfnPermissions = CfnPermissions.Builder.create(this, "MyCfnPermissions") .dataLakePrincipal(DataLakePrincipalProperty.builder() .dataLakePrincipalIdentifier("dataLakePrincipalIdentifier") .build()) .resource(ResourceProperty.builder() .databaseResource(DatabaseResourceProperty.builder() .catalogId("catalogId") .name("name") .build()) .dataLocationResource(DataLocationResourceProperty.builder() .catalogId("catalogId") .s3Resource("s3Resource") .build()) .tableResource(TableResourceProperty.builder() .catalogId("catalogId") .databaseName("databaseName") .name("name") .tableWildcard(TableWildcardProperty.builder().build()) .build()) .tableWithColumnsResource(TableWithColumnsResourceProperty.builder() .catalogId("catalogId") .columnNames(List.of("columnNames")) .columnWildcard(ColumnWildcardProperty.builder() .excludedColumnNames(List.of("excludedColumnNames")) .build()) .databaseName("databaseName") .name("name") .build()) .build()) // the properties below are optional .permissions(List.of("permissions")) .permissionsWithGrantOption(List.of("permissionsWithGrantOption")) .build();
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic final class
A fluent builder forCfnPermissions
.static interface
A wildcard object, consisting of an optional list of excluded column names or indexes.static interface
A structure for the database object.static interface
The Lake Formation principal.static interface
A structure for a data location object where permissions are granted or revoked.static interface
A structure for the resource.static interface
A structure for the table object.static interface
A wildcard object representing every table under a database.static interface
A structure for a table with columns object.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IConstruct
IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The CloudFormation resource type name for this resource class. -
Constructor Summary
ModifierConstructorDescriptionCfnPermissions
(Construct scope, String id, CfnPermissionsProps props) Create a newAWS::LakeFormation::Permissions
.protected
CfnPermissions
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
CfnPermissions
(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptionThe AWS Lake Formation principal.The permissions granted or revoked.Indicates the ability to grant permissions (as a subset of permissions granted).A structure for the resource.void
inspect
(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties
(Map<String, Object> props) void
setDataLakePrincipal
(IResolvable value) The AWS Lake Formation principal.void
The AWS Lake Formation principal.void
setPermissions
(List<String> value) The permissions granted or revoked.void
setPermissionsWithGrantOption
(List<String> value) Indicates the ability to grant permissions (as a subset of permissions granted).void
setResource
(IResolvable value) A structure for the resource.void
A structure for the resource.Methods inherited from class software.amazon.awscdk.core.CfnResource
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, isCfnResource, shouldSynthesize, toString, validateProperties
Methods inherited from class software.amazon.awscdk.core.CfnRefElement
getRef
Methods inherited from class software.amazon.awscdk.core.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId
Methods inherited from class software.amazon.awscdk.core.Construct
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validate
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnPermissions
protected CfnPermissions(software.amazon.jsii.JsiiObjectRef objRef) -
CfnPermissions
protected CfnPermissions(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnPermissions
@Stability(Stable) public CfnPermissions(@NotNull Construct scope, @NotNull String id, @NotNull CfnPermissionsProps props) Create a newAWS::LakeFormation::Permissions
.- Parameters:
scope
-- scope in which this resource is defined.
id
-- scoped id of the resource.
props
-- resource properties.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspect
in interfaceIInspectable
- Parameters:
inspector
-- tree inspector to collect and process attributes.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderProperties
in classCfnResource
- Parameters:
props
- This parameter is required.
-
getCfnProperties
- Overrides:
getCfnProperties
in classCfnResource
-
getDataLakePrincipal
The AWS Lake Formation principal. -
setDataLakePrincipal
The AWS Lake Formation principal. -
setDataLakePrincipal
@Stability(Stable) public void setDataLakePrincipal(@NotNull CfnPermissions.DataLakePrincipalProperty value) The AWS Lake Formation principal. -
getResource
A structure for the resource. -
setResource
A structure for the resource. -
setResource
A structure for the resource. -
getPermissions
The permissions granted or revoked. -
setPermissions
The permissions granted or revoked. -
getPermissionsWithGrantOption
Indicates the ability to grant permissions (as a subset of permissions granted). -
setPermissionsWithGrantOption
Indicates the ability to grant permissions (as a subset of permissions granted).
-