Skip to content

Commit 0025841

Browse files
authored
Merge pull request #390 from keboola/pepa_PAT-255_keyPair
[staging-provider] Snowflake key-pair support
2 parents 273efcb + 4136922 commit 0025841

File tree

4 files changed

+23
-12
lines changed

4 files changed

+23
-12
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"php": ">=8.2",
1414
"ext-json": "*",
1515
"keboola/php-file-storage-utils": "^0.2",
16-
"keboola/storage-api-client": "^15.0|^16.0|^17.0",
16+
"keboola/storage-api-client": "^18.0",
1717
"keboola/storage-api-php-client-branch-wrapper": "^6.0",
1818
"symfony/config": "^5.4|^6.0|^7.0",
1919
"symfony/finder": "^5.4|^6.0|^7.0",

src/Staging/AbstractStrategyFactory.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,16 @@ abstract class AbstractStrategyFactory
2121
public const WORKSPACE_TERADATA = 'workspace-teradata';
2222
public const WORKSPACE_BIGQUERY = 'workspace-bigquery';
2323

24+
public const WORKSPACE_TYPES = [
25+
self::WORKSPACE_ABS,
26+
self::WORKSPACE_REDSHIFT,
27+
self::WORKSPACE_SNOWFLAKE,
28+
self::WORKSPACE_SYNAPSE,
29+
self::WORKSPACE_EXASOL,
30+
self::WORKSPACE_TERADATA,
31+
self::WORKSPACE_BIGQUERY,
32+
];
33+
2434
public function __construct(
2535
protected readonly ClientWrapper $clientWrapper,
2636
protected readonly LoggerInterface $logger,

src/Staging/ProviderInterface.php

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,16 +12,17 @@ public function cleanup(): void;
1212

1313
/**
1414
* @return array{
15-
* container?: string,
16-
* connectionString?: string,
17-
* host?: string,
18-
* warehouse?: string,
19-
* database?: string,
20-
* schema?: string,
21-
* user?: string,
22-
* password?: string,
23-
* account?: string,
24-
* credentials?: array,
15+
* container?: string|null,
16+
* connectionString?: string|null,
17+
* host?: string|null,
18+
* warehouse?: string|null,
19+
* database?: string|null,
20+
* schema?: string|null,
21+
* user?: string|null,
22+
* password?: string|null,
23+
* privateKey?: string|null,
24+
* account?: string|null,
25+
* credentials?: array|null,
2526
* }
2627
*/
2728
public function getCredentials(): array;

tests/Functional/DownloadTablesWorkspaceSnowflakeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ public function testTablesSnowflakeDataTypesInvalid(): void
307307

308308
$this->expectException(ClientException::class);
309309
$this->expectExceptionMessage(
310-
'odbc_execute(): SQL error: Numeric value \'id2\' is not recognized',
310+
'Numeric value \'id2\' is not recognized',
311311
);
312312
$reader->downloadTables(
313313
$configuration,

0 commit comments

Comments
 (0)