Commit Graph

2067 Commits (aa16512a815d2ac263cb99a182f4d887f11f7ff3)

Author SHA1 Message Date
Jason Petersen aa16512a81
Merge pull request #2325 from citusdata/failure-packet-dumps
Attempt to stabilize packet dumps and add them back it

cr: @jasonmp85
2018-09-13 10:10:44 -06:00
Brian Cloutier 2fae06056a
Attempt to stabilize packet dumps and add them back it 2018-09-12 22:10:39 -06:00
Jason Petersen 1f64bdfc59
Merge pull request #2322 from citusdata/update-mitmproxy-version
Update mitmproxy version to remove vulnerability warnings

cr: @jasonmp85
2018-09-12 18:25:42 -06:00
Brian Cloutier 5bde8626c5
Travis uses Pipfile instead of re-specifying deps 2018-09-12 17:37:14 -06:00
Brian Cloutier e61e5d4980
Update mitmproxy version to remove vulnerability warnings 2018-09-12 17:17:22 -06:00
Murat Tuncer c3dad4bcfd
Merge pull request #2375 from citusdata/pg11_procedure
Add regression tests for procedure
2018-09-12 15:53:03 +03:00
Murat Tuncer ae0032dff8 Add regression tests for procedure calls
PG11 introduced PROCEDURE concept similar to FUNCTION
Procedure's allow committing/rolling back behavior.

This commmit adds regression tests for procedure calls.
2018-09-12 10:28:50 +03:00
Burak Velioglu 38dbc11c9a
Merge pull request #2363 from citusdata/get_whole_all_transactions
Adds UDFs for testing MX functionalities with isolation tests
2018-09-12 07:43:53 +03:00
velioglu d1f005daac Adds UDFs for testing MX functionalities with isolation tests 2018-09-12 07:04:16 +03:00
Murat Tuncer 470ee0b4d9 Revert multi_partition test back to being required
Test was marked as optional (ignore) by previous
commit. Reverting that change to make test required
2018-09-11 12:39:44 -06:00
Önder Kalacı 8e608a0e6c
Merge pull request #2360 from citusdata/dist_stat_statements
Views to provide some insight about the distributed transactions on Citus MX
2018-09-11 08:46:57 +03:00
Onder Kalaci d657759c97 Views to Provide some insight about the distributed transactions on Citus MX
With this commit, we implement two views that are very similar
to pg_stat_activity, but showing queries that are involved in
distributed queries:

    - citus_dist_stat_activity: Shows all the distributed queries
    - citus_worker_stat_activity: Shows all the queries on the shards
                                  that are initiated by distributed queries.

Both views have the same columns in the outputs. In very basic terms, both of the views
are meant to provide some useful insights about the distributed
transactions within the cluster. As the names reveal, both views are similar to pg_stat_activity.
Also note that these views can be pretty useful on Citus MX clusters.

Note that when the views are queried from the worker nodes, they'd not show the distributed
transactions that are initiated from the coordinator node. The reason is that the worker
nodes do not know the host/port of the coordinator. Thus, it is advisable to query the
views from the coordinator.

If we bucket the columns that the views returns, we'd end up with the following:

- Hostnames and ports:
   - query_hostname, query_hostport: The node that the query is running
   - master_query_host_name, master_query_host_port: The node in the cluster
                                                   initiated the query.
    Note that for citus_dist_stat_activity view, the query_hostname-query_hostport
    is always the same with master_query_host_name-master_query_host_port. The
    distinction is mostly relevant for citus_worker_stat_activity. For example,
    on Citus MX, a users starts a transaction on Node-A, which starts worker
    transactions on Node-B and Node-C. In that case, the query hostnames would be
    Node-B and Node-C whereas the master_query_host_name would Node-A.

- Distributed transaction related things:
    This is mostly the process_id, distributed transactionId and distributed transaction
    number.

- pg_stat_activity columns:
    These two views get all the columns from pg_stat_activity. We're basically joining
    pg_stat_activity with get_all_active_transactions on process_id.
2018-09-10 21:33:27 +03:00
Önder Kalacı df0ca4617f
Merge pull request #2370 from citusdata/fix_truncate_from_workers
Fix the bug introduced via allowing Truncate from MX worker nodes
2018-09-10 18:03:48 +03:00
Onder Kalaci 7de5e30432 Change flaky explain test to non-explain
This test's output changes depending on which worker is
picked for explain (e.g., worker port in the output changes).

Given that the test is only aiming to ensure that CTEs inside
CTEs work fine in DML queries, it should be fine to get rid of
the EXPLAIN. The output is verified to be correct as well.
2018-09-10 16:01:30 +03:00
Onder Kalaci 76aa6951c2 Properly send commands to other nodes
We previously implemented OTHER_WORKERS_WITH_METADATA tag. However,
that was wrong. See the related discussion:
     https://github.com/citusdata/citus/issues/2320

Instead, we switched using OTHER_WORKER_NODES and make the command
that we're running optional such that even if the node is not a
metadata node, we won't be in trouble.
2018-09-10 16:01:30 +03:00
Onder Kalaci 5cf8fbe7b6 Add infrastructure to relation if exists 2018-09-07 14:49:36 +03:00
Önder Kalacı 5ddba6a7cd
Merge pull request #2367 from citusdata/fix_wrong_escaping
Do not recover wrong distributed transactions in MX
2018-09-07 11:44:11 +03:00
Onder Kalaci bf28dd0cff Do not recover wrong distributed transactions in MX 2018-09-07 09:52:46 +03:00
Murat Tuncer e5bba08595
Merge pull request #2366 from citusdata/fix_pg11_build_failure
Reflect changed index for constraint scans in PG11
2018-09-07 08:23:04 +03:00
Murat Tuncer 65276311f7 Reflect changed index for constraint scans in PG11 2018-09-07 08:07:01 +03:00
Murat Tuncer 7b63b23808
Merge pull request #2364 from citusdata/pg11_feature_index_include
Add support for INCLUDE option in index creation
2018-09-06 20:46:33 +03:00
Murat Tuncer d8279569b8 Add support for INCLUDE option in index creation
INCLUDE is a new feature in index creation in PG11.
Included column/expression paramameters are now forwarded to shards
2018-09-06 19:41:06 +03:00
Murat Tuncer 0c1bb26448
Merge pull request #2359 from citusdata/pg11_features
Add regression tests related to new PG11 partitioning features
2018-09-06 19:39:06 +03:00
Murat Tuncer 7d3f7c2bf4 Add regression tests related to new PG11 partitioning features 2018-09-06 19:06:28 +03:00
Murat Tuncer ee27637c11
Merge pull request #2368 from citusdata/allow_pg11_failures
Temporarily allow PG11 failures
2018-09-06 18:48:27 +03:00
Murat Tuncer c7094c083b Temporarily allow PG11 failures
This is a temporary commit to unblock PG11 failures at travis
until end of milestone.
2018-09-06 18:33:43 +03:00
Murat Tuncer 49645d1aee
Merge pull request #2361 from citusdata/pg11_features_part_2
Add regression tests for new PG11 window functions
2018-09-06 08:55:55 +03:00
Murat Tuncer 55cf3e321c Add regression tests for new PG11 window functions
- <offset> preceding/following
- exclude
2018-09-04 10:48:04 +03:00
Önder Kalacı c64f669755
Merge pull request #2343 from citusdata/fix_drop_table_deadlock
Make sure that table (and metadata) is dropped before shards are dropped on Citus MX
2018-09-04 09:44:57 +03:00
Onder Kalaci 1b3257816e Make sure that table is dropped before shards are dropped
This commit fixes a bug where a concurrent DROP TABLE deadlocks
with SELECT (or DML) when the SELECT is executed from the workers.

The problem was that Citus used to remove the metadata before
droping the table on the workers. That creates a time window
where the SELECT starts running on some of the nodes and DROP
table on some of the other nodes.
2018-09-04 08:57:20 +03:00
Önder Kalacı 3ace0ad5eb
Merge pull request #2345 from citusdata/truncate_on_workers
Support TRUNCATE from the MX worker nodes
2018-09-03 15:29:14 +03:00
Onder Kalaci 2ab0e63b30 Fix flaky test 2018-09-03 14:06:32 +03:00
Onder Kalaci 26e308bf2a Support TRUNCATE from the MX worker nodes
This commit enables support for TRUNCATE on both
distributed table and reference tables.

The basic idea is to acquire lock on the relation by sending
the TRUNCATE command to all metedata worker nodes. We only
skip sending the TRUNCATE command to the node that actually
executus the command to prevent a self-distributed-deadlock.
2018-09-03 14:06:31 +03:00
Onder Kalaci 97ba7bf2eb Add the option to skip the node that is executing the node 2018-09-03 14:01:24 +03:00
Burak Velioglu a4c6cefb17
Merge pull request #2351 from citusdata/master-update-changelog-28082018
Add changelog entry for 7.5.1
2018-08-28 14:09:22 +03:00
velioglu b6cee4bb96 Add changelog entry for 7.5.1 2018-08-28 13:34:37 +03:00
Burak Velioglu eb2318f413
Merge pull request #2333 from citusdata/dml_on_ref_mx
Adds support for writing to reference tables from MX nodes.
2018-08-28 09:06:43 +03:00
velioglu bd30e3e908 Add support for writing to reference tables from MX nodes 2018-08-27 18:15:04 +03:00
velioglu 2639149bd8 Enterprise functions about metadata/resource locks 2018-08-27 16:32:20 +03:00
Önder Kalacı 6cea01620a
Merge pull request #2339 from citusdata/fix_modifying_cte
Make sure that modifying CTEs always use the correct execution mode
2018-08-23 15:44:38 +03:00
Onder Kalaci b8af8c359b Make sure that modifying CTEs always use the correct execution mode 2018-08-23 14:53:55 +03:00
Önder Kalacı 1abfce9969
Merge pull request #2346 from citusdata/fix_rte_walker
Improve query pushdown planning for very large number of shards and queries with many tables
2018-08-22 20:37:27 +03:00
Onder Kalaci 910ea392f5 Prevent multiple placements of a single shard to lead huge memory allocations 2018-08-22 19:25:01 +03:00
Onder Kalaci cb481f55cf Prevent excessive number of unnecessary range table traversal 2018-08-22 11:45:00 +03:00
Mehmet Furkan ŞAHİN 235542fe6b
Merge pull request #2342 from citusdata/applyLogRedactionNoop
ApplyLogRedaction noop func is added
2018-08-17 15:11:47 -07:00
mehmet furkan şahin ef9f38b68d ApplyLogRedaction noop func is added 2018-08-17 14:48:54 -07:00
Jason Petersen c3c0d62ca6
Add test showing poolinfo validation works
In other words, that it errors out.
2018-08-16 20:14:18 -06:00
Jason Petersen 900e88057c
Merge pull request #2341 from citusdata/disable_jit
Disable jit for now, make PG11 required

cr: @jasonmp85
2018-08-16 20:11:45 -06:00
Jason Petersen fd32c3590b
Mark PostgreSQL 11 builds as required
We will no longer accept regressions in our support for PostgreSQL 11.
2018-08-16 19:38:55 -06:00
Jason Petersen c4e2349b80
Mark failing PostgreSQL 11 test as ignored
This commit should be reverted once a new PostgreSQL 11 beta is
available: it's due to a bug in the partitioning code which has been
fixed in REL_11_STABLE but (not yet) a released tag.
2018-08-16 19:37:37 -06:00