Commit Graph

7031 Commits (leftjoin_push)

Author SHA1 Message Date
Metin Doslu 7d0c90b398 Fail fast on constraint violations in router executor 2016-06-07 18:11:17 +03:00
Metin Doslu 15eed396b3 Update ereport format 2016-06-07 15:58:32 +03:00
Metin Döşlü 8bac89b663 Merge pull request #576 from citusdata/hash-partitioned_master_update_shard_statistics
Update only shard length on statistics update for hash/range-partitioned tables
2016-06-07 15:35:51 +03:00
Metin Doslu 28a16beba7 Update only shard length on statistics update for hash-partitioned
Update only the shard length on master_update_shard_statistics() call for
hash-partitioned tables.

Fixes #519.
2016-06-07 15:04:29 +03:00
Ahmet Eren Basak 8be3ca7c4b Merge pull request #575 from citusdata/tests_with_explicit_shardid_jobid
Set Explicit ShardId/JobId In Regression Tests
2016-06-07 15:02:01 +03:00
Eren 5512bb359a Set Explicit ShardId/JobId In Regression Tests
Fixes #271

This change sets ShardIds and JobIds for each test case. Before this change,
when a new test that somehow increments Job or Shard IDs is added, then
the tests after the new test should be updated.

ShardID and JobID sequences are set at the beginning of each file with the
following commands:

```
ALTER SEQUENCE pg_catalog.pg_dist_shardid_seq RESTART 290000;
ALTER SEQUENCE pg_catalog.pg_dist_jobid_seq RESTART 290000;
```

ShardIds and JobIds are multiples of 10000. Exceptions are:
- multi_large_shardid: shardid and jobid sequences are set to much larger values
- multi_fdw_large_shardid: same as above
- multi_join_pruning: Causes a race condition with multi_hash_pruning since
they are run in parallel.
2016-06-07 14:32:44 +03:00
Murat Tuncer 46fcbd1ff9 Merge pull request #548 from citusdata/feature/manual_ddl_propagation
Add enable_ddl_propagation flag to control automatic ddl propagation
2016-06-06 14:08:47 +03:00
Murat Tuncer 360e884de1 Add enable_ddl_propagation flag to control automatic ddl propagation 2016-06-06 13:42:46 +03:00
Murat Tuncer 3c0673be51 Merge pull request #535 from citusdata/fix/equality_operator_check
Change equality operator check for operator expressions
2016-06-06 12:51:28 +03:00
Murat Tuncer 20ba0f72a6 Change equality operator check for operator expressions 2016-06-06 12:34:16 +03:00
Burak Yücesoy d6b30a66db Merge pull request #536 from citusdata/fix/fix_302_update_test_to_create_hash_partitioned_table
Update regression tests where metadata edited manually
2016-06-04 17:10:22 +03:00
Burak Yücesoy 2f096cad74 Update regression tests where metadata edited manually
Fixes #302

Since our previous syntax did not allow creating hash partitioned tables,
some of the previous tests manually changed partition method to hash to
be able to test it. With this change we remove unnecessary workaround and
create hash distributed tables instead. Also in some tests metadata was
created manually. With this change we also fixed this issue.
2016-06-04 13:50:42 +00:00
Jason Petersen 29343b7340
Omit open- tracking branches from build 2016-06-03 18:01:36 -06:00
Jason Petersen 5fe36a7179
Add Travis step to sync master to open-master 2016-06-03 13:52:52 -06:00
Burak Yücesoy b9dc906ab5 Merge pull request #544 from citusdata/fix/fix_475_remove_only_clause_from_worker_queries
Remove ONLY clause from worker queries
2016-06-03 11:53:01 +03:00
Burak Yucesoy 5db357eb1a Remove ONLY clause from worker queries
Fixes #475

With this change we prevent addition of ONLY clause to queries prepared for
worker nodes. When we add ONLY clause we may miss the inherited tables in
worker nodes created by users manually.
2016-06-03 11:42:43 +03:00
Jason Petersen 027a7a717d Merge pull request #391 from citusdata/feature/rely-less-on-remote-task-check-interval
Prototype: Rely less on remote_task_check_interval.

cr: @jasonmp85
2016-06-02 12:34:25 -06:00
Andres Freund 3dac0a4d14
Rely less on remote_task_check_interval.
When executing queries with citus.task_executor = 'real-time', query
execution could, so far, spend a significant amount of time
sleeping. That's because we were
a) sleeping after several phases of query execution, even if we're not
   waiting for network IO
b) sleeping for a fixed amount of time when waiting for network IO;
   often a lot longer than actually required.
Just reducing the amount of time slept isn't a real solution, because
that just increases CPU usage.

Instead have the real-time executor's ManageTaskExecution return whether
a task is currently being processed, waiting for reads or writes, or
failed. When all tasks are waiting for IO use poll() to wait for IO
readyness.

That requires to slightly redefine how connection timeouts are handled:
before we counted the number of times ManageTaskExecution() was called,
and compared that with the timeout divided by the task check
interval. That, if processing of tasks took a while, could significantly
increase the time till a timeout occurred. Because it was based on the
ManageTaskExecution() being called on a constant interval, this approach
isn't feasible anymore.  Instead measure the actual time since
connection establishment was started. That could in theory, if task
processing takes a very long time, lead to few passes over
PQconnectPoll().

The problem of sleeping too much also exists for the 'task-tracker'
executor, but is generally less problematic there, as processing the
individual tasks usually will take longer. That said, for e.g. the
regression tests it'd be helpful to use a similar approach.
2016-06-02 12:11:16 -06:00
Metin Döşlü ae8ba2ac52 Merge pull request #570 from citusdata/move_master_update_shard_statistics_to_pg_catalog
Move master_update_shard_statistics() to pg_catalog

cr: @marcocitus
2016-06-02 13:22:44 +03:00
Metin Doslu d4c4eaa9ff Move master_update_shard_statistics() to pg_catalog
Fixes #546
2016-06-02 10:52:47 +03:00
Jason Petersen 87d6a7e897
Merge branch amosbird:remove-redundant-functions
Closes #523
cr: @jasonmp85
2016-05-27 15:13:53 -06:00
Jason Petersen e774f22ed4
Fix formatting
Checking in citus_indent output.
2016-05-27 15:13:28 -06:00
Amos Bird 92788a0d9c
Remove redundant implementations of error funcs.
This patch does some basic cleaning jobs. It removes duplicated
implementations of ReportRemoteError() and related ones and adjusts
regression tests.
2016-05-27 15:12:59 -06:00
Jason Petersen c0c71cb8c5
Merge branch credativ:reproducible
cr: @jasonmp85
2016-05-27 12:45:55 -06:00
Jason Petersen e71fe3ef47
Merge branch infracaninophile:freebsd-fixes2
Closes #541
cr: @jasonmp85
2016-05-27 12:36:58 -06:00
Matthew Seaman 332c322b4f
Add inet includes for htonl and htons funtions
Needed to fix FreeBSD builds.
2016-05-27 12:36:12 -06:00
Murat Tuncer 24e1224eac Merge pull request #516 from citusdata/feature/fix_434_support_count_distinct
Add complex count distinct support
2016-05-27 15:55:47 +03:00
Murat Tuncer 2b0d6473b9 Add complex distinct count support for repartitioned subqueries
Single table repartition subqueries now support count(distinct column)
and count(distinct (case when ...)) expressions. Repartition query
extracts column used in aggregate expression and adds them to target
list and group by list, master query stays the same (count (distinct ...))
but attribute numbers inside the aggregate expression is modified to
reflect changes in repartition query.
2016-05-27 15:43:05 +03:00
Metin Döşlü b520fb7448 Merge pull request #489 from citusdata/respect_guc_in_master_create_empty_shard
Make master_create_empty_shard() aware of the shard placement policy

cr: @marcocitus
2016-05-27 15:13:23 +03:00
Metin Doslu afa74ce5ca Make master_create_empty_shard() aware of the shard placement policy
Now, master_create_empty_shard() will create shards according to the
value of citus.shard_placement_policy which also makes default round-robin
instead of random.
2016-05-27 15:05:53 +03:00
Ahmet Eren Basak 2148922cb2 Merge pull request #486 from citusdata/multi_shard_delete
ADD master_modify_multiple_shards UDF
2016-05-26 17:37:07 +03:00
eren 132d9212d0 ADD master_modify_multiple_shards UDF
Fixes #10

This change creates a new UDF: master_modify_multiple_shards
Parameters:
  modify_query: A simple DELETE or UPDATE query as a string.

The UDF is similar to the existing master_apply_delete_command UDF.
Basically, given the modify query, it prunes the shard list, re-constructs
the query for each shard and sends the query to the placements.

Depending on the value of citus.multi_shard_commit_protocol, the commit
can be done in one-phase or two-phase manner.

Limitations:
* It cannot be called inside a transaction block
* It only be called with simple operator expressions (like Single Shard Modify)

Sample Usage:
```
SELECT master_modify_multiple_shards(
  'DELETE FROM customer_delete_protocol WHERE c_custkey > 500 AND c_custkey < 500');
```
2016-05-26 17:30:35 +03:00
Burak Yücesoy c75df74348 Merge pull request #517 from citusdata/fix/fix_469_rename_ReceiveRegularFile
Change duplicated function name - RecieveRegularFile()
2016-05-26 14:05:55 +03:00
Burak Yucesoy 0e71ffd937 Fix #469
This change renames one of the ReceiveRegularFile functions with
more descriptive name.
2016-05-26 12:03:36 +03:00
Christoph Berg 7df82baf46 Sort list of objects in src/backend/distributed/Makefile
Make's $(wildcard) does not sort the glob result, but returns filenames
in filesystem ordering. This makes the build result vary and hence
unreproducible on the binary level. Fix by adding $(sort).

Spotted by Debian's reproducible builds project.
2016-05-18 10:42:20 +02:00
Jason Petersen ad61d4ae06 Merge pull request #531 from citusdata/update_changelog
Add CHANGELOG entries for 5.1 release

cr: @sumedhpathak
2016-05-17 10:13:57 -06:00
Jason Petersen a7ae634750
Add CHANGELOG entries for 5.1 release
Probably a superset of what we actually want, but should be complete.
2016-05-17 10:02:05 -06:00
Jason Petersen 4ca4f10966
Add multi_copy test outputs to gitignore 2016-05-10 13:36:56 -06:00
Jason Petersen 61b6394e4b
Add gitignore rules for latest install files
Got tired of dirty git tree.
2016-05-10 11:57:11 -06:00
Jason Petersen d76ead817b
Add latest CHANGELOG entries 2016-05-10 11:57:00 -06:00
Önder Kalacı de3bcc4364 Merge pull request #495 from citusdata/fix/494_invalid_distributed_explain_json
Distributed EXPLAIN: Generate valid JSON output
2016-05-06 15:01:49 +03:00
Marco Slot 1b4fbc76e2 Add JSON/XML validation to EXPLAIN regression tests and fix issues 2016-05-06 11:30:07 +02:00
Lukas Fittl 2f694f7af3 Distributed EXPLAIN: Generate valid JSON output.
This modifies the EXPLAIN output functions to actually generate
valid JSON output when (FORMAT JSON) is being used.

Fixes #494.
2016-05-05 12:48:01 +02:00
Önder Kalacı ca909a71fc Merge pull request #498 from citusdata/fix_check_full_failure
Fix check-full failures
2016-05-05 13:43:24 +03:00
Onder Kalaci d7fd56df89 Fix check-full failures
This commit fixes failures happen during check-full. The change does make
clean seperation of executor types in certain places to keep the outputs
stable.
2016-05-05 12:28:22 +03:00
Jason Petersen eab60e20de
Add CHANGELOG entry for 5.0.1 2016-05-04 22:07:43 -06:00
Andres Freund 2eb386dcf7 Merge pull request #493 from citusdata/stamp-5.1
Stamp 5.1

CR: Jason
2016-05-04 18:47:01 -07:00
Andres Freund 5f282dd241 Stamp 5.1 release. 2016-05-04 18:05:41 -07:00
Andres Freund 4d7bcfdd35 Generate extension versions from the previous one. 2016-05-04 18:05:41 -07:00
Önder Kalacı 5604669db5 Merge pull request #487 from citusdata/fix_compile_warning
Fix compile time warning
2016-05-04 09:52:05 +03:00