Commit Graph

4705 Commits (1e11a34d0028c98932c530029365384cfece82c9)

Author SHA1 Message Date
Marco Slot 1e11a34d00 Apply #4834 to configure as well 2021-03-18 01:35:34 +01:00
Marco Slot 4ad88a7a89
Merge pull request #4834 from ProsperWorks/master
More precise error messages for ./configure.
2021-03-18 14:22:09 +01:00
jhwillett 8bcf3b9887 More precise error messages for ./configure --without-lz4 and --without-zstd. 2021-03-17 12:52:04 -07:00
SaitTalhaNisanci b4620bed87
Merge pull request #4822 from citusdata/changelog/10.0-3
Update CHANGELOG for 10.0.3
2021-03-17 17:54:32 +03:00
Önder Kalacı b5f4320164
Make sure that single task local executions start coordinated transaction (#4831)
With https://github.com/citusdata/citus/pull/4806 we enabled
2PC for any non-read-only local task. However, if the execution
is a single task, enabling 2PC (CoordinatedTransactionShouldUse2PC)
hits an assertion as we are not in a coordinated transaction.

There is no downside of using a coordinated transaction for single
task local queries.
2021-03-17 12:20:57 +01:00
Ahmet Gedemenli 4558132239
Merge pull request #4830 from citusdata/add-udf-citus-get-active-worker-nodes
Add udf citus_get_active_worker_nodes
2021-03-17 13:39:30 +03:00
Ahmet Gedemenli 5e5db9eefa Add udf citus_get_active_worker_nodes 2021-03-17 13:15:59 +03:00
Sait Talha Nisanci 92130ae2a2 Update CHANGELOG for 10.0.3 2021-03-17 11:21:36 +03:00
Marco Slot 946f529826
Merge pull request #4820 from citusdata/marcocitus/copy-guc
Introduce citus.remote_copy_flush_threshold GUC
2021-03-16 19:05:10 +01:00
Marco Slot 43f600bc46
Merge pull request #4808 from citusdata/marcocitus/connection-lifetime 2021-03-16 14:58:06 +01:00
Marco Slot fbc2147e11 Replace MAX_PUT_COPY_DATA_BUFFER_SIZE by citus.remote_copy_flush_threshold GUC 2021-03-16 06:00:38 +01:00
Marco Slot 1646fca445 Add GUC to set maximum connection lifetime 2021-03-16 01:57:57 +01:00
jeff-davis 3b12556401
Columnar: cleanup (#4814)
* Columnar: fix misnamed file.

* Columnar: make compression not dependent on columnar.h.

* Columnar: rename columnar_metadata_tables.c to columnar_metadata.c.

* Columnar: make customscan not depend on columnar.h.

Co-authored-by: Jeff Davis <jefdavi@microsoft.com>
2021-03-15 11:34:39 -07:00
Onur Tirtir b2a7bafcc4
Fix flaky test in multi_foreign_key_relation_graph (#4819) 2021-03-15 17:55:04 +03:00
Marco Slot 7d8d5cad98
Merge pull request #4817 from citusdata/marcocitus/fix-warning
Remove unnecessary AtEOXact_Files call
2021-03-15 09:58:41 +01:00
Marco Slot 6c5d263b7a Remove unnecessary AtEOXact_Files call 2021-03-15 09:34:02 +01:00
Onur Tirtir 1d3e075e62
Support temporary columnar tables (#4766) 2021-03-12 12:01:36 +03:00
Önder Kalacı 56245d232d
Merge pull request #4806 from citusdata/fix_2pc_local_exec
Do not trigger 2PC for reads on local execution
2021-03-12 09:34:34 +01:00
Onder Kalaci e65e72130d Rename use -> shouldUse
Because setting the flag doesn't necessarily mean that we'll
use 2PC. If connections are read-only, we will not use 2PC.
In other words, we'll use 2PC only for connections that modified
any placements.
2021-03-12 08:29:43 +00:00
Onder Kalaci 6a7ed7b309 Do not trigger 2PC for reads on local execution
Before this commit, Citus used 2PC no matter what kind of
local query execution happens.

For example, if the coordinator has shards (and the workers as well),
even a simple SELECT query could start 2PC:
```SQL

WITH cte_1 AS (SELECT * FROM test LIMIT 10) SELECT count(*) FROM cte_1;
```

In this query, the local execution of the shards (and also intermediate
result reads) triggers the 2PC.

To prevent that, Citus now distinguishes local reads and local writes.
And, Citus switches to 2PC only if a modification happens. This may
still lead to unnecessary 2PCs when there is a local modification
and remote SELECTs only. Though, we handle that separately
via #4587.
2021-03-12 08:29:43 +00:00
Onur Tirtir 874d5fd962
Remove foreign keys between columnar metadata tables (#4791)
Postgres keeps AFTER trigger state for each transaction, because we can have deferred AFTER triggers which will be fired at the end of a transaction. Postgres cleans up this state at the end of transaction.

Postgres processes ON COMMIT triggers after cleaning-up the AFTER trigger states. So if we fire any triggers in ON COMMIT, the AFTER trigger state won't be cleaned-up properly and the transaction state will be left in an inconsistent state, which might result in assertion failure.

So with this commit, we remove foreign keys between columnar metadata tables and enforce constraints between them manually when dropping columnar tables.
2021-03-12 11:28:17 +03:00
Naisila Puka 71a9f45513
Fix upgrade and downgrade paths for master/citus_update_table_statistics (#4805) 2021-03-11 14:52:40 +03:00
Marco Slot 69f09556fd
Merge pull request #4809 from joeljuca/readme-code-highlights
Fix incorrect language syntax on README.md
2021-03-10 23:44:45 +01:00
Joel Jucá a770c5fe4e
Fix incorrect language syntax on README.md 2021-03-10 18:18:45 -03:00
Naisila Puka 196064836c
Skip 2PC for readonly connections in a transaction (#4587)
* Skip 2PC for readonly connections in a transaction

* Use ConnectionModifiedPlacement() function

* Remove the second check of ConnectionModifiedPlacement()

* Add order by to prevent flaky output

* Test using pg_dist_transaction
2021-03-10 20:01:37 +03:00
Marco Slot 68a527ba17
Merge pull request #4800 from citusdata/marcocitus/fix-mod-cte 2021-03-09 21:12:46 +01:00
Marco Slot 9c0d7f5c26 Add tests for modifying CTE and SELECT without FROM 2021-03-09 10:39:33 +01:00
Marco Slot 58f85f55c0 Fixes a crash in queries with a modifying CTE and a SELECT without FROM 2021-03-09 10:39:33 +01:00
SaitTalhaNisanci aef7fc3a51
Ignore columnar generated test files (#4796) 2021-03-09 10:52:08 +03:00
Claire Giordano 742db1c5a2
Merge pull request #4789 from citusdata/claire-readme-edit1
Rm Performance H2 section title (temporarily)
2021-03-07 22:25:08 -08:00
Claire Giordano 33a6f763ea
Rm Performance H2 section title (temporarily) 2021-03-07 17:24:24 -08:00
Marco Slot fe5494b72a
Merge pull request #4345 from citusdata/marcocitus/readme_updates
Modernize Citus readme
2021-03-05 18:12:45 +01:00
Philip Dubé ce296ac62e
Merge pull request #4779 from citusdata/typos
Fix various typos due to zealous repetition
2021-03-05 13:16:12 +00:00
Philip Dubé 4e22f02997 Fix various typos due to zealous repetition 2021-03-04 19:28:15 +00:00
Marco Slot 61d7363eed Rewrite the README 2021-03-04 10:29:11 +01:00
Onur Tirtir 1bb7a0a268
Fix chunk_group_consistency regression test view (#4765) 2021-03-04 12:20:25 +03:00
Onur Tirtir 9728ce1167
Add tests for concurrent index deadlock issue (#4775) 2021-03-04 11:56:54 +03:00
Marco Slot d7880df4ab
Merge pull request #4767 from citusdata/marcocitus/fix-master-add-node
Try to return earlier in idempotent citus_add_node
2021-03-03 23:30:37 +01:00
Hadi Moshayedi 6c409b5d3e
Merge pull request #4769 from citusdata/fix-4675
Populate DATABASEOID cache before CREATE INDEX CONCURRENTLY
2021-03-03 13:04:41 -08:00
Hadi Moshayedi affe38eac6 Populate DATABASEOID cache before CREATE INDEX CONCURRENTLY 2021-03-03 12:59:46 -08:00
Halil Ozan Akgül fc493547cd
Merge pull request #4772 from citusdata/update-cl-1002
Update CHANGELOG for 10.0.2
2021-03-03 17:03:35 +03:00
Halil Ozan Akgül c2a9706203 Update CHANGELOG for 10.0.2 2021-03-03 16:18:00 +03:00
Önder Kalacı 857beb36fe
Merge pull request #4756 from citusdata/fix_on_top_of_pg13
Prevent infinite recursion for queries that involve UNION ALL and JOIN
2021-03-03 13:41:37 +01:00
Onder Kalaci 54ee96470e Pass pointer of AttributeEquivalenceClass instead of pointer of pointer
AttributeEquivalenceClass seems to be unnecessarily used with multiple
pointers. Just use a single pointer for ease of read.
2021-03-03 12:27:26 +01:00
Onder Kalaci d1cd198655 Prevent infinite recursion for queries that involve UNION ALL and JOIN
With this commit, we make sure to prevent infinite recursion for queries
in the format: [subquery with a UNION ALL] JOIN [table or subquery]

Also, fixes a bug where we pushdown UNION ALL below a JOIN even if the
UNION ALL is not safe to pushdown.
2021-03-03 12:27:26 +01:00
Hanefi Onaldi 697bbbd3c6
Do not use security flags by default (#4770) 2021-03-03 12:51:16 +03:00
Hadi Moshayedi 1a05131331
Use chunk groups to read columnar data (#4768) 2021-03-02 23:53:24 -08:00
Naisila Puka 2f30614fe3
Reimplement citus_update_table_statistics to detect dist. deadlocks (#4752)
* Reimplement citus_update_table_statistics

* Update stats for the given table not colocation group

* Add tests for reimplemented citus_update_table_statistics

* Use coordinated transaction, merge with citus_shard_sizes functions

* Update the old master_update_table_statistics as well
2021-03-03 04:12:30 +03:00
Hanefi Onaldi f87107eb6b
Add security flags in configure scripts (#4760) 2021-03-03 01:55:29 +03:00
Marco Slot f25de6a0e3 Try to return earlier in idempotent master_add_node 2021-03-02 21:22:47 +01:00