• R/O
  • HTTP
  • SSH
  • HTTPS

pg_hint_plan: List of commits

firtst release


RSS
Rev. Time Author
9db100f PG94 2020-02-17 21:08:52 Kyotaro Horiguchi

Restore current hint state when returned from non-hinted query planning.

If no hint is given for the current level query, pg_hint_plan_planner
calls the next level of planner after erasing the
current_hint_state. But it forgot to restore the state before the
planning of the rest part of the current-level query. It is
(a-kind-of) broken by the commit 2c73975 and d1a839a but overlooked by
assuming the required side-effect of the fix. Get back the behavior
by restoring current_hint_state after returned from the lower level
planner with unhinted query.

Issue: https://github.com/ossc-db/pg_hint_plan/issues/30
Reported-by: higuchi-daisuke

516711b 2020-02-17 14:53:27 Kyotaro Horiguchi

Fix Rows hint parsing

This is a long standing bug that Rows hint with no parameter causees a
crash. Fixed the Rows hint parser.

43fe344 2020-02-14 15:46:43 Kyotaro Horiguchi

Fix crash bug caused by plancache invalidation

https://github.com/ossc-db/pg_hint_plan/issues/41

After plancache is invalidated then revaliated, get_query_string
accesses query_list of invalid plansource then crash. Ignore invalid
plancache and get the correct hint string and Query node at the next
planning time during revalidation.

On the way fixing this, a bug related to planner reentrance is
fixed. That fix causes behavioral change for nested
planning. Previously outer-level hint (wrongly) overrides inner-level
query but currenlty outer-level hint no longer affects inner-level
query.

4bddf46 2020-02-13 20:02:01 LittleWuCoding

Fix compiling error on Solaris

The 'LDFLAGS+=-Wl,--build-id' option is for rpm building in Linux like
OS. The SunOS is not native support the option
'LDFLAGS+=-Wl,--build-id' . So, we disable this option in SunOS while
compiling.

Committed a bit tweaked version from the orignal.

510f6a4 2020-02-13 19:40:12 Kyotaro Horiguchi

Stabilize regression test and catching-up to the core.

Further unstability is found about stats reset. Inserted more 1 second
sleeps to stabilize it. Some planner fix seems to have changed its
behvavior. The commit 2407d4807f, which changed the category of
client_min_messages, affected ut-A's result. Follow the changes.

Most of this fix is comes from the pull request
https://github.com/ossc-db/pg_hint_plan/pull/28 by Dagouhan.

3112422 2020-02-13 14:50:53 Kyotaro Horiguchi

Do null-check of error_context_stack before use

The variable is accessed without null checking when planner is called
in the context of pl/pgsql. Fix it. Back-patched up to pg_hint_plan94.

Reporter: egashira-yusuke
Issue: https://github.com/ossc-db/pg_hint_plan/issues/42
Original-Author: sun-wei <30999182+Dagouhan@users.noreply.github.com>
Original-patch: https://github.com/ossc-db/pg_hint_plan/pull/45/commits/8fe092ef73a9af6cfb41e20717d7cb35aa74fce2

7f82a1c 2019-08-29 16:57:00 LittleWuCoding

fix spelling mistakes in file pg_hint_plan.html

523c048 REL94_1_1_8 2019-01-17 16:41:58 Kyotaro Horiguchi

Change version to 1.1.8

Version bumped to 1.1.8. SPEC file is updated.

200ecda 2019-01-17 16:41:58 Kyotaro Horiguchi

Fix reverse link of hint_list.html

pg_hint_plan.html and hint_list.html pointed to the Japanese version
of main document. Fixed it.

f348aa3 2019-01-17 15:20:53 Kyotaro Horiguchi

Fix documentation.

The documentation contains some stale description or missing
items. Fix it.

6e17c4c 2019-01-17 14:09:32 Kyotaro Horiguchi

Do make install for rpmbuild

Use make install to build in prmbuild directory instaed of using
install command to individual file to reduce maintenance labor.

090a1f2 2019-01-17 14:08:37 Kyotaro Horiguchi

Include all pg_hint_plan--*.sql files in installation

Glob installation/upgrade SQL scripts instead of spcifying
individually to reduce maintenance labor.

a01e893 2019-01-17 14:07:49 Kyotaro Horiguchi

Change copyright year to 2019

With some minor fixes in the document.

be85d3d 2019-01-09 09:55:02 Kyotaro Horiguchi

Call standrad_ProcessUtility when no hook is set

The last commit c362705 forgot the case of no previous hook function
in the ProcessUtility hook function. Fix it.

c362705 2019-01-07 19:07:10 Kyotaro Horiguchi

Support prepared statements on extended protocol

However pg_hint_plan doesn't fully consider the extended protocol,
commit 3f6c983 accidentially broke the case where an analyzed prepared
statement is executed on extended protocol. This patch fixes that only
for the hints-in-comment case. Hint-table still doesn't work in the
case since query-normalization needs Query, which is not available in
planner_hook.

d615026 2019-01-07 19:07:10 Kyotaro Horiguchi

Remove an useless variable

commit 3f6c983 made the variable stmt_name useless. Remove it.

b32d680 2018-12-05 17:32:46 Kyotaro Horiguchi

Fix for union-on-inheritance case

setup_hint_enforcement may pick up a wrong hint when multiple
subqueries access inheritance tables. This leads to failure to apply
hints on other than the first subquery.

0e34503 2018-12-05 17:32:41 Kyotaro Horiguchi

Don't reset plpgsql nest level at every command end

Clean up code for global exit is forgetting about loops that run
hinted commands multiple times. This leads to pg_hint_plan's failure
to affect after the first execution of the inner commands.
The hint below worked only for the first time.

FOR outer IN EXECUTE 'outer-command' LOOP
FOR inner IN EXECUTE '/*+ hint */ inner-command' LOOP
<something>
END LOOP;
END LOOP;

5a909ae REL94_1_1_7 2018-11-13 17:04:34 Kyotaro Horiguchi

Changed version to 1.1.7

Previously parse_messages and message_level were binded to the same
internal variable. Separate the two GUCs. On the way doing this some
mssages that did not honor the variable were fixed. Default behavior
is not changed but the the two variables works differently from the
previous version, perhaps closer to expected.

c4f93f5 2018-11-13 16:55:19 Kyotaro Horiguchi

Fix debug output level control

Previously parse_messages and message_level were binded to the same
internal variable. Separate the two GUCs. On the way doing this some
mssages that did not honor the variable were fixed. Default behavior
is not changed but the the two variables works differently from the
previous version, perhaps closer to expected.

690a353 REL94_1_1_6 2018-06-08 14:12:01 Kyotaro Horiguchi

Change version to 1.1.6.

1.1.5 has a crash bug in Describe message of extended protocol
path. If server receives the message after invalidation of
corresponding query cache, pg_hint_plan crashes.

On the way fixing it, this version took in the following commit of
core.

58fec95268 Change more places to be less trusting of RestrictInfo.is_pushed_down.

e608fb3 2018-06-08 14:11:30 Kyotaro Horiguchi

Took in core improvement.

Took in the following commit of core.

58fec95268 Change more places to be less trusting of RestrictInfo.is_pushed_down.

a257715 2018-06-08 14:11:06 Kyotaro Horiguchi

Took in changes of pg_stat_statements.

Took in the following commits on pg_stat_statements. These commits
change unused part of the file so they don't affect the behavior of
pg_hint_plan.

4f37d09169 Avoid unlikely data-loss scenarios due to rename() without fsync.

93840f96c7 Improve contrib/pg_stat_statements' handling of garbage collection failure.

a27fbb8 2018-06-08 10:02:56 Kyotaro Horiguchi

Fix a crash bug in case debug_query_string is NULL

pg_hint_plan believed that debug_query_string cannot be null when
parse_analyze is called, but for example in the case under
exec_describe_statement_message, it is not. We see the query string in
pstate even in the case, so use it instead in the case. Since pstate
is storing the query of the lowermost level, we should use
debug_query_string in other cases.

f56a7f5 2017-11-06 15:11:01 Kyotaro Horiguchi

Added and removed some entries in .gitignore

Removed core.c, that is not appropriate.
Added .deps and RPMS.

c779db7 2017-11-06 14:04:04 Kyotaro Horiguchi

Use pg_strcasecmp instead of strcasecmp for the sake of portability

67ee094 REL94_1_1_5 2017-07-27 19:19:36 Kyotaro Horiguchi

Change version to 1.1.5

1.1.4 has an assertion failure bug raised by DECLARE CURSOR with
enabling table hint. Fixed it.

Addition to that, core.c has been up to date to core.

5355f71 2017-07-27 19:19:21 Kyotaro Horiguchi

Make core.c up to date.

Apply changes in corresponding core code.

6f424c5 2017-07-27 19:19:10 Kyotaro Horiguchi

Fixed a crash bug by DECLARE CURSOR and enable_hint_table = on

The previous version causes assertion failure by DECLARE CURSOR syntax
when table hint is activated. The cause is that the version forgot the
fact that DelcareCursorStmt is in a bit strange shape. Add support of
DECLARE CURSOR and regression test for table hinting.

1407e83 REL94_1_1_4 2017-05-19 14:00:32 Kyotaro Horiguchi

Change version to 1.1.4

1.1.3 has a crash bug raised by queries in specific shape involving
complex views and/or SQL functions.

It is fixed in this version.

Show on old repository browser