[open-ils-commits] [GIT] Evergreen ILS branch rel_3_2 updated. 6a014627152e3a89dd536918e4f06401101215d6
Evergreen Git
git at git.evergreen-ils.org
Tue Oct 1 15:25:21 EDT 2019
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".
The branch, rel_3_2 has been updated
via 6a014627152e3a89dd536918e4f06401101215d6 (commit)
via aa267255a212f658755a3b8ddd7ee4bf0df8e771 (commit)
via 30a95eeaa3bb6a2737b2d3b1405f79b7aa44c9f3 (commit)
from 42ec4917c0f0bb0fe034e1b09d5ba0ef6cf0021e (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 6a014627152e3a89dd536918e4f06401101215d6
Author: Jason Boyer <jboyer at equinoxinitiative.org>
Date: Tue Oct 1 15:10:56 2019 -0400
LP#1768141: Stamping Upgrade Script
Signed-off-by: Jason Boyer <jboyer at equinoxinitiative.org>
diff --git a/Open-ILS/src/sql/Pg/upgrade/1185.schema.mark_perm_grp_descendants_stable.sql b/Open-ILS/src/sql/Pg/upgrade/1185.schema.mark_perm_grp_descendants_stable.sql
new file mode 100644
index 0000000000..0df191ee97
--- /dev/null
+++ b/Open-ILS/src/sql/Pg/upgrade/1185.schema.mark_perm_grp_descendants_stable.sql
@@ -0,0 +1,7 @@
+BEGIN;
+
+SELECT evergreen.upgrade_deps_block_check('1185', :eg_version); -- csharp / gmcharlt / jboyer
+
+ALTER FUNCTION permission.grp_descendants( INT ) STABLE;
+
+COMMIT;
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql
deleted file mode 100644
index 5dcad46c36..0000000000
--- a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql
+++ /dev/null
@@ -1,7 +0,0 @@
-BEGIN;
-
-SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
-
-ALTER FUNCTION permission.grp_descendants( INT ) STABLE;
-
-COMMIT;
commit aa267255a212f658755a3b8ddd7ee4bf0df8e771
Author: Galen Charlton <gmc at equinoxinitiative.org>
Date: Fri Aug 2 10:41:44 2019 -0400
LP#1768141: (follow-up) change schema update
Change the update to an "ALTER FUNCTION ... STABLE" both
to make the purpose of the update more clear and to remove
the need to check the rest of the function definition when
backporting.
Signed-off-by: Galen Charlton <gmc at equinoxinitiative.org>
Signed-off-by: Jason Boyer <jboyer at equinoxinitiative.org>
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql
index 35244339a4..5dcad46c36 100644
--- a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql
+++ b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql
@@ -2,18 +2,6 @@ BEGIN;
SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
-CREATE OR REPLACE FUNCTION permission.grp_descendants( INT ) RETURNS SETOF permission.grp_tree AS $$
- WITH RECURSIVE descendant_depth AS (
- SELECT gr.id,
- gr.parent
- FROM permission.grp_tree gr
- WHERE gr.id = $1
- UNION ALL
- SELECT gr.id,
- gr.parent
- FROM permission.grp_tree gr
- JOIN descendant_depth dd ON (dd.id = gr.parent)
- ) SELECT gr.* FROM permission.grp_tree gr JOIN descendant_depth USING (id);
-$$ LANGUAGE SQL STABLE ROWS 1;
+ALTER FUNCTION permission.grp_descendants( INT ) STABLE;
COMMIT;
commit 30a95eeaa3bb6a2737b2d3b1405f79b7aa44c9f3
Author: Chris Sharp <csharp at georgialibraries.org>
Date: Mon May 20 16:14:00 2019 -0400
LP#1768141 - Mark permission.grp_descendants STABLE.
Quoting Galen Charlton's comments on the bug report:
The database function permission.grp_descendants should
be marked stable; it qualifies, and doing so should allow
PostgreSQL to improve query plans. One example of a query
that would benefit is searching by patron profile (a la
bug 1497322)
Signed-off-by: Chris Sharp <csharp at georgialibraries.org>
Signed-off-by: Galen Charlton <gmc at equinoxinitiative.org>
Signed-off-by: Jason Boyer <jboyer at equinoxinitiative.org>
diff --git a/Open-ILS/src/sql/Pg/006.schema.permissions.sql b/Open-ILS/src/sql/Pg/006.schema.permissions.sql
index 564f7852f9..05d38a6243 100644
--- a/Open-ILS/src/sql/Pg/006.schema.permissions.sql
+++ b/Open-ILS/src/sql/Pg/006.schema.permissions.sql
@@ -133,7 +133,7 @@ CREATE OR REPLACE FUNCTION permission.grp_descendants( INT ) RETURNS SETOF permi
FROM permission.grp_tree gr
JOIN descendant_depth dd ON (dd.id = gr.parent)
) SELECT gr.* FROM permission.grp_tree gr JOIN descendant_depth USING (id);
-$$ LANGUAGE SQL ROWS 1;
+$$ LANGUAGE SQL STABLE ROWS 1;
CREATE OR REPLACE FUNCTION permission.grp_tree_full_path ( INT ) RETURNS SETOF permission.grp_tree AS $$
SELECT *
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql
new file mode 100644
index 0000000000..35244339a4
--- /dev/null
+++ b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.mark_perm_grp_descendants_stable.sql
@@ -0,0 +1,19 @@
+BEGIN;
+
+SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
+
+CREATE OR REPLACE FUNCTION permission.grp_descendants( INT ) RETURNS SETOF permission.grp_tree AS $$
+ WITH RECURSIVE descendant_depth AS (
+ SELECT gr.id,
+ gr.parent
+ FROM permission.grp_tree gr
+ WHERE gr.id = $1
+ UNION ALL
+ SELECT gr.id,
+ gr.parent
+ FROM permission.grp_tree gr
+ JOIN descendant_depth dd ON (dd.id = gr.parent)
+ ) SELECT gr.* FROM permission.grp_tree gr JOIN descendant_depth USING (id);
+$$ LANGUAGE SQL STABLE ROWS 1;
+
+COMMIT;
-----------------------------------------------------------------------
Summary of changes:
Open-ILS/src/sql/Pg/006.schema.permissions.sql | 2 +-
.../Pg/upgrade/1185.schema.mark_perm_grp_descendants_stable.sql | 7 +++++++
2 files changed, 8 insertions(+), 1 deletion(-)
create mode 100644 Open-ILS/src/sql/Pg/upgrade/1185.schema.mark_perm_grp_descendants_stable.sql
hooks/post-receive
--
Evergreen ILS
More information about the open-ils-commits
mailing list