Manage Google Cloud Storage assets¶
Operations on GCS assets (connections, buckets, objects).
In general, these should be:
- Created in top-down order (connection, then bucket, then object)
- Deleted in bottom-up order (objects, then buckets, then connections)1
erDiagram
Connection ||--o{ GCSBucket : contains
GCSBucket ||--o{ GCSObject : contains
Asset structure¶
Connection¶
A Google Cloud Storage connection requires a name and qualifiedName. For creation, specific settings are also required to distinguish it as a Google Cloud Storage connection rather than another type of connection. In addition, at least one of adminRoles, adminGroups, or adminUsers must be provided.
| Create a GCS connection | |
|---|---|
1 2 3 4 5 6 7 8 9 10 | |
- Retrieve the GUID for the admin role, to use later for defining the roles that can administer the connection.
- Build up the minimum request to create a connection.
- Provide a human-readable name for your connection, such as
productionordevelopment. - Set the type of connection to GCS.
- List the workspace roles that should be able to administer the connection (or null if none). All users with that workspace role (current and future) will be administrators of the connection. Note that the values here need to be the GUID(s) of the workspace role(s). At least one of
adminRoles,adminGroups, oradminUsersmust be provided. - List the group names that can administer this connection (or null if none). All users within that group (current and future) will be administrators of the connection. Note that the values here are the name(s) of the group(s). At least one of
adminRoles,adminGroups, oradminUsersmust be provided. - List the user names that can administer this connection (or null if none). Note that the values here are the username(s) of the user(s). At least one of
adminRoles,adminGroups, oradminUsersmust be provided. - Actually call Atlan to create the connection. Because this operation will persist the asset in Atlan, you must provide it an
AtlanClientthrough which to connect to the tenant. - Retrieve the qualifiedName for use in subsequent creation calls. (You'd probably want to do some null checking first.)
| Create a GCS connection | |
|---|---|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | |
- Retrieve the GUID for the admin role, to use later for defining the roles that can administer the connection.
- Build up the minimum request to create a connection.
- You must provide a client instance.
- Provide a human-readable name for your connection, such as
productionordevelopment. - Set the type of connection to GCS.
- List the workspace roles that should be able to administer the connection (or
Noneif none). All users with that workspace role (current and future) will be administrators of the connection. Note that the values here need to be the GUID(s) of the workspace role(s). At least one ofadmin_roles,admin_groups, oradmin_usersmust be provided. - List the group names that can administer this connection (or
Noneif none). All users within that group (current and future) will be administrators of the connection. Note that the values here are the name(s) of the group(s). At least one ofadmin_roles,admin_groups, oradmin_usersmust be provided. - List the user names that can administer this connection (or
Noneif none). Note that the values here are the username(s) of the user(s). At least one ofadmin_roles,admin_groups, oradmin_usersmust be provided. - Actually call Atlan to create the connection.
- Retrieve the qualifiedName for use in subsequent creation calls. (You'd probably want to do some null checking first.)
| Create a GCS connection | |
|---|---|
1 2 3 4 5 6 7 8 9 10 | |
- Retrieve the GUID for the admin role, to use later for defining the roles that can administer the connection.
- Build up the minimum request to create a connection.
- Provide a human-readable name for your connection, such as
productionordevelopment. - Set the type of connection to GCS.
- List the workspace roles that should be able to administer the connection (or null if none). All users with that workspace role (current and future) will be administrators of the connection. Note that the values here need to be the GUID(s) of the workspace role(s). At least one of
adminRoles,adminGroups, oradminUsersmust be provided. - List the group names that can administer this connection (or null if none). All users within that group (current and future) will be administrators of the connection. Note that the values here are the name(s) of the group(s). At least one of
adminRoles,adminGroups, oradminUsersmust be provided. - List the user names that can administer this connection (or null if none). Note that the values here are the username(s) of the user(s). At least one of
adminRoles,adminGroups, oradminUsersmust be provided. - Actually call Atlan to create the connection. Because this operation will persist the asset in Atlan, you must provide it an
AtlanClientthrough which to connect to the tenant. - Retrieve the qualifiedName for use in subsequent creation calls. (You'd probably want to do some null checking first.)
| POST /api/meta/entity/bulk | |
|---|---|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | |
- The
typeNamemust be exactlyConnection. - Human-readable name for your connection, such as
productionordevelopment. - The
connectorNamemust be exactlygcs. - The
qualifiedNameshould follow the pattern:default/gcs/<epoch>, where<epoch>is the time in milliseconds at which the connection is being created. - The
categorymust beObjectStore. - List any workspace roles that can administer this connection. All users with that workspace role (current and future) will be administrators of the connection. Note that the values here need to be the GUID(s) of the workspace role(s). At least one of
adminRoles,adminGroups, oradminUsersmust be provided. - List any groups that can administer this connection. All users within that group (current and future) will be administrators of the connection. Note that the values here are the name(s) of the group(s). At least one of
adminRoles,adminGroups, oradminUsersmust be provided. - List any users that can administer this connection. Note that the values here are the username(s) of the user(s). At least one of
adminRoles,adminGroups, oradminUsersmust be provided.
Access policies
Atlan creates the policies that grant access to a connection, including the ability to retrieve the connection and to create assets within it, asynchronously. It can take several seconds (even up to approximately 30 seconds) before these are in place after creating the connection.
You may therefore need to wait before you'll be able to create the assets below within the connection.
To confirm access, retrieve the connection after it has been created. The SDKs' retry loops will automatically retry until the connection can be successfully retrieved. At that point, your API token has permission to create the other assets.
Note: if you are reusing an existing connection rather than creating one via your API token, you must give your API token a persona that has access to that connection. Otherwise all attempts to create, read, update, or delete assets within that connection will fail due to a lack of permissions.
GCSBucket¶
A Google Cloud Storage bucket requires a name and a qualifiedName. For creation, you also need to specify the connectionQualifiedName of the connection for the bucket.
| Create a GCS bucket | |
|---|---|
11 12 13 14 15 16 17 | |
- Build up the minimum request to create a bucket.
- Provide a human-readable name for your bucket.
- Provide the qualifiedName of the connection for this bucket.
- (Optional) To ensure the UI displays the correct count of
GCSObject's, set thegcsObjectCountdirectly on theGCSBucketinstance. - Actually call Atlan to create the bucket. Because this operation will persist the asset in Atlan, you must provide it an
AtlanClientthrough which to connect to the tenant. - Retrieve the created bucket for use in subsequent creation calls. (You'd probably want to do some null checking first.)
| Create a GCS bucket | |
|---|---|
17 18 19 20 21 22 23 | |
- Build up the minimum request to create a bucket.
- Provide a human-readable name for your bucket.
- Provide the
qualified_nameof the connection for this bucket. - (Optional) To ensure the UI displays the correct count of
GCSObject's, set thegcs_object_countdirectly on theGCSBucketinstance. - Actually call Atlan to create the bucket.
- Retrieve the created bucket for use in subsequent creation calls.(You'd probably want to do some null checking first.)
| Create a GCS bucket | |
|---|---|
11 12 13 14 15 16 17 | |
- Build up the minimum request to create a bucket.
- Provide a human-readable name for your bucket.
- Provide the qualifiedName of the connection for this bucket.
- (Optional) To ensure the UI displays the correct count of
GCSObject's, set thegcsObjectCountdirectly on theGCSBucketinstance. - Actually call Atlan to create the bucket. Because this operation will persist the asset in Atlan, you must provide it an
AtlanClientthrough which to connect to the tenant. - Retrieve the created bucket for use in subsequent creation calls. (You'd probably want to do some null checking first.)
| POST /api/meta/entity/bulk | |
|---|---|
1 2 3 4 5 6 7 8 9 10 11 12 13 | |
- The
typeNamemust be exactlyGCSBucket. - Human-readable name for your bucket.
- The
qualifiedNameshould follow the pattern:default/gcs/<epoch>/<name>, wheredefault/gcs/<epoch>is the qualifiedName of the connection for this bucket and<name>is the unique name for this bucket. - The
connectionQualifiedNamemust be the exact qualifiedName of the connection for this bucket. - The
connectorNamemust be exactlygcs.
GCSObject¶
A Google Cloud Storage object requires a name and a qualifiedName. For creation, you also need to specify the bucketQualifiedName of the bucket that will contain the object.
| Create a GCS object | |
|---|---|
18 19 20 21 22 | |
- Build up the minimum request to create an object.
- Provide a human-readable name for your object.
- Provide the bucket for this object. If you did not already have the bucket, you could also use
GCSBucket.refByGuid()with the GUID of the bucket, orGCSBucket.refByQualifiedName()with thequalifiedNameof the bucket. - Actually call Atlan to create the object. Because this operation will persist the asset in Atlan, you must provide it an
AtlanClientthrough which to connect to the tenant.
| Create a GCS object | |
|---|---|
23 24 25 26 27 28 | |
- Build up the minimum request to create an object.
- Provide a human-readable name for your object.
- Provide the
nameof the bucket this object should be created within. - Provide the
qualified_nameof the bucket for this object. - Actually call Atlan to create the object.
| Create a GCS object | |
|---|---|
18 19 20 21 22 | |
- Build up the minimum request to create an object.
- Provide a human-readable name for your object.
- Provide the bucket for this object. If you did not already have the bucket, you could also use
GCSBucket.refByGuid()with the GUID of the bucket, orGCSBucket.refByQualifiedName()with thequalifiedNameof the bucket. - Actually call Atlan to create the object. Because this operation will persist the asset in Atlan, you must provide it an
AtlanClientthrough which to connect to the tenant.
| POST /api/meta/entity/bulk | |
|---|---|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | |
- The
typeNamemust be exactlyGCSObject. - Human-readable name for your object.
- The
qualifiedNameshould follow the pattern:default/gcs/<epoch>/<bucket>/<name>, wheredefault/gcs/<epoch>/<bucket>is the qualifiedName of the bucket that contains this object and<name>is the unique name for this object. - The
connectionQualifiedNamemust be the exact qualifiedName of the connection for this object. - The
connectorNamemust be exactlygcs. - The bucket in which this object exists is embedded in the
gcsBucketattribute. - The
typeNamefor this embedded reference must beGCSBucket. - To complete the reference, you must include a
uniqueAttributesobject with the qualifiedName of the bucket. Note: the bucket must already exist in Atlan before creating the object. - The
gcsBucketNameshould be the human-readable name of the bucket. - The
gcsBucketQualifiedNameshould be the qualifiedName of the bucket.
By prefix¶
Create a GCS object using prefix:
Coming soon
| Create a GCS object using prefix | |
|---|---|
23 24 25 26 27 28 29 30 | |
- Build up the minimum request to create an object.
- Provide a human-readable name for your object.
- Provide the
qualified_nameof the connection for this object. - Provide the folder path where the object is located within the bucket.
- Provide the
nameof the bucket this object should be created within. - Provide the
qualified_nameof the bucket this object should be created within. - Actually call Atlan to create the object.
Coming soon
| POST /api/meta/entity/bulk | |
|---|---|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | |
- The
typeNamemust be exactlyGCSObject. - Human-readable name for your object.
- The
qualifiedNameshould follow the pattern:default/gcs/<epoch>/<bucket-name>/<prefix>/<name>, wheredefault/gcs/<epoch>is thequalifiedNameof the connection for this object, and<prefix>/<name>is the folder path where this object is located within the bucket. - Provide the folder path where the object is located within the bucket.
- The
connectionQualifiedNamemust be the exact qualifiedName of the connection for this object. - The
connectorNamemust be exactlygcs. - The bucket in which this object exists is embedded in the
gcsBucketattribute. - The
typeNamefor this embedded reference must beGCSBucket. - To complete the reference, you must include a
uniqueAttributesobject with the qualifiedName of the bucket. Note: the bucket must already exist in Atlan before creating the object. - The
gcsBucketNameshould be the human-readable name of the bucket. - The
gcsBucketQualifiedNameshould be the qualifiedName of the bucket.
Available relationships¶
Every level of the object store structure is an Asset, and can therefore be related to the following other assets.
erDiagram
Asset }o--o{ AtlasGlossaryTerm : meanings
Asset ||--o{ Link : links
Asset ||--o| Readme : readme
Asset }o--o{ Process : inputToProcesses
Asset }o--o{ Process : outputFromProcesses
AtlasGlossaryTerm¶
A glossary term provides meaning to an asset. The link terms to assets snippet provides more detail on setting this relationship.
Link¶
A link provides additional context to an asset, by providing a URL to additional information.
Readme¶
A README provides rich documentation for an asset. The add asset READMEs snippet provides more detail on setting this relationship.
Process¶
A process provides lineage information for an asset. An asset can be both an input and an output for one or more processes. The lineage snippets provide more detail on creating and working with lineage.
-
Although if you want to delete everything in a connection, your better avenue is the packaged connection delete utility in the UI. ↩