Commit Graph

5093 Commits (a75e5ba3e7cdcf5a8032926c8e52b671d5c0b7e8)

Author SHA1 Message Date
Sait Talha Nisanci a75e5ba3e7 Add alternative output for pg12 for window_functions 2021-08-21 18:15:23 +03:00
Halil Ozan Akgul ac85ac042d Merge branch 'pg14_support' of github.com:citusdata/citus into pg14_support 2021-08-20 20:58:40 +03:00
Halil Ozan Akgul 06ceb5632e Sets next_shard_id at partition_wise_join test 2021-08-20 20:57:43 +03:00
Halil Ozan Akgul bf4fb5b4ca Readds deleted resultRelInfo changes for previos PG versions
These changes were removed in commit: Introduces ExecSimpleRelationInsert_compat and modifyStateResultRelInfo macros
We shouldn't have removed them but instead kept them for before PG14
2021-08-20 20:17:33 +03:00
Nils Dijk 8c0cb6e760
use pg14 image for pg upgrade tests 2021-08-20 17:06:36 +02:00
Sait Talha Nisanci 13e075ed54 Add alternative output for isolation_master_update_node 2021-08-20 10:48:25 +03:00
Sait Talha Nisanci f515599cd9 Bind seg version to 1.3 in isolation_textension_commands 2021-08-20 10:26:41 +03:00
Sait Talha Nisanci b0b883e32c Merge branch 'pg14_support' of https://github.com/citusdata/citus into pg14_support 2021-08-20 09:54:52 +03:00
Sait Talha Nisanci d1b81ad840 Turn off VERBOSE to avoid alternative output
With VERBOSE option, as of PG14, we get a line with "Query Identifier".
2021-08-20 09:51:12 +03:00
Sait Talha Nisanci a82945e51b Add partition_wise_join to avoid big alternative output
There was a small part in multi_partitioning that would need an
alternative output for pg14. Instead of adding an alternative for the
whole file, we created a new file, called partition_wise_join.sql and
added the alternative output for that.
2021-08-20 09:38:41 +03:00
Sait Talha Nisanci ff2d643ab9 Check if extversion is the same for seg extension
When we check the exact version of the seg extension, it becomes a
problem when its version changes, such as from 1.3 to 1.4. So now we
modified the changes to check for that the version is the same in all
the cluster.
2021-08-20 09:16:44 +03:00
Halil Ozan Akgul 8cf5ec7942 Includes pg_version_constants.h in columnar_version_compat.h 2021-08-19 21:42:32 +03:00
Halil Ozan Akgul 293818b93f Puts usage of HASH_STRINGS in PG14 version check 2021-08-19 21:34:43 +03:00
Halil Ozan Akgul 47054c8aed Introduces pg_get_statisticsobj_worker_compat macro
Relevant PG commit:
a4d75c86bf15220df22de0a92c819ecef9db3849
2021-08-19 19:33:10 +03:00
Halil Ozan Akgul 533b031a31 Introduces make_simple_restrictinfo_compat and pull_varnos_compat macros
make_simple_restrictinfo and pull_varnos functions now have a new parameter
These new macros give us the ability to use this new parameter for PG14 and they don't give the parameter for previous versions

Relevant PG commit:
55dc86eca70b1dc18a79c141b3567efed910329d
2021-08-19 19:01:26 +03:00
Nils Dijk f4290d8004
add missing define with old value 2021-08-19 17:44:55 +02:00
Nils Dijk 6494c7afe7
add 14beta3 to CI 2021-08-19 17:25:07 +02:00
Halil Ozan Akgul ef95553658 Removes password outputs from alter_role_propagation tests 2021-08-19 18:12:00 +03:00
Sait Talha Nisanci be797f6eb1 Add alternative output for multi_deparse_function
Postgres tightened up its checks for invalid GUC names hence we started
to get an alternative output for one of our tests. We add an alternative
output since the file is relatively small.

Commit on PG:
3db826bd55cd1df0dd8c3d811f8e5b936d7ba1e4
2021-08-19 16:03:30 +03:00
Sait Talha Nisanci 5442882209 Add shard relation to pState in localCopy
CopyFrom expects an AccessShareLock on the table. Instead of adding an
explicit lock, we do it how postgres is doing, which is to use
addRangeTableEntryForRelation.

Commit:
c532d15dddff14b01fe9ef1d465013cb8ef186df
2021-08-19 15:03:49 +03:00
Sait Talha Nisanci 19a61ad958 Add alternative output for window_functions 2021-08-19 13:17:38 +03:00
Sait Talha Nisanci a812a76a30 Add some normalization rules for pg14 2021-08-19 13:17:20 +03:00
Sait Talha Nisanci 58f07f03ca Turn off COSTS to avoid alternative output for pg14 2021-08-19 13:17:04 +03:00
Sait Talha Nisanci bb831b18f3 Change pg13 test to not differ with pg14 to avoid adding alternative output 2021-08-19 13:16:55 +03:00
Sait Talha Nisanci bf525818e4 Remove VERBOSE output to make pg14 and pg13 output the same 2021-08-19 13:16:46 +03:00
Sait Talha Nisanci 5e9857005d Use rte->updatedCols to determine if partition column exists
Use rte->updatedCols to determine if partition column exists in the
target list in case of UPDATE.

Commit on PG:
86dc90056dfdbd9d1b891718d2e5614e3e432f35
2021-08-19 13:16:32 +03:00
Sait Talha Nisanci 25f9e92636 Use oid_hash in write state management 2021-08-19 13:16:27 +03:00
Halil Ozan Akgul 4216ef38f9 Changes array_cat argument type from anyarray to anycompatiblearray
Relevant PG commit:
9e38c2bb5093ceb0c04d6315ccd8975bd17add66
2021-08-19 13:07:13 +03:00
Sait Talha Nisanci f339d6e264 Fix unlimited copy size variable's value 2021-08-19 13:07:13 +03:00
Sait Talha Nisanci 16b821efba Use empty string instead of NULL for queryString
Postgres doesn't accept NULL for queryStrings in explain plans anymore.
Internally, there are some places in Postgres where they modified the
NULLS to ""(the empty string). So we do the same on citus side.

Commit on Postgres:
1111b2668d89bfcb6f502789158b1233ab4217a6
2021-08-19 13:07:13 +03:00
Sait Talha Nisanci a39fdc3c3a Use HASH_STRINGS explicitly in hash functions
Postgres expects to set the HASH_STRINGS explicitly in case of the
default behaivor for string hash function.

Postgres Commit
b3817f5f774663d55931dd4fab9c5a94a15ae7ab
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul dbe61f6000 Renames shadowing ruleutils_14.c variables 2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 4199db699e Introduces index_insert_compat macro
index_insert function now has a new parameter, indexUnchanged
This new macro give us the ability to use these new parameter for PG14 and they don't give the parameters for previous versions
Existing parameter is set to false

Relevant PG commit:
9dc718bdf2b1a574481a45624d42b674332e2903
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 62e84a4342 Introduces ExecSimpleRelationInsert_compat and modifyStateResultRelInfo macros
es_result_relation_info is removed from Estate. In this commit we make some changes to handle that.
resultRelationInfo filed is added to ModifyState to support the removed field.

Relevant PG commits:
1375422c7826a2bf387be29895e961614f69de4b
a04daa97a4339c38e304cd6164d37da540d665a8
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 8d5e8b573b Introduces GetOldestNonRemovableTransactionId_compat macro
GetOldestXmin function is removed so we use GetOldestNonRemovableTransactionId functions instead
GetOldestNonRemovableTransactionId_compat picks the appropriate one

Relevant PG commit:
dc7420c2c9274a283779ec19718d2d16323640c0
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul d946625cb9 Introduces get_partition_parent_compat and RelationGetPartitionDesc_compat macros
get_partition_parent and RelationGetPartitionDesc functions now have new parameters to also include detached partitions
Thess new macros give us the ability to use these new parameter for PG14 and they don't give the parameters for previous versions
Existing parameters are set to not accept detached partitions

Relevant PG commit:
71f4c8c6f74ba021e55d35b1128d22fb8c6e1629
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul a1fc7ae5e0 Introduces proc_statusflags_compat macro
In two commits vacuumFlags in PGXACT is moved and then renamed to status flags
This macro uses the appropriate version of the flag

Relevant PG commits:
5788e258bb26495fab65ff3aa486268d1c50b123
cd9c1b3e197a9b53b840dcc87eb41b04d601a5f9
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 12af353d63 Introduces SetTuplestoreDestReceiverParams_compat macro
SetTuplestoreDestReceiverParams function now has two new parameters
This new macro give us the ability to use this new parameter for PG14 and it doesn't give the parameter for previous versions
Existing parameters are set to NULL to keep previous behavior

Relevant PG commit:
2f48ede080f42b97b594fb14102c82ca1001b80c
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 95674ad4e3 !!!!! DO NOT MERGE THIS COMMIT 2021-08-19 13:07:13 +03:00
Halil Ozan Akgul abe85798a8 Uses lfirst_node in ruleutils_14.c
Relevant PG commit:
2b00db4fb0c7f02f000276bfadaab65a14059168
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 8ddeef9d7c Adds missing include_out_argument parameter to func_get_detail in ruleutils_14.c
Relevant PG commit:
e56bce5d43789cce95d099554ae9593ada92b3b7
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul d07a6129e3 Adds SQL-standard function body support to ruleutils_14.c
Relevant PG commit:
e717a9a18b2e34c9c40e5259ad4d31cd7e420750
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 0d0fbe518c Adds EXTRACT cases to get_func_sql_syntax in ruleutils_14.c
Relevant PG commit:
a2da77cdb4661826482ebf2ddba1f953bc74afe4
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul ad30f5ef20 Removes ModifyTable check from set_deparse_plan in ruleutils_14.c
Relevant PG commit:
86dc90056dfdbd9d1b891718d2e5614e3e432f35
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 1bee1b299d Adds JOIN ... USING alias to ruleutils_14.c
Relevant PG commit:
055fee7eb4dcc78e58672aef146334275e1cc40d
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 40738bcb43 Extends statistics on expressions in ruleutils_14.c
Relevant PG commit:
a4d75c86bf15220df22de0a92c819ecef9db3849
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul f2d8f60772 Adds GROUP BY DISTINCT to ruleutils_14.c
Relevant PG commit:
be45be9c33a85e72cdaeb9967e9f6d2d00199e09
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 987daf9052 Enhances cycle mark values at ruleutils_14.c
Relevant PG commit:
f4adc41c4f92cc91d507b19e397140c35bb9fd71
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul 8260a42a62 Adds SEARCH and CYCLE clauses to ruleutils_14.c
Relevant PG commit:
3696a600e2292d43c00949ddf0352e4ebb487e5b
2021-08-19 13:07:13 +03:00
Halil Ozan Akgul d0668c6519 Adds bytea equivalents of ltrim() and rtrim() to ruleutils_14.c
Relevant PG commit:
a6cf3df4ebdcbc7857910a67f259705645383e9f
2021-08-19 13:07:13 +03:00