4
4
from attrs import field as _attrs_field
5
5
6
6
from ..models .aws_authentication_mode import AwsAuthenticationMode
7
+ from ..models .azure_authentication_mode import AzureAuthenticationMode
7
8
from ..models .duckdb_files_format_type import DuckdbFilesFormatType
8
9
from ..models .duckdb_read_mode import DuckdbReadMode
9
10
from ..models .duckdb_storage_type import DuckdbStorageType
@@ -41,12 +42,21 @@ class DuckdbParametersSpec:
41
42
must be an absolute path.
42
43
storage_type (Union[Unset, DuckdbStorageType]):
43
44
aws_authentication_mode (Union[Unset, AwsAuthenticationMode]):
45
+ azure_authentication_mode (Union[Unset, AzureAuthenticationMode]):
44
46
user (Union[Unset, str]): DuckDB user name for a remote storage type. The value can be in the
45
47
${ENVIRONMENT_VARIABLE_NAME} format to use dynamic substitution.
46
48
password (Union[Unset, str]): DuckDB password for a remote storage type. The value can be in the
47
49
${ENVIRONMENT_VARIABLE_NAME} format to use dynamic substitution.
48
50
region (Union[Unset, str]): The region for the storage credentials. The value can be in the
49
51
${ENVIRONMENT_VARIABLE_NAME} format to use dynamic substitution.
52
+ tenant_id (Union[Unset, str]): Azure Tenant ID used by DuckDB Secret Manager. The value can be in the
53
+ ${ENVIRONMENT_VARIABLE_NAME} format to use dynamic substitution.
54
+ client_id (Union[Unset, str]): Azure Client ID used by DuckDB Secret Manager. The value can be in the
55
+ ${ENVIRONMENT_VARIABLE_NAME} format to use dynamic substitution.
56
+ client_secret (Union[Unset, str]): Azure Client Secret used by DuckDB Secret Manager. The value can be in the
57
+ ${ENVIRONMENT_VARIABLE_NAME} format to use dynamic substitution.
58
+ account_name (Union[Unset, str]): Azure Storage Account Name used by DuckDB Secret Manager. The value can be in
59
+ the ${ENVIRONMENT_VARIABLE_NAME} format to use dynamic substitution.
50
60
"""
51
61
52
62
read_mode : Union [Unset , DuckdbReadMode ] = UNSET
@@ -59,9 +69,14 @@ class DuckdbParametersSpec:
59
69
directories : Union [Unset , "DuckdbParametersSpecDirectories" ] = UNSET
60
70
storage_type : Union [Unset , DuckdbStorageType ] = UNSET
61
71
aws_authentication_mode : Union [Unset , AwsAuthenticationMode ] = UNSET
72
+ azure_authentication_mode : Union [Unset , AzureAuthenticationMode ] = UNSET
62
73
user : Union [Unset , str ] = UNSET
63
74
password : Union [Unset , str ] = UNSET
64
75
region : Union [Unset , str ] = UNSET
76
+ tenant_id : Union [Unset , str ] = UNSET
77
+ client_id : Union [Unset , str ] = UNSET
78
+ client_secret : Union [Unset , str ] = UNSET
79
+ account_name : Union [Unset , str ] = UNSET
65
80
additional_properties : Dict [str , Any ] = _attrs_field (init = False , factory = dict )
66
81
67
82
def to_dict (self ) -> Dict [str , Any ]:
@@ -102,9 +117,17 @@ def to_dict(self) -> Dict[str, Any]:
102
117
if not isinstance (self .aws_authentication_mode , Unset ):
103
118
aws_authentication_mode = self .aws_authentication_mode .value
104
119
120
+ azure_authentication_mode : Union [Unset , str ] = UNSET
121
+ if not isinstance (self .azure_authentication_mode , Unset ):
122
+ azure_authentication_mode = self .azure_authentication_mode .value
123
+
105
124
user = self .user
106
125
password = self .password
107
126
region = self .region
127
+ tenant_id = self .tenant_id
128
+ client_id = self .client_id
129
+ client_secret = self .client_secret
130
+ account_name = self .account_name
108
131
109
132
field_dict : Dict [str , Any ] = {}
110
133
field_dict .update (self .additional_properties )
@@ -129,12 +152,22 @@ def to_dict(self) -> Dict[str, Any]:
129
152
field_dict ["storage_type" ] = storage_type
130
153
if aws_authentication_mode is not UNSET :
131
154
field_dict ["aws_authentication_mode" ] = aws_authentication_mode
155
+ if azure_authentication_mode is not UNSET :
156
+ field_dict ["azure_authentication_mode" ] = azure_authentication_mode
132
157
if user is not UNSET :
133
158
field_dict ["user" ] = user
134
159
if password is not UNSET :
135
160
field_dict ["password" ] = password
136
161
if region is not UNSET :
137
162
field_dict ["region" ] = region
163
+ if tenant_id is not UNSET :
164
+ field_dict ["tenant_id" ] = tenant_id
165
+ if client_id is not UNSET :
166
+ field_dict ["client_id" ] = client_id
167
+ if client_secret is not UNSET :
168
+ field_dict ["client_secret" ] = client_secret
169
+ if account_name is not UNSET :
170
+ field_dict ["account_name" ] = account_name
138
171
139
172
return field_dict
140
173
@@ -216,12 +249,29 @@ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
216
249
else :
217
250
aws_authentication_mode = AwsAuthenticationMode (_aws_authentication_mode )
218
251
252
+ _azure_authentication_mode = d .pop ("azure_authentication_mode" , UNSET )
253
+ azure_authentication_mode : Union [Unset , AzureAuthenticationMode ]
254
+ if isinstance (_azure_authentication_mode , Unset ):
255
+ azure_authentication_mode = UNSET
256
+ else :
257
+ azure_authentication_mode = AzureAuthenticationMode (
258
+ _azure_authentication_mode
259
+ )
260
+
219
261
user = d .pop ("user" , UNSET )
220
262
221
263
password = d .pop ("password" , UNSET )
222
264
223
265
region = d .pop ("region" , UNSET )
224
266
267
+ tenant_id = d .pop ("tenant_id" , UNSET )
268
+
269
+ client_id = d .pop ("client_id" , UNSET )
270
+
271
+ client_secret = d .pop ("client_secret" , UNSET )
272
+
273
+ account_name = d .pop ("account_name" , UNSET )
274
+
225
275
duckdb_parameters_spec = cls (
226
276
read_mode = read_mode ,
227
277
files_format_type = files_format_type ,
@@ -233,9 +283,14 @@ def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
233
283
directories = directories ,
234
284
storage_type = storage_type ,
235
285
aws_authentication_mode = aws_authentication_mode ,
286
+ azure_authentication_mode = azure_authentication_mode ,
236
287
user = user ,
237
288
password = password ,
238
289
region = region ,
290
+ tenant_id = tenant_id ,
291
+ client_id = client_id ,
292
+ client_secret = client_secret ,
293
+ account_name = account_name ,
239
294
)
240
295
241
296
duckdb_parameters_spec .additional_properties = d
0 commit comments