You can subscribe to this list here.
2010 |
Jan
|
Feb
|
Mar
|
Apr
(4) |
May
(28) |
Jun
(12) |
Jul
(11) |
Aug
(12) |
Sep
(5) |
Oct
(19) |
Nov
(14) |
Dec
(12) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2011 |
Jan
(18) |
Feb
(30) |
Mar
(115) |
Apr
(89) |
May
(50) |
Jun
(44) |
Jul
(22) |
Aug
(13) |
Sep
(11) |
Oct
(30) |
Nov
(28) |
Dec
(39) |
2012 |
Jan
(38) |
Feb
(18) |
Mar
(43) |
Apr
(91) |
May
(108) |
Jun
(46) |
Jul
(37) |
Aug
(44) |
Sep
(33) |
Oct
(29) |
Nov
(36) |
Dec
(15) |
2013 |
Jan
(35) |
Feb
(611) |
Mar
(5) |
Apr
(55) |
May
(30) |
Jun
(28) |
Jul
(458) |
Aug
(34) |
Sep
(9) |
Oct
(39) |
Nov
(22) |
Dec
(32) |
2014 |
Jan
(16) |
Feb
(16) |
Mar
(42) |
Apr
(179) |
May
(7) |
Jun
(6) |
Jul
(9) |
Aug
|
Sep
(4) |
Oct
|
Nov
(3) |
Dec
|
2015 |
Jan
|
Feb
|
Mar
|
Apr
(2) |
May
(4) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
|
|
|
1
(2) |
2
(3) |
3
|
4
(2) |
5
(3) |
6
(2) |
7
(8) |
8
(12) |
9
|
10
|
11
(17) |
12
(16) |
13
(4) |
14
(3) |
15
(5) |
16
|
17
|
18
(1) |
19
(3) |
20
(2) |
21
(1) |
22
(1) |
23
|
24
|
25
(3) |
26
(1) |
27
|
28
|
29
|
30
|
From: Michael P. <mic...@us...> - 2011-04-02 17:28:23
|
Project "Postgres-XC". The branch, master has been updated via e1946160fe64042e76b5252c66b6f6fb5da6b85d (commit) from 098a076729929a8ecf2c6eecd5cc6de63628e882 (commit) - Log ----------------------------------------------------------------- commit e1946160fe64042e76b5252c66b6f6fb5da6b85d Author: Michael P <mic...@us...> Date: Sun Apr 3 02:27:21 2011 +0900 Support for COMMENT Depending on the object type, COMMENT is treated on Coordinators or on all nodes. diff --git a/src/backend/tcop/utility.c b/src/backend/tcop/utility.c index a184b89..1ffeead 100644 --- a/src/backend/tcop/utility.c +++ b/src/backend/tcop/utility.c @@ -804,6 +804,24 @@ standard_ProcessUtility(Node *parsetree, case T_CommentStmt: CommentObject((CommentStmt *) parsetree); + +#ifdef PGXC + /* + * We need to check details of the object being dropped and + * run command on correct nodes + */ + if (IS_PGXC_COORDINATOR && !IsConnFromCoord()) + { + CommentStmt *stmt = (CommentStmt *) parsetree; + + /* Sequence and views exists only on Coordinators */ + if (stmt->objtype == OBJECT_SEQUENCE || + stmt->objtype == OBJECT_VIEW) + ExecUtilityStmtOnNodes(queryString, NULL, false, EXEC_ON_COORDS); + else + ExecUtilityStmtOnNodes(queryString, NULL, false, EXEC_ON_ALL_NODES); + } +#endif break; case T_CopyStmt: ----------------------------------------------------------------------- Summary of changes: src/backend/tcop/utility.c | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+), 0 deletions(-) hooks/post-receive -- Postgres-XC |
From: Michael P. <mic...@us...> - 2011-04-02 16:48:55
|
Project "Postgres-XC". The branch, master has been updated via 098a076729929a8ecf2c6eecd5cc6de63628e882 (commit) from 894ec20ad348f6230e1a796b7435d62f6867eab8 (commit) - Log ----------------------------------------------------------------- commit 098a076729929a8ecf2c6eecd5cc6de63628e882 Author: Michael P <mic...@us...> Date: Sun Apr 3 01:46:20 2011 +0900 Fix for bug 3237724: CREATE/DROP TABLE in test join The origin of this bug was a query in inherit. This query dropped a dozen of tables at once but some tables did not exist due to Postgres-XC's SQL restrictions. It was resulting in diff about tables already existing for test cases create_view and join. diff --git a/src/test/regress/sql/inherit.sql b/src/test/regress/sql/inherit.sql index 4babd68..d735a73 100644 --- a/src/test/regress/sql/inherit.sql +++ b/src/test/regress/sql/inherit.sql @@ -333,7 +333,16 @@ SELECT c.relname, objsubid, description FROM pg_description, pg_index i, pg_clas CREATE TABLE inh_error1 () INHERITS (t1, t4); CREATE TABLE inh_error2 (LIKE t4 INCLUDING STORAGE) INHERITS (t1); -DROP TABLE t1, t2, t3, t4, t12_storage, t12_comments, t1_inh, t13_inh, t13_like, t_all; +DROP TABLE t1; +DROP TABLE t2; +DROP TABLE t3; +DROP TABLE t4; +DROP TABLE t12_storage; +DROP TABLE t12_comments; +DROP TABLE t1_inh; +DROP TABLE t13_inh; +DROP TABLE t13_like; +DROP TABLE t_all; -- Test for renaming in simple multiple inheritance CREATE TABLE t1 (a int, b int); ----------------------------------------------------------------------- Summary of changes: src/test/regress/sql/inherit.sql | 11 ++++++++++- 1 files changed, 10 insertions(+), 1 deletions(-) hooks/post-receive -- Postgres-XC |
From: Michael P. <mic...@us...> - 2011-04-02 16:33:25
|
Project "Postgres-XC". The branch, master has been updated via 894ec20ad348f6230e1a796b7435d62f6867eab8 (commit) from f738280c29b0e50348a8b0940679595534220e24 (commit) - Log ----------------------------------------------------------------- commit 894ec20ad348f6230e1a796b7435d62f6867eab8 Author: Michael P <mic...@us...> Date: Sun Apr 3 01:32:35 2011 +0900 Fix for bug 3269392: GRANT for VIEW and SEQUENCE GRANT was launched on all the nodes, but for views and sequence objects it is only necessary to launch it on Coordinators. When multiple objects are granted at the same time, XC checks their types and returns an error in case Coordinator-only objects are mixed with normal relations. There is also a fix for regression test privileges. diff --git a/src/backend/tcop/utility.c b/src/backend/tcop/utility.c index 49c018b..a184b89 100644 --- a/src/backend/tcop/utility.c +++ b/src/backend/tcop/utility.c @@ -1007,12 +1007,58 @@ standard_ProcessUtility(Node *parsetree, break; case T_GrantStmt: - ExecuteGrantStmt((GrantStmt *) parsetree); - #ifdef PGXC - if (IS_PGXC_COORDINATOR) - ExecUtilityStmtOnNodes(queryString, NULL, false, EXEC_ON_ALL_NODES); + if (IS_PGXC_COORDINATOR && !IsConnFromCoord()) + { + RemoteQueryExecType remoteExecType = EXEC_ON_ALL_NODES; + GrantStmt *stmt = (GrantStmt *) parsetree; + + /* Launch GRANT on Coordinator if object is a sequence */ + if (stmt->objtype == ACL_OBJECT_SEQUENCE) + remoteExecType = EXEC_ON_COORDS; + else if (stmt->objtype == ACL_OBJECT_RELATION && + stmt->targtype == ACL_TARGET_OBJECT) + { + /* + * In case object is a relation, differenciate the case + * of a sequence, a view and a table + */ + ListCell *cell; + /* Check the list of objects */ + bool first = true; + RemoteQueryExecType type_local = remoteExecType; + + foreach (cell, stmt->objects) + { + RangeVar *relvar = (RangeVar *) lfirst(cell); + Oid relid = RangeVarGetRelid(relvar, false); + + if (get_rel_relkind(relid) == RELKIND_SEQUENCE || + get_rel_relkind(relid) == RELKIND_VIEW) + remoteExecType = EXEC_ON_COORDS; + else + remoteExecType = EXEC_ON_ALL_NODES; + + /* Check if objects can be launched at the same place as 1st one */ + if (first) + { + type_local = remoteExecType; + first = false; + } + else + { + if (type_local != remoteExecType) + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("PGXC does not support GRANT on multiple object types"), + errdetail("Grant VIEW/SEQUENCE and relations on separate queries"))); + } + } + } + ExecUtilityStmtOnNodes(queryString, NULL, false, remoteExecType); + } #endif + ExecuteGrantStmt((GrantStmt *) parsetree); break; case T_GrantRoleStmt: diff --git a/src/test/regress/expected/privileges_1.out b/src/test/regress/expected/privileges_1.out index 94b9267..d71fd34 100644 --- a/src/test/regress/expected/privileges_1.out +++ b/src/test/regress/expected/privileges_1.out @@ -457,7 +457,6 @@ REVOKE ALL PRIVILEGES ON LANGUAGE sql FROM PUBLIC; GRANT USAGE ON LANGUAGE sql TO regressuser1; -- ok GRANT USAGE ON LANGUAGE c TO PUBLIC; -- fail ERROR: language "c" is not trusted -HINT: Only superusers can use untrusted languages. SET SESSION AUTHORIZATION regressuser1; GRANT USAGE ON LANGUAGE sql TO regressuser2; -- fail WARNING: no privileges were granted for "sql" @@ -893,14 +892,19 @@ SELECT lo_create(1005); (1 row) GRANT ALL ON LARGE OBJECT 1001 TO PUBLIC; +ERROR: large object 1001 does not exist GRANT SELECT ON LARGE OBJECT 1003 TO regressuser2; +ERROR: large object 1003 does not exist GRANT SELECT,UPDATE ON LARGE OBJECT 1004 TO regressuser2; +ERROR: large object 1004 does not exist GRANT ALL ON LARGE OBJECT 1005 TO regressuser2; +ERROR: large object 1005 does not exist GRANT SELECT ON LARGE OBJECT 1005 TO regressuser2 WITH GRANT OPTION; +ERROR: large object 1005 does not exist GRANT SELECT, INSERT ON LARGE OBJECT 1001 TO PUBLIC; -- to be failed -ERROR: invalid privilege type INSERT for large object +ERROR: large object 1001 does not exist GRANT SELECT, UPDATE ON LARGE OBJECT 1001 TO nosuchuser; -- to be failed -ERROR: role "nosuchuser" does not exist +ERROR: large object 1001 does not exist GRANT SELECT, UPDATE ON LARGE OBJECT 999 TO PUBLIC; -- to be failed ERROR: large object 999 does not exist \c - @@ -918,46 +922,29 @@ SELECT lo_create(2002); (1 row) SELECT loread(lo_open(1001, x'40000'::int), 32); - loread --------- - \x -(1 row) - +ERROR: permission denied for large object 1001 SELECT loread(lo_open(1002, x'40000'::int), 32); -- to be denied ERROR: permission denied for large object 1002 SELECT loread(lo_open(1003, x'40000'::int), 32); - loread --------- - \x -(1 row) - +ERROR: permission denied for large object 1003 SELECT loread(lo_open(1004, x'40000'::int), 32); - loread --------- - \x -(1 row) - +ERROR: permission denied for large object 1004 SELECT lowrite(lo_open(1001, x'20000'::int), 'abcd'); - lowrite ---------- - 4 -(1 row) - +ERROR: permission denied for large object 1001 SELECT lowrite(lo_open(1002, x'20000'::int), 'abcd'); -- to be denied ERROR: permission denied for large object 1002 SELECT lowrite(lo_open(1003, x'20000'::int), 'abcd'); -- to be denied ERROR: permission denied for large object 1003 SELECT lowrite(lo_open(1004, x'20000'::int), 'abcd'); - lowrite ---------- - 4 -(1 row) - +ERROR: permission denied for large object 1004 GRANT SELECT ON LARGE OBJECT 1005 TO regressuser3; +ERROR: large object 1005 does not exist GRANT UPDATE ON LARGE OBJECT 1006 TO regressuser3; -- to be denied ERROR: large object 1006 does not exist REVOKE ALL ON LARGE OBJECT 2001, 2002 FROM PUBLIC; +ERROR: large object 2001 does not exist GRANT ALL ON LARGE OBJECT 2001 TO regressuser3; +ERROR: large object 2001 does not exist SELECT lo_unlink(1001); -- to be denied ERROR: must be owner of large object 1001 SELECT lo_unlink(2002); @@ -969,39 +956,27 @@ SELECT lo_unlink(2002); \c - -- confirm ACL setting SELECT oid, pg_get_userbyid(lomowner) ownername, lomacl FROM pg_largeobject_metadata; - oid | ownername | lomacl -------+--------------+------------------------------------------------------------------------------------------ + oid | ownername | lomacl +------+--------------+-------- + 1001 | regressuser1 | 1002 | regressuser1 | - 1001 | regressuser1 | {regressuser1=rw/regressuser1,=rw/regressuser1} - 1003 | regressuser1 | {regressuser1=rw/regressuser1,regressuser2=r/regressuser1} - 1004 | regressuser1 | {regressuser1=rw/regressuser1,regressuser2=rw/regressuser1} - 1005 | regressuser1 | {regressuser1=rw/regressuser1,regressuser2=r*w/regressuser1,regressuser3=r/regressuser2} - 2001 | regressuser2 | {regressuser2=rw/regressuser2,regressuser3=rw/regressuser2} + 1003 | regressuser1 | + 1004 | regressuser1 | + 1005 | regressuser1 | + 2001 | regressuser2 | (6 rows) SET SESSION AUTHORIZATION regressuser3; SELECT loread(lo_open(1001, x'40000'::int), 32); - loread ------------- - \x61626364 -(1 row) - +ERROR: permission denied for large object 1001 SELECT loread(lo_open(1003, x'40000'::int), 32); -- to be denied ERROR: permission denied for large object 1003 SELECT loread(lo_open(1005, x'40000'::int), 32); - loread --------- - \x -(1 row) - +ERROR: permission denied for large object 1005 SELECT lo_truncate(lo_open(1005, x'20000'::int), 10); -- to be denied ERROR: permission denied for large object 1005 SELECT lo_truncate(lo_open(2001, x'20000'::int), 10); - lo_truncate -------------- - 0 -(1 row) - +ERROR: permission denied for large object 2001 -- compatibility mode in largeobject permission \c - SET lo_compat_privileges = false; -- default setting @@ -1260,6 +1235,8 @@ REVOKE USAGE ON LANGUAGE sql FROM regressuser1; DROP OWNED BY regressuser1; DROP USER regressuser1; DROP USER regressuser2; +ERROR: role "regressuser2" cannot be dropped because some objects depend on it +DETAIL: privileges for language sql DROP USER regressuser3; DROP USER regressuser4; DROP USER regressuser5; ----------------------------------------------------------------------- Summary of changes: src/backend/tcop/utility.c | 54 ++++++++++++++++++-- src/test/regress/expected/privileges_1.out | 77 ++++++++++------------------ 2 files changed, 77 insertions(+), 54 deletions(-) hooks/post-receive -- Postgres-XC |