pulumi-snowflake 0.50.3a1710160126__py3-none-any.whl → 1.2.0a1736849992__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pulumi-snowflake might be problematic. Click here for more details.
- pulumi_snowflake/__init__.py +224 -172
- pulumi_snowflake/_inputs.py +52857 -1665
- pulumi_snowflake/_utilities.py +41 -5
- pulumi_snowflake/account.py +188 -218
- pulumi_snowflake/account_authentication_policy_attachment.py +149 -0
- pulumi_snowflake/account_parameter.py +21 -48
- pulumi_snowflake/account_password_policy_attachment.py +7 -32
- pulumi_snowflake/account_role.py +250 -0
- pulumi_snowflake/alert.py +38 -47
- pulumi_snowflake/api_authentication_integration_with_authorization_code_grant.py +704 -0
- pulumi_snowflake/api_authentication_integration_with_client_credentials.py +657 -0
- pulumi_snowflake/api_authentication_integration_with_jwt_bearer.py +692 -0
- pulumi_snowflake/api_integration.py +33 -52
- pulumi_snowflake/authentication_policy.py +622 -0
- pulumi_snowflake/config/__init__.pyi +76 -99
- pulumi_snowflake/config/outputs.py +5 -0
- pulumi_snowflake/config/vars.py +93 -124
- pulumi_snowflake/cortex_search_service.py +596 -0
- pulumi_snowflake/database.py +819 -213
- pulumi_snowflake/database_role.py +81 -44
- pulumi_snowflake/dynamic_table.py +42 -49
- pulumi_snowflake/email_notification_integration.py +33 -28
- pulumi_snowflake/{unsafe_execute.py → execute.py} +36 -39
- pulumi_snowflake/external_function.py +54 -75
- pulumi_snowflake/external_oauth_integration.py +593 -542
- pulumi_snowflake/external_table.py +67 -90
- pulumi_snowflake/external_volume.py +382 -0
- pulumi_snowflake/failover_group.py +57 -98
- pulumi_snowflake/file_format.py +33 -28
- pulumi_snowflake/function_java.py +1211 -0
- pulumi_snowflake/function_javascript.py +882 -0
- pulumi_snowflake/function_python.py +1212 -0
- pulumi_snowflake/function_scala.py +1212 -0
- pulumi_snowflake/function_sql.py +835 -0
- pulumi_snowflake/get_account_roles.py +129 -0
- pulumi_snowflake/get_accounts.py +53 -22
- pulumi_snowflake/get_alerts.py +22 -9
- pulumi_snowflake/get_connections.py +109 -0
- pulumi_snowflake/get_cortex_search_services.py +216 -0
- pulumi_snowflake/get_current_account.py +24 -13
- pulumi_snowflake/get_current_role.py +14 -7
- pulumi_snowflake/get_database.py +25 -9
- pulumi_snowflake/get_database_role.py +162 -0
- pulumi_snowflake/get_database_roles.py +79 -47
- pulumi_snowflake/get_databases.py +91 -73
- pulumi_snowflake/get_dynamic_tables.py +36 -19
- pulumi_snowflake/get_external_functions.py +28 -9
- pulumi_snowflake/get_external_tables.py +28 -9
- pulumi_snowflake/get_failover_groups.py +18 -7
- pulumi_snowflake/get_file_formats.py +28 -9
- pulumi_snowflake/get_functions.py +28 -9
- pulumi_snowflake/get_grants.py +207 -84
- pulumi_snowflake/get_masking_policies.py +91 -51
- pulumi_snowflake/get_materialized_views.py +28 -9
- pulumi_snowflake/get_network_policies.py +129 -0
- pulumi_snowflake/get_parameters.py +38 -15
- pulumi_snowflake/get_pipes.py +28 -9
- pulumi_snowflake/get_procedures.py +28 -9
- pulumi_snowflake/get_resource_monitors.py +37 -24
- pulumi_snowflake/get_row_access_policies.py +91 -51
- pulumi_snowflake/get_schemas.py +145 -41
- pulumi_snowflake/get_secrets.py +200 -0
- pulumi_snowflake/get_security_integrations.py +129 -0
- pulumi_snowflake/get_sequences.py +28 -9
- pulumi_snowflake/get_shares.py +18 -9
- pulumi_snowflake/get_stages.py +28 -9
- pulumi_snowflake/get_storage_integrations.py +16 -9
- pulumi_snowflake/get_streamlits.py +170 -0
- pulumi_snowflake/get_streams.py +114 -54
- pulumi_snowflake/get_system_generate_scim_access_token.py +18 -9
- pulumi_snowflake/get_system_get_aws_sns_iam_policy.py +32 -7
- pulumi_snowflake/get_system_get_private_link_config.py +120 -5
- pulumi_snowflake/get_system_get_snowflake_platform_info.py +15 -7
- pulumi_snowflake/get_tables.py +28 -9
- pulumi_snowflake/get_tags.py +130 -0
- pulumi_snowflake/get_tasks.py +134 -54
- pulumi_snowflake/get_users.py +116 -44
- pulumi_snowflake/get_views.py +114 -54
- pulumi_snowflake/get_warehouses.py +79 -26
- pulumi_snowflake/grant_account_role.py +28 -75
- pulumi_snowflake/grant_application_role.py +257 -0
- pulumi_snowflake/grant_database_role.py +35 -94
- pulumi_snowflake/grant_ownership.py +382 -0
- pulumi_snowflake/grant_privileges_to_account_role.py +42 -78
- pulumi_snowflake/grant_privileges_to_database_role.py +37 -383
- pulumi_snowflake/grant_privileges_to_share.py +96 -44
- pulumi_snowflake/legacy_service_user.py +3670 -0
- pulumi_snowflake/managed_account.py +40 -11
- pulumi_snowflake/masking_policy.py +213 -310
- pulumi_snowflake/materialized_view.py +62 -71
- pulumi_snowflake/network_policy.py +217 -61
- pulumi_snowflake/network_policy_attachment.py +5 -34
- pulumi_snowflake/network_rule.py +473 -0
- pulumi_snowflake/notification_integration.py +49 -84
- pulumi_snowflake/oauth_integration_for_custom_clients.py +906 -0
- pulumi_snowflake/{oauth_integration.py → oauth_integration_for_partner_applications.py} +191 -192
- pulumi_snowflake/object_parameter.py +10 -101
- pulumi_snowflake/outputs.py +49200 -2928
- pulumi_snowflake/password_policy.py +41 -28
- pulumi_snowflake/pipe.py +33 -4
- pulumi_snowflake/primary_connection.py +330 -0
- pulumi_snowflake/procedure_java.py +1273 -0
- pulumi_snowflake/procedure_javascript.py +895 -0
- pulumi_snowflake/procedure_python.py +1226 -0
- pulumi_snowflake/procedure_scala.py +1273 -0
- pulumi_snowflake/procedure_sql.py +895 -0
- pulumi_snowflake/provider.py +378 -613
- pulumi_snowflake/pulumi-plugin.json +2 -1
- pulumi_snowflake/resource_monitor.py +118 -327
- pulumi_snowflake/row_access_policy.py +200 -149
- pulumi_snowflake/{saml_integration.py → saml2_integration.py} +356 -299
- pulumi_snowflake/schema.py +949 -178
- pulumi_snowflake/scim_integration.py +286 -109
- pulumi_snowflake/secondary_connection.py +339 -0
- pulumi_snowflake/secondary_database.py +1080 -0
- pulumi_snowflake/secret_with_authorization_code_grant.py +548 -0
- pulumi_snowflake/secret_with_basic_authentication.py +500 -0
- pulumi_snowflake/secret_with_client_credentials.py +511 -0
- pulumi_snowflake/secret_with_generic_string.py +452 -0
- pulumi_snowflake/sequence.py +9 -34
- pulumi_snowflake/service_user.py +3585 -0
- pulumi_snowflake/share.py +33 -28
- pulumi_snowflake/shared_database.py +939 -0
- pulumi_snowflake/stage.py +95 -84
- pulumi_snowflake/storage_integration.py +46 -4
- pulumi_snowflake/stream_on_directory_table.py +517 -0
- pulumi_snowflake/stream_on_external_table.py +632 -0
- pulumi_snowflake/stream_on_table.py +666 -0
- pulumi_snowflake/stream_on_view.py +666 -0
- pulumi_snowflake/streamlit.py +671 -0
- pulumi_snowflake/table.py +86 -97
- pulumi_snowflake/table_column_masking_policy_application.py +7 -14
- pulumi_snowflake/table_constraint.py +29 -172
- pulumi_snowflake/tag.py +142 -74
- pulumi_snowflake/tag_association.py +40 -215
- pulumi_snowflake/task.py +3048 -418
- pulumi_snowflake/user.py +3351 -384
- pulumi_snowflake/user_authentication_policy_attachment.py +197 -0
- pulumi_snowflake/user_password_policy_attachment.py +5 -4
- pulumi_snowflake/user_public_keys.py +5 -0
- pulumi_snowflake/view.py +466 -215
- pulumi_snowflake/warehouse.py +184 -168
- {pulumi_snowflake-0.50.3a1710160126.dist-info → pulumi_snowflake-1.2.0a1736849992.dist-info}/METADATA +7 -6
- pulumi_snowflake-1.2.0a1736849992.dist-info/RECORD +148 -0
- {pulumi_snowflake-0.50.3a1710160126.dist-info → pulumi_snowflake-1.2.0a1736849992.dist-info}/WHEEL +1 -1
- pulumi_snowflake/account_grant.py +0 -343
- pulumi_snowflake/database_grant.py +0 -495
- pulumi_snowflake/external_table_grant.py +0 -690
- pulumi_snowflake/failover_group_grant.py +0 -388
- pulumi_snowflake/file_format_grant.py +0 -635
- pulumi_snowflake/function.py +0 -872
- pulumi_snowflake/function_grant.py +0 -745
- pulumi_snowflake/get_role.py +0 -121
- pulumi_snowflake/get_roles.py +0 -120
- pulumi_snowflake/grant_privileges_to_role.py +0 -825
- pulumi_snowflake/integration_grant.py +0 -440
- pulumi_snowflake/masking_policy_grant.py +0 -542
- pulumi_snowflake/materialized_view_grant.py +0 -689
- pulumi_snowflake/pipe_grant.py +0 -587
- pulumi_snowflake/procedure.py +0 -887
- pulumi_snowflake/procedure_grant.py +0 -745
- pulumi_snowflake/resource_monitor_grant.py +0 -387
- pulumi_snowflake/role.py +0 -273
- pulumi_snowflake/role_grants.py +0 -352
- pulumi_snowflake/role_ownership_grant.py +0 -338
- pulumi_snowflake/row_access_policy_grant.py +0 -540
- pulumi_snowflake/schema_grant.py +0 -647
- pulumi_snowflake/sequence_grant.py +0 -635
- pulumi_snowflake/session_parameter.py +0 -332
- pulumi_snowflake/stage_grant.py +0 -635
- pulumi_snowflake/stream.py +0 -614
- pulumi_snowflake/stream_grant.py +0 -635
- pulumi_snowflake/table_grant.py +0 -677
- pulumi_snowflake/tag_grant.py +0 -532
- pulumi_snowflake/tag_masking_policy_association.py +0 -210
- pulumi_snowflake/task_grant.py +0 -635
- pulumi_snowflake/user_grant.py +0 -394
- pulumi_snowflake/user_ownership_grant.py +0 -286
- pulumi_snowflake/view_grant.py +0 -705
- pulumi_snowflake/warehouse_grant.py +0 -440
- pulumi_snowflake-0.50.3a1710160126.dist-info/RECORD +0 -136
- {pulumi_snowflake-0.50.3a1710160126.dist-info → pulumi_snowflake-1.2.0a1736849992.dist-info}/top_level.txt +0 -0
|
@@ -4,9 +4,14 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
11
16
|
|
|
12
17
|
__all__ = [
|
|
@@ -82,20 +87,21 @@ class AwaitableGetCurrentAccountResult(GetCurrentAccountResult):
|
|
|
82
87
|
|
|
83
88
|
def get_current_account(opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetCurrentAccountResult:
|
|
84
89
|
"""
|
|
90
|
+
!> **Caution: Preview Feature** This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to `preview_features_enabled field` in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.
|
|
91
|
+
|
|
85
92
|
## Example Usage
|
|
86
93
|
|
|
87
|
-
<!--Start PulumiCodeChooser -->
|
|
88
94
|
```python
|
|
89
95
|
import pulumi
|
|
90
96
|
import pulumi_aws as aws
|
|
91
97
|
import pulumi_snowflake as snowflake
|
|
92
98
|
|
|
93
99
|
this = snowflake.get_current_account()
|
|
94
|
-
snowflake_account_url = aws.
|
|
95
|
-
|
|
100
|
+
snowflake_account_url = aws.index.SsmParameter("snowflake_account_url",
|
|
101
|
+
name=/snowflake/account_url,
|
|
102
|
+
type=String,
|
|
96
103
|
value=this.url)
|
|
97
104
|
```
|
|
98
|
-
<!--End PulumiCodeChooser -->
|
|
99
105
|
"""
|
|
100
106
|
__args__ = dict()
|
|
101
107
|
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
@@ -106,24 +112,29 @@ def get_current_account(opts: Optional[pulumi.InvokeOptions] = None) -> Awaitabl
|
|
|
106
112
|
id=pulumi.get(__ret__, 'id'),
|
|
107
113
|
region=pulumi.get(__ret__, 'region'),
|
|
108
114
|
url=pulumi.get(__ret__, 'url'))
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
@_utilities.lift_output_func(get_current_account)
|
|
112
|
-
def get_current_account_output(opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetCurrentAccountResult]:
|
|
115
|
+
def get_current_account_output(opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetCurrentAccountResult]:
|
|
113
116
|
"""
|
|
117
|
+
!> **Caution: Preview Feature** This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to `preview_features_enabled field` in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.
|
|
118
|
+
|
|
114
119
|
## Example Usage
|
|
115
120
|
|
|
116
|
-
<!--Start PulumiCodeChooser -->
|
|
117
121
|
```python
|
|
118
122
|
import pulumi
|
|
119
123
|
import pulumi_aws as aws
|
|
120
124
|
import pulumi_snowflake as snowflake
|
|
121
125
|
|
|
122
126
|
this = snowflake.get_current_account()
|
|
123
|
-
snowflake_account_url = aws.
|
|
124
|
-
|
|
127
|
+
snowflake_account_url = aws.index.SsmParameter("snowflake_account_url",
|
|
128
|
+
name=/snowflake/account_url,
|
|
129
|
+
type=String,
|
|
125
130
|
value=this.url)
|
|
126
131
|
```
|
|
127
|
-
<!--End PulumiCodeChooser -->
|
|
128
132
|
"""
|
|
129
|
-
|
|
133
|
+
__args__ = dict()
|
|
134
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
135
|
+
__ret__ = pulumi.runtime.invoke_output('snowflake:index/getCurrentAccount:getCurrentAccount', __args__, opts=opts, typ=GetCurrentAccountResult)
|
|
136
|
+
return __ret__.apply(lambda __response__: GetCurrentAccountResult(
|
|
137
|
+
account=pulumi.get(__response__, 'account'),
|
|
138
|
+
id=pulumi.get(__response__, 'id'),
|
|
139
|
+
region=pulumi.get(__response__, 'region'),
|
|
140
|
+
url=pulumi.get(__response__, 'url')))
|
|
@@ -4,9 +4,14 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
11
16
|
|
|
12
17
|
__all__ = [
|
|
@@ -58,7 +63,7 @@ class AwaitableGetCurrentRoleResult(GetCurrentRoleResult):
|
|
|
58
63
|
|
|
59
64
|
def get_current_role(opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetCurrentRoleResult:
|
|
60
65
|
"""
|
|
61
|
-
|
|
66
|
+
!> **Caution: Preview Feature** This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to `preview_features_enabled field` in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.
|
|
62
67
|
"""
|
|
63
68
|
__args__ = dict()
|
|
64
69
|
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
@@ -67,11 +72,13 @@ def get_current_role(opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGe
|
|
|
67
72
|
return AwaitableGetCurrentRoleResult(
|
|
68
73
|
id=pulumi.get(__ret__, 'id'),
|
|
69
74
|
name=pulumi.get(__ret__, 'name'))
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
@_utilities.lift_output_func(get_current_role)
|
|
73
|
-
def get_current_role_output(opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetCurrentRoleResult]:
|
|
75
|
+
def get_current_role_output(opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetCurrentRoleResult]:
|
|
74
76
|
"""
|
|
75
|
-
|
|
77
|
+
!> **Caution: Preview Feature** This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to `preview_features_enabled field` in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.
|
|
76
78
|
"""
|
|
77
|
-
|
|
79
|
+
__args__ = dict()
|
|
80
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
81
|
+
__ret__ = pulumi.runtime.invoke_output('snowflake:index/getCurrentRole:getCurrentRole', __args__, opts=opts, typ=GetCurrentRoleResult)
|
|
82
|
+
return __ret__.apply(lambda __response__: GetCurrentRoleResult(
|
|
83
|
+
id=pulumi.get(__response__, 'id'),
|
|
84
|
+
name=pulumi.get(__response__, 'name')))
|
pulumi_snowflake/get_database.py
CHANGED
|
@@ -4,9 +4,14 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
11
16
|
|
|
12
17
|
__all__ = [
|
|
@@ -131,16 +136,16 @@ class AwaitableGetDatabaseResult(GetDatabaseResult):
|
|
|
131
136
|
def get_database(name: Optional[str] = None,
|
|
132
137
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetDatabaseResult:
|
|
133
138
|
"""
|
|
139
|
+
!> **Caution: Preview Feature** This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to `preview_features_enabled field` in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.
|
|
140
|
+
|
|
134
141
|
## Example Usage
|
|
135
142
|
|
|
136
|
-
<!--Start PulumiCodeChooser -->
|
|
137
143
|
```python
|
|
138
144
|
import pulumi
|
|
139
145
|
import pulumi_snowflake as snowflake
|
|
140
146
|
|
|
141
147
|
this = snowflake.get_database(name="DEMO_DB")
|
|
142
148
|
```
|
|
143
|
-
<!--End PulumiCodeChooser -->
|
|
144
149
|
|
|
145
150
|
|
|
146
151
|
:param str name: The database from which to return its metadata.
|
|
@@ -161,24 +166,35 @@ def get_database(name: Optional[str] = None,
|
|
|
161
166
|
origin=pulumi.get(__ret__, 'origin'),
|
|
162
167
|
owner=pulumi.get(__ret__, 'owner'),
|
|
163
168
|
retention_time=pulumi.get(__ret__, 'retention_time'))
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
@_utilities.lift_output_func(get_database)
|
|
167
169
|
def get_database_output(name: Optional[pulumi.Input[str]] = None,
|
|
168
|
-
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetDatabaseResult]:
|
|
170
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDatabaseResult]:
|
|
169
171
|
"""
|
|
172
|
+
!> **Caution: Preview Feature** This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to `preview_features_enabled field` in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.
|
|
173
|
+
|
|
170
174
|
## Example Usage
|
|
171
175
|
|
|
172
|
-
<!--Start PulumiCodeChooser -->
|
|
173
176
|
```python
|
|
174
177
|
import pulumi
|
|
175
178
|
import pulumi_snowflake as snowflake
|
|
176
179
|
|
|
177
180
|
this = snowflake.get_database(name="DEMO_DB")
|
|
178
181
|
```
|
|
179
|
-
<!--End PulumiCodeChooser -->
|
|
180
182
|
|
|
181
183
|
|
|
182
184
|
:param str name: The database from which to return its metadata.
|
|
183
185
|
"""
|
|
184
|
-
|
|
186
|
+
__args__ = dict()
|
|
187
|
+
__args__['name'] = name
|
|
188
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
189
|
+
__ret__ = pulumi.runtime.invoke_output('snowflake:index/getDatabase:getDatabase', __args__, opts=opts, typ=GetDatabaseResult)
|
|
190
|
+
return __ret__.apply(lambda __response__: GetDatabaseResult(
|
|
191
|
+
comment=pulumi.get(__response__, 'comment'),
|
|
192
|
+
created_on=pulumi.get(__response__, 'created_on'),
|
|
193
|
+
id=pulumi.get(__response__, 'id'),
|
|
194
|
+
is_current=pulumi.get(__response__, 'is_current'),
|
|
195
|
+
is_default=pulumi.get(__response__, 'is_default'),
|
|
196
|
+
name=pulumi.get(__response__, 'name'),
|
|
197
|
+
options=pulumi.get(__response__, 'options'),
|
|
198
|
+
origin=pulumi.get(__response__, 'origin'),
|
|
199
|
+
owner=pulumi.get(__response__, 'owner'),
|
|
200
|
+
retention_time=pulumi.get(__response__, 'retention_time')))
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
|
|
3
|
+
# *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
|
+
|
|
5
|
+
import copy
|
|
6
|
+
import warnings
|
|
7
|
+
import sys
|
|
8
|
+
import pulumi
|
|
9
|
+
import pulumi.runtime
|
|
10
|
+
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
15
|
+
from . import _utilities
|
|
16
|
+
|
|
17
|
+
__all__ = [
|
|
18
|
+
'GetDatabaseRoleResult',
|
|
19
|
+
'AwaitableGetDatabaseRoleResult',
|
|
20
|
+
'get_database_role',
|
|
21
|
+
'get_database_role_output',
|
|
22
|
+
]
|
|
23
|
+
|
|
24
|
+
@pulumi.output_type
|
|
25
|
+
class GetDatabaseRoleResult:
|
|
26
|
+
"""
|
|
27
|
+
A collection of values returned by getDatabaseRole.
|
|
28
|
+
"""
|
|
29
|
+
def __init__(__self__, comment=None, database=None, id=None, name=None, owner=None):
|
|
30
|
+
if comment and not isinstance(comment, str):
|
|
31
|
+
raise TypeError("Expected argument 'comment' to be a str")
|
|
32
|
+
pulumi.set(__self__, "comment", comment)
|
|
33
|
+
if database and not isinstance(database, str):
|
|
34
|
+
raise TypeError("Expected argument 'database' to be a str")
|
|
35
|
+
pulumi.set(__self__, "database", database)
|
|
36
|
+
if id and not isinstance(id, str):
|
|
37
|
+
raise TypeError("Expected argument 'id' to be a str")
|
|
38
|
+
pulumi.set(__self__, "id", id)
|
|
39
|
+
if name and not isinstance(name, str):
|
|
40
|
+
raise TypeError("Expected argument 'name' to be a str")
|
|
41
|
+
pulumi.set(__self__, "name", name)
|
|
42
|
+
if owner and not isinstance(owner, str):
|
|
43
|
+
raise TypeError("Expected argument 'owner' to be a str")
|
|
44
|
+
pulumi.set(__self__, "owner", owner)
|
|
45
|
+
|
|
46
|
+
@property
|
|
47
|
+
@pulumi.getter
|
|
48
|
+
def comment(self) -> str:
|
|
49
|
+
"""
|
|
50
|
+
The comment on the role
|
|
51
|
+
"""
|
|
52
|
+
return pulumi.get(self, "comment")
|
|
53
|
+
|
|
54
|
+
@property
|
|
55
|
+
@pulumi.getter
|
|
56
|
+
def database(self) -> str:
|
|
57
|
+
"""
|
|
58
|
+
The database from which to return the database role from.
|
|
59
|
+
"""
|
|
60
|
+
return pulumi.get(self, "database")
|
|
61
|
+
|
|
62
|
+
@property
|
|
63
|
+
@pulumi.getter
|
|
64
|
+
def id(self) -> str:
|
|
65
|
+
"""
|
|
66
|
+
The provider-assigned unique ID for this managed resource.
|
|
67
|
+
"""
|
|
68
|
+
return pulumi.get(self, "id")
|
|
69
|
+
|
|
70
|
+
@property
|
|
71
|
+
@pulumi.getter
|
|
72
|
+
def name(self) -> str:
|
|
73
|
+
"""
|
|
74
|
+
Database role name.
|
|
75
|
+
"""
|
|
76
|
+
return pulumi.get(self, "name")
|
|
77
|
+
|
|
78
|
+
@property
|
|
79
|
+
@pulumi.getter
|
|
80
|
+
def owner(self) -> str:
|
|
81
|
+
"""
|
|
82
|
+
The owner of the role
|
|
83
|
+
"""
|
|
84
|
+
return pulumi.get(self, "owner")
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
class AwaitableGetDatabaseRoleResult(GetDatabaseRoleResult):
|
|
88
|
+
# pylint: disable=using-constant-test
|
|
89
|
+
def __await__(self):
|
|
90
|
+
if False:
|
|
91
|
+
yield self
|
|
92
|
+
return GetDatabaseRoleResult(
|
|
93
|
+
comment=self.comment,
|
|
94
|
+
database=self.database,
|
|
95
|
+
id=self.id,
|
|
96
|
+
name=self.name,
|
|
97
|
+
owner=self.owner)
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
def get_database_role(database: Optional[str] = None,
|
|
101
|
+
name: Optional[str] = None,
|
|
102
|
+
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetDatabaseRoleResult:
|
|
103
|
+
"""
|
|
104
|
+
!> **Caution: Preview Feature** This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to `preview_features_enabled field` in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.
|
|
105
|
+
|
|
106
|
+
## Example Usage
|
|
107
|
+
|
|
108
|
+
```python
|
|
109
|
+
import pulumi
|
|
110
|
+
import pulumi_snowflake as snowflake
|
|
111
|
+
|
|
112
|
+
db_role = snowflake.get_database_role(database="MYDB",
|
|
113
|
+
name="DBROLE")
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
:param str database: The database from which to return the database role from.
|
|
118
|
+
:param str name: Database role name.
|
|
119
|
+
"""
|
|
120
|
+
__args__ = dict()
|
|
121
|
+
__args__['database'] = database
|
|
122
|
+
__args__['name'] = name
|
|
123
|
+
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
124
|
+
__ret__ = pulumi.runtime.invoke('snowflake:index/getDatabaseRole:getDatabaseRole', __args__, opts=opts, typ=GetDatabaseRoleResult).value
|
|
125
|
+
|
|
126
|
+
return AwaitableGetDatabaseRoleResult(
|
|
127
|
+
comment=pulumi.get(__ret__, 'comment'),
|
|
128
|
+
database=pulumi.get(__ret__, 'database'),
|
|
129
|
+
id=pulumi.get(__ret__, 'id'),
|
|
130
|
+
name=pulumi.get(__ret__, 'name'),
|
|
131
|
+
owner=pulumi.get(__ret__, 'owner'))
|
|
132
|
+
def get_database_role_output(database: Optional[pulumi.Input[str]] = None,
|
|
133
|
+
name: Optional[pulumi.Input[str]] = None,
|
|
134
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDatabaseRoleResult]:
|
|
135
|
+
"""
|
|
136
|
+
!> **Caution: Preview Feature** This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to `preview_features_enabled field` in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.
|
|
137
|
+
|
|
138
|
+
## Example Usage
|
|
139
|
+
|
|
140
|
+
```python
|
|
141
|
+
import pulumi
|
|
142
|
+
import pulumi_snowflake as snowflake
|
|
143
|
+
|
|
144
|
+
db_role = snowflake.get_database_role(database="MYDB",
|
|
145
|
+
name="DBROLE")
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
:param str database: The database from which to return the database role from.
|
|
150
|
+
:param str name: Database role name.
|
|
151
|
+
"""
|
|
152
|
+
__args__ = dict()
|
|
153
|
+
__args__['database'] = database
|
|
154
|
+
__args__['name'] = name
|
|
155
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
156
|
+
__ret__ = pulumi.runtime.invoke_output('snowflake:index/getDatabaseRole:getDatabaseRole', __args__, opts=opts, typ=GetDatabaseRoleResult)
|
|
157
|
+
return __ret__.apply(lambda __response__: GetDatabaseRoleResult(
|
|
158
|
+
comment=pulumi.get(__response__, 'comment'),
|
|
159
|
+
database=pulumi.get(__response__, 'database'),
|
|
160
|
+
id=pulumi.get(__response__, 'id'),
|
|
161
|
+
name=pulumi.get(__response__, 'name'),
|
|
162
|
+
owner=pulumi.get(__response__, 'owner')))
|
|
@@ -4,11 +4,17 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
11
16
|
from . import outputs
|
|
17
|
+
from ._inputs import *
|
|
12
18
|
|
|
13
19
|
__all__ = [
|
|
14
20
|
'GetDatabaseRolesResult',
|
|
@@ -22,30 +28,28 @@ class GetDatabaseRolesResult:
|
|
|
22
28
|
"""
|
|
23
29
|
A collection of values returned by getDatabaseRoles.
|
|
24
30
|
"""
|
|
25
|
-
def __init__(__self__,
|
|
26
|
-
if database and not isinstance(database, str):
|
|
27
|
-
raise TypeError("Expected argument 'database' to be a str")
|
|
28
|
-
pulumi.set(__self__, "database", database)
|
|
31
|
+
def __init__(__self__, database_roles=None, id=None, in_database=None, like=None, limit=None):
|
|
29
32
|
if database_roles and not isinstance(database_roles, list):
|
|
30
33
|
raise TypeError("Expected argument 'database_roles' to be a list")
|
|
31
34
|
pulumi.set(__self__, "database_roles", database_roles)
|
|
32
35
|
if id and not isinstance(id, str):
|
|
33
36
|
raise TypeError("Expected argument 'id' to be a str")
|
|
34
37
|
pulumi.set(__self__, "id", id)
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
38
|
+
if in_database and not isinstance(in_database, str):
|
|
39
|
+
raise TypeError("Expected argument 'in_database' to be a str")
|
|
40
|
+
pulumi.set(__self__, "in_database", in_database)
|
|
41
|
+
if like and not isinstance(like, str):
|
|
42
|
+
raise TypeError("Expected argument 'like' to be a str")
|
|
43
|
+
pulumi.set(__self__, "like", like)
|
|
44
|
+
if limit and not isinstance(limit, dict):
|
|
45
|
+
raise TypeError("Expected argument 'limit' to be a dict")
|
|
46
|
+
pulumi.set(__self__, "limit", limit)
|
|
43
47
|
|
|
44
48
|
@property
|
|
45
49
|
@pulumi.getter(name="databaseRoles")
|
|
46
50
|
def database_roles(self) -> Sequence['outputs.GetDatabaseRolesDatabaseRoleResult']:
|
|
47
51
|
"""
|
|
48
|
-
|
|
52
|
+
Holds the aggregated output of all database role details queries.
|
|
49
53
|
"""
|
|
50
54
|
return pulumi.get(self, "database_roles")
|
|
51
55
|
|
|
@@ -57,6 +61,30 @@ class GetDatabaseRolesResult:
|
|
|
57
61
|
"""
|
|
58
62
|
return pulumi.get(self, "id")
|
|
59
63
|
|
|
64
|
+
@property
|
|
65
|
+
@pulumi.getter(name="inDatabase")
|
|
66
|
+
def in_database(self) -> str:
|
|
67
|
+
"""
|
|
68
|
+
The database from which to return the database roles from.
|
|
69
|
+
"""
|
|
70
|
+
return pulumi.get(self, "in_database")
|
|
71
|
+
|
|
72
|
+
@property
|
|
73
|
+
@pulumi.getter
|
|
74
|
+
def like(self) -> Optional[str]:
|
|
75
|
+
"""
|
|
76
|
+
Filters the output with **case-insensitive** pattern, with support for SQL wildcard characters (`%` and `_`).
|
|
77
|
+
"""
|
|
78
|
+
return pulumi.get(self, "like")
|
|
79
|
+
|
|
80
|
+
@property
|
|
81
|
+
@pulumi.getter
|
|
82
|
+
def limit(self) -> Optional['outputs.GetDatabaseRolesLimitResult']:
|
|
83
|
+
"""
|
|
84
|
+
Limits the number of rows returned. If the `limit.from` is set, then the limit wll start from the first element matched by the expression. The expression is only used to match with the first element, later on the elements are not matched by the prefix, but you can enforce a certain pattern with `starts_with` or `like`.
|
|
85
|
+
"""
|
|
86
|
+
return pulumi.get(self, "limit")
|
|
87
|
+
|
|
60
88
|
|
|
61
89
|
class AwaitableGetDatabaseRolesResult(GetDatabaseRolesResult):
|
|
62
90
|
# pylint: disable=using-constant-test
|
|
@@ -64,55 +92,59 @@ class AwaitableGetDatabaseRolesResult(GetDatabaseRolesResult):
|
|
|
64
92
|
if False:
|
|
65
93
|
yield self
|
|
66
94
|
return GetDatabaseRolesResult(
|
|
67
|
-
database=self.database,
|
|
68
95
|
database_roles=self.database_roles,
|
|
69
|
-
id=self.id
|
|
96
|
+
id=self.id,
|
|
97
|
+
in_database=self.in_database,
|
|
98
|
+
like=self.like,
|
|
99
|
+
limit=self.limit)
|
|
70
100
|
|
|
71
101
|
|
|
72
|
-
def get_database_roles(
|
|
102
|
+
def get_database_roles(in_database: Optional[str] = None,
|
|
103
|
+
like: Optional[str] = None,
|
|
104
|
+
limit: Optional[Union['GetDatabaseRolesLimitArgs', 'GetDatabaseRolesLimitArgsDict']] = None,
|
|
73
105
|
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetDatabaseRolesResult:
|
|
74
106
|
"""
|
|
75
|
-
|
|
107
|
+
Data source used to get details of filtered database roles. Filtering is aligned with the current possibilities for [SHOW DATABASE ROLES](https://docs.snowflake.com/en/sql-reference/sql/show-database-roles) query (`like` and `limit` are supported). The results of SHOW is encapsulated in show_output collection.
|
|
76
108
|
|
|
77
|
-
<!--Start PulumiCodeChooser -->
|
|
78
|
-
```python
|
|
79
|
-
import pulumi
|
|
80
|
-
import pulumi_snowflake as snowflake
|
|
81
109
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
:param str database: The database from which to return the database roles from.
|
|
110
|
+
:param str in_database: The database from which to return the database roles from.
|
|
111
|
+
:param str like: Filters the output with **case-insensitive** pattern, with support for SQL wildcard characters (`%` and `_`).
|
|
112
|
+
:param Union['GetDatabaseRolesLimitArgs', 'GetDatabaseRolesLimitArgsDict'] limit: Limits the number of rows returned. If the `limit.from` is set, then the limit wll start from the first element matched by the expression. The expression is only used to match with the first element, later on the elements are not matched by the prefix, but you can enforce a certain pattern with `starts_with` or `like`.
|
|
88
113
|
"""
|
|
89
114
|
__args__ = dict()
|
|
90
|
-
__args__['
|
|
115
|
+
__args__['inDatabase'] = in_database
|
|
116
|
+
__args__['like'] = like
|
|
117
|
+
__args__['limit'] = limit
|
|
91
118
|
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
92
119
|
__ret__ = pulumi.runtime.invoke('snowflake:index/getDatabaseRoles:getDatabaseRoles', __args__, opts=opts, typ=GetDatabaseRolesResult).value
|
|
93
120
|
|
|
94
121
|
return AwaitableGetDatabaseRolesResult(
|
|
95
|
-
database=pulumi.get(__ret__, 'database'),
|
|
96
122
|
database_roles=pulumi.get(__ret__, 'database_roles'),
|
|
97
|
-
id=pulumi.get(__ret__, 'id')
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
def get_database_roles_output(
|
|
102
|
-
|
|
123
|
+
id=pulumi.get(__ret__, 'id'),
|
|
124
|
+
in_database=pulumi.get(__ret__, 'in_database'),
|
|
125
|
+
like=pulumi.get(__ret__, 'like'),
|
|
126
|
+
limit=pulumi.get(__ret__, 'limit'))
|
|
127
|
+
def get_database_roles_output(in_database: Optional[pulumi.Input[str]] = None,
|
|
128
|
+
like: Optional[pulumi.Input[Optional[str]]] = None,
|
|
129
|
+
limit: Optional[pulumi.Input[Optional[Union['GetDatabaseRolesLimitArgs', 'GetDatabaseRolesLimitArgsDict']]]] = None,
|
|
130
|
+
opts: Optional[Union[pulumi.InvokeOptions, pulumi.InvokeOutputOptions]] = None) -> pulumi.Output[GetDatabaseRolesResult]:
|
|
103
131
|
"""
|
|
104
|
-
|
|
132
|
+
Data source used to get details of filtered database roles. Filtering is aligned with the current possibilities for [SHOW DATABASE ROLES](https://docs.snowflake.com/en/sql-reference/sql/show-database-roles) query (`like` and `limit` are supported). The results of SHOW is encapsulated in show_output collection.
|
|
105
133
|
|
|
106
|
-
<!--Start PulumiCodeChooser -->
|
|
107
|
-
```python
|
|
108
|
-
import pulumi
|
|
109
|
-
import pulumi_snowflake as snowflake
|
|
110
134
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
:param str database: The database from which to return the database roles from.
|
|
135
|
+
:param str in_database: The database from which to return the database roles from.
|
|
136
|
+
:param str like: Filters the output with **case-insensitive** pattern, with support for SQL wildcard characters (`%` and `_`).
|
|
137
|
+
:param Union['GetDatabaseRolesLimitArgs', 'GetDatabaseRolesLimitArgsDict'] limit: Limits the number of rows returned. If the `limit.from` is set, then the limit wll start from the first element matched by the expression. The expression is only used to match with the first element, later on the elements are not matched by the prefix, but you can enforce a certain pattern with `starts_with` or `like`.
|
|
117
138
|
"""
|
|
118
|
-
|
|
139
|
+
__args__ = dict()
|
|
140
|
+
__args__['inDatabase'] = in_database
|
|
141
|
+
__args__['like'] = like
|
|
142
|
+
__args__['limit'] = limit
|
|
143
|
+
opts = pulumi.InvokeOutputOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
144
|
+
__ret__ = pulumi.runtime.invoke_output('snowflake:index/getDatabaseRoles:getDatabaseRoles', __args__, opts=opts, typ=GetDatabaseRolesResult)
|
|
145
|
+
return __ret__.apply(lambda __response__: GetDatabaseRolesResult(
|
|
146
|
+
database_roles=pulumi.get(__response__, 'database_roles'),
|
|
147
|
+
id=pulumi.get(__response__, 'id'),
|
|
148
|
+
in_database=pulumi.get(__response__, 'in_database'),
|
|
149
|
+
like=pulumi.get(__response__, 'like'),
|
|
150
|
+
limit=pulumi.get(__response__, 'limit')))
|