Commit Graph

118 Commits

Author SHA1 Message Date
Sandro Santilli
9afc59da5e Set release date for 0.2.1 2014-06-11 19:28:24 +02:00
Sandro Santilli
bc0966c46e Do not add unique index on cartodb_id if already a primary key
Closes #38
2014-06-11 19:21:19 +02:00
Sandro Santilli
afcc2498c8 List plpythonu requirement first, so get pg_catalog scanned before public
Since "plpythonu" is installed in "pg_catalog" schema, requiring it
from cartodb.control adds the "pg_catalog" to the search_path.
Schemas are added to search_path in order of appearence in the "requires"
directive of the cartodb.contorl, right after the name of schema
written in the "schema" directive.

So this commit changes the resulting search_path from:

 cartodb,schema_triggers,public,pg_catalog

To:

 cartodb,pg_catalog,schema_triggers,public

Preventing presence of objects in the "public" schema from changing
interpretation of function signatures and body from this extension.

Spotted in the real world in presence of a "date" table changing
intepretation of CDB_StringToDate function.
2014-06-11 16:27:11 +02:00
Sandro Santilli
81bbfcbda8 Drop useless DEFAULT specification in plpgsql variable declarations 2014-06-11 11:25:25 +02:00
Sandro Santilli
9dbe854df7 Do not force re-cartodbfication on CREATE FROM unpackaged 2014-06-11 10:24:53 +02:00
Sandro Santilli
befa7a10c8 Set version to 0.2.0 2014-06-09 12:51:31 +02:00
Sandro Santilli
f75c256b6e Another full qualification of CDB_TransformToWebmercator in CDB_CartodbfyTable 2014-06-06 18:09:41 +02:00
Sandro Santilli
d52556c20e Fully qualify call to CDB_TransformToWebmercator from CDB_CartodbfyTable 2014-06-06 17:28:43 +02:00
Sandro Santilli
85afef40d8 Make git dependency support use as a submodule 2014-06-06 16:15:02 +02:00
Sandro Santilli
1692e792a7 Make .git/index a dependency of cartodb_version.sql
Ensures proper rebuild of version function on git pull/commit
2014-06-06 13:36:21 +02:00
Sandro Santilli
f8180123eb Grant permission to run table-info functions to public
This is needed as a way to migrate from versions < 0.2.0
See #36
2014-06-06 11:36:19 +02:00
Sandro Santilli
01ae7b8c10 Drop role management
Roles are not created anymore, previously private functions for table
information extraction (CDB_UserTables, CDB_TableIndexes, CDB_ColumnNames,
CDB_ColumnType) will now be callable by anyone while only returning
information about tables over which the calling user has SELECT privilege.

Closes #36
2014-06-06 11:02:51 +02:00
Sandro Santilli
edc56e60ee Further increase in test tolerance 2014-06-05 18:21:52 +02:00
Sandro Santilli
f6e0456265 Increase tolerance in floating number based tests (extent) 2014-06-05 18:20:04 +02:00
Sandro Santilli
1f7b8db532 [Travis] install postgresql-plpython-9.3 package, now needed 2014-06-05 15:06:14 +02:00
Sandro Santilli
f9f73d2d62 Fix potential infinite loop in CDB_QueryStatements
This fix was already present at one point in cartodb/lib/sql
(where the code was copied from) but in a different branch than
the one the code was initially copied from.

The fix depends on plpython language which becomes a new dependency.
2014-06-05 15:00:57 +02:00
Sandro Santilli
fba8d3ab84 Do not assume cartodb functions install in "public" schema during testing 2014-06-04 17:03:17 +02:00
Sandro Santilli
ca07c81f13 Make sed usage more compatible
... and a bit less safe

Might close #35
2014-06-04 15:11:30 +02:00
Sandro Santilli
9322cecb3d Make sed command a variable 2014-06-04 12:58:19 +02:00
Sandro Santilli
e932ec3595 Fix formatting 2014-06-04 12:53:14 +02:00
Raul Ochoa
3fb1f69eb1 CDB-3086 adds troubleshooting section to readme with information about mac os x sed 2014-06-04 12:52:51 +02:00
Sandro Santilli
e993f83b8d Rename test to have "Test" suffix 2014-06-04 10:41:34 +02:00
Sandro Santilli
651bb8cdb7 Add instructions about adding a test 2014-06-04 10:40:18 +02:00
Sandro Santilli
a92d7d7d37 Add cdb_extension_reload() utility function 2014-06-04 10:31:03 +02:00
Sandro Santilli
c286727181 Add note about extension needing to be installed before it can be upgraded to 2014-06-04 10:16:42 +02:00
Sandro Santilli
d762da1ca2 Add section about updating cartodb extension
CDB-3049
2014-06-04 10:13:35 +02:00
Sandro Santilli
a650c951c8 Add link to pg_schema_triggers fork 2014-06-03 16:26:05 +02:00
Sandro Santilli
9230ffa925 Include revision info in cdb_version() output
Closes #34

NOTE: it will only work if "make" is run from within a git clone
2014-06-03 13:20:49 +02:00
Sandro Santilli
ce20009fb2 Workaround PostgreSQL bug possibly triggering infinite loops
Implements casting of existing system column values during
cartodbfication using ALTER rather than UPDATE.

It's faster for tables with many rows and works around a
longstanding PostgreSQL bug. See
http://www.postgresql.org/message-id/20140530143150.GA11051@localhost

CDB-3059
2014-05-30 19:24:19 +02:00
Sandro Santilli
cc9cbdb7a7 Typo 2014-05-30 18:35:08 +02:00
Sandro Santilli
ac53d6b000 Formatting only change 2014-05-30 12:22:54 +02:00
Sandro Santilli
f5ad0d0434 Fully qualify call to CDB_UserDataSize from quota trigger 2014-05-28 17:42:11 +02:00
Sandro Santilli
bfd56f0ea6 Fully qualify call to cdb_disable_ddl_hooks from cdb_enable_ddl_hooks 2014-05-28 12:53:22 +02:00
Sandro Santilli
7483f8d10b Update NEWS file (0.1.1 will likely not happen) 2014-05-28 12:32:30 +02:00
Sandro Santilli
004c3c5543 Ensure cartodb_id uses an associated sequence
Closes #33
2014-05-28 10:45:42 +02:00
Sandro Santilli
d1990f1765 Provide upgrade paths
Mainly from 0.1.0 and 0.1.1
Includes 0.2.0dev to next and back
2014-05-28 09:48:32 +02:00
Sandro Santilli
2601364011 Fix recursive DDL trigger on create table
Closes #32
2014-05-28 09:02:02 +02:00
Sandro Santilli
85cc74b4f4 Do not install cartodb_version.sql in system dirs 2014-05-27 15:51:45 +02:00
Sandro Santilli
2ffa13af58 Add tool to create upgrades 2014-05-23 18:16:10 +02:00
Sandro Santilli
09cf368d62 Move DDL triggers and extension postamble under scripts-available
Target 0.2.0
2014-05-23 17:40:14 +02:00
Sandro Santilli
213cf0aee2 Set version to 0.1.0 again 2014-05-23 17:09:36 +02:00
Sandro Santilli
b2b93a362f Encode dependency of cartodb_version.sql on Makefile 2014-05-23 16:58:26 +02:00
Sandro Santilli
348177d23a Fix cartodbfication of already-cartodbfied tables in presence of views
Closes #30
Includes testcase
2014-05-23 16:54:36 +02:00
Sandro Santilli
50c5cd676c Encode dependency of cartodb.control on Makefile 2014-05-23 16:43:01 +02:00
Sandro Santilli
e9c6728e8e Back to 0.1.0dev version (aborted final) 2014-05-23 16:10:03 +02:00
Sandro Santilli
102e8bd018 Improve error message on failing CDB_CartodbfyTable 2014-05-23 16:04:54 +02:00
Sandro Santilli
fe008b952d Set version to 0.1.0 2014-05-23 15:33:11 +02:00
Sandro Santilli
5602edd207 Make time interval test not dependent on intervalstyle
Fixes testing from under cartodb/lib/sql
2014-05-22 16:32:15 +02:00
Sandro Santilli
967b7abec0 Try to retain existing cartodb_id values
Also reset sequence when original cartodb_id values correctly
cast to integers, and does not keep a backup in that case.

Closes #27
2014-05-22 14:11:09 +02:00
Sandro Santilli
134d2d29b6 Try to cast TEXT typed updated_at and created_at if present
If the cast fails we'll still rename those fields and create
new ones. See #27 (cartodb_id is still not done)
2014-05-22 13:10:42 +02:00