Commit Graph

58 Commits

Author SHA1 Message Date
Raúl Marín
9010642326 Revert "Revert 0.33.0"
This reverts commit 24cb6cf9c1.
2019-12-24 00:33:35 +01:00
Raúl Marín
24cb6cf9c1 Revert 0.33.0 2019-12-23 20:23:02 +01:00
Raul Marin
82d8f7e1aa Deprecate FDW user setup ;__( 2019-11-06 18:26:37 +01:00
Raul Marin
164fba197f test_foreign_tables: Better debugging and query the default database when needed 2019-10-24 12:35:46 +02:00
Raul Marin
5a12033609 Adapt tests to changes 2019-10-03 18:58:27 +02:00
Rafa de la Torre
e41d2ec019 Add a flag to force drop of user FDW and related objects
If force = true then it will add the subclause `CASCADE` to the SQL
DDL sentences that support it, otherwise it'll use `RESTRICT` which is
the default and exact opposite.
2019-07-16 17:40:05 +02:00
Rafa de la Torre
076207c49c Make sure there are no (double)escaping issues 2019-07-16 16:24:02 +02:00
Rafa de la Torre
ce1e9ac41c Prefix all objects created with cdb_fdw_
Build the DB objects related to a user FDW with the following form:
`cdb_fdw_name`. This is aimed at easily inspect and filter them.

As requested in code review.
2019-07-16 15:35:35 +02:00
Rafa de la Torre
0f33ee8b22 Prepend an underscore (_) to functions meant to be run by superuser
_CDB_SetUp_User_PG_FDW_Server and _CDB_Drop_User_PG_FDW_Server are
meant to be executed by a superuser. Therefore they shouldn't be
considered part of the public API and hence the _CDB_Private_Function
naming convention.
2019-07-16 14:32:32 +02:00
Rafa de la Torre
a32dea0282 Remove SECURITY DEFINER from user-defined FDW's 2019-07-16 13:26:03 +02:00
Rafa de la Torre
3a255df9d0 Rename PG-FDW's-specific functions to _PG_FDW_
As per review comment.
2019-07-16 13:14:11 +02:00
Rafa de la Torre
c4e2549dc8 A few more permissions tests for completeness 2019-07-15 18:14:23 +02:00
Rafa de la Torre
2e9f642378 Check when users shall not have permissions to the FDW 2019-07-15 17:32:48 +02:00
Rafa de la Torre
99096d41e0 Drop the role when dropping a user-defined FDW 2019-07-15 17:25:48 +02:00
Rafa de la Torre
3a10ef7e76 Add ability to grant fdw role to org members 2019-07-15 16:54:23 +02:00
Rafa de la Torre
a20676f391 Add a test/example of granting the fdw role 2019-07-15 16:19:06 +02:00
Rafa de la Torre
37004db047 Add new function to drop a user-defined foreign server 2019-07-15 16:14:07 +02:00
Rafa de la Torre
8cfc8e65cf Test with a regular user (non-superadmin) 2019-07-15 14:44:21 +02:00
Rafa de la Torre
6e34e16b8d Add basic test for user-defined FDW's 2019-07-15 13:16:14 +02:00
Rafa de la Torre
d378ca6fe0 Test for missing foreign CDB_TableMetadata 2019-07-03 16:25:16 +02:00
Rafa de la Torre
b0b4a92240 Add a test case for missing foreign CDB_Tablementadata 2019-06-28 16:19:57 +02:00
Raul Marin
78077a6ec1 Bash tests improvements
- Stop loading sql files manually.
- Make tests independent.
- Single DB setup (not once per test)
2019-05-31 15:37:15 +02:00
Eneko Lakasta
b209726b1c
Merge pull request #320 from bloomberg/v0_18_5/cdb_tablemetadata_text_hotfix
Fix incorrect timestamps in CDB_TableMetadata_Text
2018-07-23 16:00:19 +02:00
Tyler Parsons
5c86029029 Test for correct timestamps in cdb_tablemetadata_text 2018-01-25 23:08:28 -05:00
Tyler Parsons
acd101af9b Use PGPORT as fdw port if specified 2018-01-25 23:08:12 -05:00
Raul Marin
0f7a1c4882 Remove PARALLEL mode in older versions (up to 9.6) 2017-11-13 09:35:20 +01:00
Javier Goizueta
399b680b41 Merge pull request #283 from CartoDB/157-test-fixes
Fix tests: race condition with publicuser #157
2016-11-30 16:08:21 +01:00
Rafa de la Torre
30cd4cf1f9 Fix tests: race condition with publicuser #157 2016-10-17 16:31:10 +02:00
Javier Goizueta
1356131ec1 Fix tests 2016-10-14 11:22:06 +02:00
Javier Goizueta
1f01ecae30 Exclude overviews from user data size
Fixes #261

Some internal functions from the Overviews module
have been moved to a separate file because they're now
used from Quaota function.
2016-06-13 10:04:13 +02:00
Raul Ochoa
de5a702510 Adds table for storing camshaft analysis nodes 2016-04-18 17:41:39 +02:00
Alejandro Martínez
90c16fdb13 Fully qualify invalidations 2016-03-02 16:22:22 +01:00
Alejandro Martínez
56fed12392 Add CDB_TableMetadata_Text view as a proxy to access FDW tablemetadata 2016-02-11 19:16:00 +01:00
Rafa de la Torre
9596e8d9bc A couple checks for quoted idents in CDB_Last_Updated_Time 2016-02-10 19:10:57 +01:00
Rafa de la Torre
06036e2fe8 Quote identifiers returned by CDB_QueryTables_Updated_At 2016-02-10 18:58:01 +01:00
Rafa de la Torre
2bce771488 Add some tests
Tests for:
* CDB_QueryTables_Updated_At
* CDB_Last_Updated_Time
2016-02-09 19:24:08 +01:00
Alejandro Martínez
fdbad0f93c Fix specs on 9.3 2016-02-08 17:33:41 +01:00
Alejandro Martínez
131aee1503 Fully qualify function names 2016-02-08 16:35:26 +01:00
Alejandro Martínez
e858ddfa0b Add CDB_ForeignTable specs 2016-02-08 15:46:25 +01:00
Rafa de la Torre
6e4a5b5635 Add CASCADE to DROP SCHEMA... in tear_down #138 2015-09-09 18:33:06 +02:00
Raul Ochoa
5abe6e0b3d Merge branch 'master' into cdb_querytables_quoted
Conflicts:
	test/extension/test.sh
2015-09-07 12:17:36 +02:00
Raul Ochoa
4be7d4a497 Use quote_ident to quote schema and table names when necessary
Fixes #133
2015-09-03 13:12:29 +02:00
Raul Ochoa
350c76f847 Add option to run tests by prefix
`bash test/extension/test.sh test_cdb_querytables`
will run all tests that start with test_cdb_querytables
2015-09-03 12:59:20 +02:00
Raul Ochoa
e28b6344aa Assert it's not possible to get column names from a table without permissions 2015-09-02 12:32:43 +02:00
Raul Ochoa
2867a6fbad Assert user can use its schema to retrieve column names 2015-09-02 12:32:34 +02:00
Raul Ochoa
7582f2cbc5 CDB_ColumnType uses schema and table from regclass
Fixes #130
2015-09-02 12:06:04 +02:00
Raul Ochoa
4b5c5dd275 CDB_ColumnNames uses schema and table name from regclass
Fixes #122
2015-09-02 12:04:52 +02:00
Raul Ochoa
eb6fc4fefb Use CDB_ColumnType and CDB_ColumnNames in bash tests 2015-09-02 12:01:43 +02:00
Raul Ochoa
fc95566ddd Remove test for unexistent table as there was already one 2015-03-31 16:01:49 +02:00
Raul Ochoa
7f58e1f690 Adds tests for cdb_tablemetadatatouch
- fixes tableoid by using the proper table oid
 - tests quoted and unqouted call with OID
 - tests non existent table to fail
2015-03-31 14:48:45 +02:00