singlestoredb 1.8.0__cp38-abi3-win_amd64.whl → 1.9.0__cp38-abi3-win_amd64.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 singlestoredb might be problematic. Click here for more details.
- _singlestoredb_accel.pyd +0 -0
- singlestoredb/__init__.py +2 -2
- singlestoredb/config.py +6 -0
- singlestoredb/connection.py +11 -0
- singlestoredb/fusion/handler.py +3 -0
- singlestoredb/fusion/handlers/export.py +6 -14
- singlestoredb/fusion/handlers/files.py +690 -0
- singlestoredb/fusion/handlers/stage.py +103 -91
- singlestoredb/fusion/handlers/utils.py +148 -0
- singlestoredb/management/__init__.py +1 -0
- singlestoredb/management/export.py +20 -184
- singlestoredb/management/files.py +1038 -0
- singlestoredb/management/workspace.py +162 -349
- singlestoredb/mysql/connection.py +9 -1
- singlestoredb/tests/test.ipynb +18 -0
- singlestoredb/tests/test2.ipynb +18 -0
- singlestoredb/tests/test_management.py +273 -1
- {singlestoredb-1.8.0.dist-info → singlestoredb-1.9.0.dist-info}/METADATA +1 -1
- {singlestoredb-1.8.0.dist-info → singlestoredb-1.9.0.dist-info}/RECORD +25 -19
- {singlestoredb-1.8.0.dist-info → singlestoredb-1.9.0.dist-info}/top_level.txt +1 -0
- sqlx/__init__.py +4 -0
- sqlx/magic.py +113 -0
- {singlestoredb-1.8.0.dist-info → singlestoredb-1.9.0.dist-info}/LICENSE +0 -0
- {singlestoredb-1.8.0.dist-info → singlestoredb-1.9.0.dist-info}/WHEEL +0 -0
- {singlestoredb-1.8.0.dist-info → singlestoredb-1.9.0.dist-info}/entry_points.txt +0 -0
_singlestoredb_accel.pyd
CHANGED
|
Binary file
|
singlestoredb/__init__.py
CHANGED
|
@@ -13,7 +13,7 @@ Examples
|
|
|
13
13
|
|
|
14
14
|
"""
|
|
15
15
|
|
|
16
|
-
__version__ = '1.
|
|
16
|
+
__version__ = '1.9.0'
|
|
17
17
|
|
|
18
18
|
from typing import Any
|
|
19
19
|
|
|
@@ -25,7 +25,7 @@ from .exceptions import (
|
|
|
25
25
|
DataError, ManagementError,
|
|
26
26
|
)
|
|
27
27
|
from .management import (
|
|
28
|
-
manage_cluster, manage_workspaces,
|
|
28
|
+
manage_cluster, manage_workspaces, manage_files,
|
|
29
29
|
)
|
|
30
30
|
from .types import (
|
|
31
31
|
Date, Time, Timestamp, DateFromTicks, TimeFromTicks, TimestampFromTicks,
|
singlestoredb/config.py
CHANGED
|
@@ -134,6 +134,12 @@ register_option(
|
|
|
134
134
|
environ='SINGLESTOREDB_SSL_CIPHER',
|
|
135
135
|
)
|
|
136
136
|
|
|
137
|
+
register_option(
|
|
138
|
+
'tls_sni_servername', 'str', check_str, None,
|
|
139
|
+
'Sets TLS SNI servername',
|
|
140
|
+
environ='SINGLESTOREDB_TLS_SNI_SERVERNAME',
|
|
141
|
+
)
|
|
142
|
+
|
|
137
143
|
register_option(
|
|
138
144
|
'ssl_disabled', 'bool', check_bool, False,
|
|
139
145
|
'Disable SSL usage',
|
singlestoredb/connection.py
CHANGED
|
@@ -20,6 +20,7 @@ from typing import Sequence
|
|
|
20
20
|
from typing import Tuple
|
|
21
21
|
from typing import Union
|
|
22
22
|
from urllib.parse import parse_qs
|
|
23
|
+
from urllib.parse import unquote_plus
|
|
23
24
|
from urllib.parse import urlparse
|
|
24
25
|
|
|
25
26
|
import sqlparams
|
|
@@ -284,6 +285,15 @@ def _parse_url(url: str) -> Dict[str, Any]:
|
|
|
284
285
|
if parts.scheme != 'singlestoredb':
|
|
285
286
|
out['driver'] = parts.scheme.lower()
|
|
286
287
|
|
|
288
|
+
if out.get('user'):
|
|
289
|
+
out['user'] = unquote_plus(out['user'])
|
|
290
|
+
|
|
291
|
+
if out.get('password'):
|
|
292
|
+
out['password'] = unquote_plus(out['password'])
|
|
293
|
+
|
|
294
|
+
if out.get('database'):
|
|
295
|
+
out['database'] = unquote_plus(out['database'])
|
|
296
|
+
|
|
287
297
|
# Convert query string to parameters
|
|
288
298
|
out.update({k.lower(): v[-1] for k, v in parse_qs(parts.query).items()})
|
|
289
299
|
|
|
@@ -1288,6 +1298,7 @@ def connect(
|
|
|
1288
1298
|
ssl_key: Optional[str] = None, ssl_cert: Optional[str] = None,
|
|
1289
1299
|
ssl_ca: Optional[str] = None, ssl_disabled: Optional[bool] = None,
|
|
1290
1300
|
ssl_cipher: Optional[str] = None, ssl_verify_cert: Optional[bool] = None,
|
|
1301
|
+
tls_sni_servername: Optional[str] = None,
|
|
1291
1302
|
ssl_verify_identity: Optional[bool] = None,
|
|
1292
1303
|
conv: Optional[Dict[int, Callable[..., Any]]] = None,
|
|
1293
1304
|
credential_type: Optional[str] = None,
|
singlestoredb/fusion/handler.py
CHANGED
|
@@ -5,10 +5,8 @@ from typing import Dict
|
|
|
5
5
|
from typing import Optional
|
|
6
6
|
|
|
7
7
|
from .. import result
|
|
8
|
-
from ...management.export import Catalog
|
|
9
8
|
from ...management.export import ExportService
|
|
10
9
|
from ...management.export import ExportStatus
|
|
11
|
-
from ...management.export import Link
|
|
12
10
|
from ..handler import SQLHandler
|
|
13
11
|
from ..result import FusionSQLResult
|
|
14
12
|
from .utils import get_workspace_group
|
|
@@ -71,8 +69,6 @@ class CreateClusterIdentity(SQLHandler):
|
|
|
71
69
|
|
|
72
70
|
"""
|
|
73
71
|
|
|
74
|
-
_enabled = False
|
|
75
|
-
|
|
76
72
|
def run(self, params: Dict[str, Any]) -> Optional[FusionSQLResult]:
|
|
77
73
|
# Catalog
|
|
78
74
|
catalog_config = json.loads(params['catalog'].get('catalog_config', '{}') or '{}')
|
|
@@ -91,14 +87,14 @@ class CreateClusterIdentity(SQLHandler):
|
|
|
91
87
|
wsg,
|
|
92
88
|
'none',
|
|
93
89
|
'none',
|
|
94
|
-
|
|
95
|
-
|
|
90
|
+
dict(**catalog_config, **catalog_creds),
|
|
91
|
+
dict(**storage_config, **storage_creds),
|
|
96
92
|
columns=None,
|
|
97
93
|
).create_cluster_identity()
|
|
98
94
|
|
|
99
95
|
res = FusionSQLResult()
|
|
100
|
-
res.add_field('
|
|
101
|
-
res.set_rows([(out['
|
|
96
|
+
res.add_field('Identity', result.STRING)
|
|
97
|
+
res.set_rows([(out['identity'],)])
|
|
102
98
|
|
|
103
99
|
return res
|
|
104
100
|
|
|
@@ -165,8 +161,6 @@ class CreateExport(SQLHandler):
|
|
|
165
161
|
|
|
166
162
|
""" # noqa
|
|
167
163
|
|
|
168
|
-
_enabled = False
|
|
169
|
-
|
|
170
164
|
def run(self, params: Dict[str, Any]) -> Optional[FusionSQLResult]:
|
|
171
165
|
# From table
|
|
172
166
|
if isinstance(params['from_table'], str):
|
|
@@ -195,8 +189,8 @@ class CreateExport(SQLHandler):
|
|
|
195
189
|
wsg,
|
|
196
190
|
from_database,
|
|
197
191
|
from_table,
|
|
198
|
-
|
|
199
|
-
|
|
192
|
+
dict(**catalog_config, **catalog_creds),
|
|
193
|
+
dict(**storage_config, **storage_creds),
|
|
200
194
|
columns=None,
|
|
201
195
|
).start()
|
|
202
196
|
|
|
@@ -219,8 +213,6 @@ class ShowExport(SQLHandler):
|
|
|
219
213
|
|
|
220
214
|
"""
|
|
221
215
|
|
|
222
|
-
_enabled = False
|
|
223
|
-
|
|
224
216
|
def run(self, params: Dict[str, Any]) -> Optional[FusionSQLResult]:
|
|
225
217
|
wsg = get_workspace_group({})
|
|
226
218
|
out = ExportStatus(params['export_id'], wsg)
|