Removes large_table_shard_count GUC

pull/1991/head
velioglu 2018-02-01 13:59:44 +03:00 committed by Marco Slot
parent b1e6636398
commit 121ff39b26
93 changed files with 40 additions and 354 deletions

View File

@ -34,7 +34,6 @@
/* Config variables managed via guc.c */ /* Config variables managed via guc.c */
int LargeTableShardCount = 4; /* shard counts for a large table */
bool LogMultiJoinOrder = false; /* print join order as a debugging aid */ bool LogMultiJoinOrder = false; /* print join order as a debugging aid */
/* Function pointer type definition for join rule evaluation functions */ /* Function pointer type definition for join rule evaluation functions */

View File

@ -71,6 +71,7 @@ static bool StatisticsCollectionGucCheckHook(bool *newval, void **extra, GucSour
/* static variable to hold value of deprecated GUC variable */ /* static variable to hold value of deprecated GUC variable */
static bool ExpireCachedShards = false; static bool ExpireCachedShards = false;
static int LargeTableShardCount = 0;
/* *INDENT-OFF* */ /* *INDENT-OFF* */
@ -656,15 +657,12 @@ RegisterCitusConfigVariables(void)
DefineCustomIntVariable( DefineCustomIntVariable(
"citus.large_table_shard_count", "citus.large_table_shard_count",
gettext_noop("The shard count threshold over which a table is considered large."), gettext_noop("This variable has been deprecated."),
gettext_noop("A distributed table is considered to be large if it has " gettext_noop("Consider reference tables instead"),
"more shards than the value specified here. This largeness "
"criteria is then used in picking a table join order during "
"distributed query planning."),
&LargeTableShardCount, &LargeTableShardCount,
4, 1, 10000, 4, 1, 10000,
PGC_USERSET, PGC_USERSET,
0, GUC_NO_SHOW_ALL,
NULL, NULL, NULL); NULL, NULL, NULL);
DefineCustomIntVariable( DefineCustomIntVariable(

View File

@ -74,7 +74,6 @@ typedef struct JoinOrderNode
/* Config variables managed via guc.c */ /* Config variables managed via guc.c */
extern int LargeTableShardCount;
extern bool LogMultiJoinOrder; extern bool LogMultiJoinOrder;

View File

@ -73,7 +73,6 @@ check-multi-mx: all tempinstall-main
check-multi-task-tracker-extra: all tempinstall-main check-multi-task-tracker-extra: all tempinstall-main
$(pg_regress_multi_check) --load-extension=citus \ $(pg_regress_multi_check) --load-extension=citus \
--server-option=citus.task_executor_type=task-tracker \ --server-option=citus.task_executor_type=task-tracker \
--server-option=citus.large_table_shard_count=1 \
-- $(MULTI_REGRESS_OPTS) --schedule=$(citus_abs_srcdir)/multi_task_tracker_extra_schedule $(EXTRA_TESTS) -- $(MULTI_REGRESS_OPTS) --schedule=$(citus_abs_srcdir)/multi_task_tracker_extra_schedule $(EXTRA_TESTS)
check-follower-cluster: all check-follower-cluster: all

View File

@ -831,7 +831,6 @@ Aggregate
-> Seq Scan on lineitem_290001 lineitem -> Seq Scan on lineitem_290001 lineitem
Filter: (l_orderkey > 9030) Filter: (l_orderkey > 9030)
-- Test re-partition join -- Test re-partition join
SET citus.large_table_shard_count TO 1;
EXPLAIN (COSTS FALSE) EXPLAIN (COSTS FALSE)
SELECT count(*) SELECT count(*)
FROM lineitem, orders, customer_append, supplier_single_shard FROM lineitem, orders, customer_append, supplier_single_shard

View File

@ -831,7 +831,6 @@ Aggregate
-> Seq Scan on lineitem_290001 lineitem -> Seq Scan on lineitem_290001 lineitem
Filter: (l_orderkey > 9030) Filter: (l_orderkey > 9030)
-- Test re-partition join -- Test re-partition join
SET citus.large_table_shard_count TO 1;
EXPLAIN (COSTS FALSE) EXPLAIN (COSTS FALSE)
SELECT count(*) SELECT count(*)
FROM lineitem, orders, customer_append, supplier_single_shard FROM lineitem, orders, customer_append, supplier_single_shard

View File

@ -81,8 +81,6 @@ DEBUG: join prunable for intervals [8997,14947] and [1,5986]
explain statements for distributed queries are not enabled explain statements for distributed queries are not enabled
(2 rows) (2 rows)
-- Update configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO LOG; SET client_min_messages TO LOG;
-- The following queries check that we correctly handle joins and OR clauses. In -- The following queries check that we correctly handle joins and OR clauses. In
-- particular, these queries check that we factorize out OR clauses if possible, -- particular, these queries check that we factorize out OR clauses if possible,
@ -103,12 +101,6 @@ EXPLAIN SELECT l_quantity FROM lineitem, orders
LOG: join order: [ "lineitem" ][ cartesian product "orders" ] LOG: join order: [ "lineitem" ][ cartesian product "orders" ]
ERROR: cannot perform distributed planning on this query ERROR: cannot perform distributed planning on this query
DETAIL: Cartesian products are currently unsupported DETAIL: Cartesian products are currently unsupported
-- The below queries modify the partition method in pg_dist_partition. We thus
-- begin a transaction here so the changes don't impact any other parallel
-- running tests.
BEGIN;
-- Validate that we take into account the partition method when building the
-- join-order plan.
EXPLAIN SELECT count(*) FROM orders, lineitem_hash EXPLAIN SELECT count(*) FROM orders, lineitem_hash
WHERE o_orderkey = l_orderkey; WHERE o_orderkey = l_orderkey;
LOG: join order: [ "orders" ][ single partition join "lineitem_hash" ] LOG: join order: [ "orders" ][ single partition join "lineitem_hash" ]
@ -141,8 +133,6 @@ LOG: join order: [ "customer_hash" ][ reference join "nation" ]
explain statements for distributed queries are not enabled explain statements for distributed queries are not enabled
(3 rows) (3 rows)
-- Update the large table shard count for all the following tests.
SET citus.large_table_shard_count TO 1;
-- Validate that we don't use a single-partition join method for a hash -- Validate that we don't use a single-partition join method for a hash
-- re-partitioned table, thus preventing a partition of just the customer table. -- re-partitioned table, thus preventing a partition of just the customer table.
EXPLAIN SELECT count(*) FROM orders, lineitem, customer_append EXPLAIN SELECT count(*) FROM orders, lineitem, customer_append
@ -179,7 +169,6 @@ LOG: join order: [ "orders_hash" ][ single partition join "customer_append" ]
explain statements for distributed queries are not enabled explain statements for distributed queries are not enabled
(3 rows) (3 rows)
COMMIT;
-- Reset client logging level to its previous value -- Reset client logging level to its previous value
SET client_min_messages TO NOTICE; SET client_min_messages TO NOTICE;
DROP TABLE lineitem_hash; DROP TABLE lineitem_hash;

View File

@ -1,5 +1,5 @@
-- --
-- MULTI_JOIN_ORDER_TPCH_LARGE -- MULTI_JOIN_ORDER_TPCH_REPARTITION
-- --
SET citus.next_shard_id TO 660000; SET citus.next_shard_id TO 660000;
-- Enable configuration to print table join order -- Enable configuration to print table join order
@ -7,11 +7,9 @@ SET citus.explain_distributed_queries TO off;
SET citus.log_multi_join_order TO TRUE; SET citus.log_multi_join_order TO TRUE;
SET citus.task_executor_type = 'task-tracker'; -- can't explain all queries otherwise SET citus.task_executor_type = 'task-tracker'; -- can't explain all queries otherwise
SET client_min_messages TO LOG; SET client_min_messages TO LOG;
-- Change configuration to treat lineitem, orders, customer, and part tables as -- The following queries are basically the same as the ones in tpch_small
-- large. The following queries are basically the same as the ones in tpch_small
-- except that more data has been loaded into customer and part tables. Therefore, -- except that more data has been loaded into customer and part tables. Therefore,
-- we will apply different distributed join strategies for these queries. -- we will apply different distributed join strategies for these queries.
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
EXPLAIN SELECT EXPLAIN SELECT
sum(l_extendedprice * l_discount) as revenue sum(l_extendedprice * l_discount) as revenue

View File

@ -5,8 +5,6 @@
SET citus.explain_distributed_queries TO off; SET citus.explain_distributed_queries TO off;
SET citus.log_multi_join_order TO TRUE; SET citus.log_multi_join_order TO TRUE;
SET client_min_messages TO LOG; SET client_min_messages TO LOG;
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
EXPLAIN SELECT EXPLAIN SELECT
sum(l_extendedprice * l_discount) as revenue sum(l_extendedprice * l_discount) as revenue

View File

@ -1,13 +1,11 @@
-- --
-- MULTI_JOIN_PRUNING -- MULTI_JOIN_PRUNING
-- --
-- Check that join-pruning works for joins between two large relations. For now -- Check that join-pruning works for joins between two relations. For now
-- we only check for join-pruning between locally partitioned relations. In the -- we only check for join-pruning between locally partitioned relations. In the
-- future we want to check for pruning between re-partitioned relations as well. -- future we want to check for pruning between re-partitioned relations as well.
SET citus.explain_distributed_queries TO off; SET citus.explain_distributed_queries TO off;
SET client_min_messages TO DEBUG2; SET client_min_messages TO DEBUG2;
-- Change configuration to treat all tables as large
SET citus.large_table_shard_count TO 2;
SELECT sum(l_linenumber), avg(l_linenumber) FROM lineitem, orders SELECT sum(l_linenumber), avg(l_linenumber) FROM lineitem, orders
WHERE l_orderkey = o_orderkey; WHERE l_orderkey = o_orderkey;
DEBUG: join prunable for intervals [1,5986] and [8997,14947] DEBUG: join prunable for intervals [1,5986] and [8997,14947]

View File

@ -65,11 +65,8 @@ SELECT c_custkey, c_name, count(*) as lineitem_count
304 | Customer#000000304 | 31 304 | Customer#000000304 | 31
(10 rows) (10 rows)
-- Now, enable limit optimization to fetch half of each task's results. For this -- Now, enable limit optimization to fetch half of each task's results.
-- test, we also change a config setting to ensure that we don't repartition any
-- of the tables during the query.
SET citus.limit_clause_row_fetch_count TO 150; SET citus.limit_clause_row_fetch_count TO 150;
SET citus.large_table_shard_count TO 2;
SELECT c_custkey, c_name, count(*) as lineitem_count SELECT c_custkey, c_name, count(*) as lineitem_count
FROM customer, orders, lineitem FROM customer, orders, lineitem
WHERE c_custkey = o_custkey AND l_orderkey = o_orderkey WHERE c_custkey = o_custkey AND l_orderkey = o_orderkey
@ -90,7 +87,6 @@ DEBUG: push down of limit count: 150
304 | Customer#000000304 | 31 304 | Customer#000000304 | 31
(10 rows) (10 rows)
RESET citus.large_table_shard_count;
-- We now test scenarios where applying the limit optimization wouldn't produce -- We now test scenarios where applying the limit optimization wouldn't produce
-- meaningful results. First, we check that we don't push down the limit clause -- meaningful results. First, we check that we don't push down the limit clause
-- for non-commutative aggregates. -- for non-commutative aggregates.

View File

@ -496,7 +496,6 @@ Aggregate
-> Index Only Scan using lineitem_mx_pkey_1220052 on lineitem_mx_1220052 lineitem_mx -> Index Only Scan using lineitem_mx_pkey_1220052 on lineitem_mx_1220052 lineitem_mx
Index Cond: (l_orderkey > 9030) Index Cond: (l_orderkey > 9030)
-- Test re-partition join -- Test re-partition join
SET citus.large_table_shard_count TO 1;
EXPLAIN (COSTS FALSE) EXPLAIN (COSTS FALSE)
SELECT count(*) SELECT count(*)
FROM lineitem_mx, orders_mx, customer_mx, supplier_mx FROM lineitem_mx, orders_mx, customer_mx, supplier_mx

View File

@ -496,7 +496,6 @@ Aggregate
-> Index Only Scan using lineitem_mx_pkey_1220052 on lineitem_mx_1220052 lineitem_mx -> Index Only Scan using lineitem_mx_pkey_1220052 on lineitem_mx_1220052 lineitem_mx
Index Cond: (l_orderkey > 9030) Index Cond: (l_orderkey > 9030)
-- Test re-partition join -- Test re-partition join
SET citus.large_table_shard_count TO 1;
EXPLAIN (COSTS FALSE) EXPLAIN (COSTS FALSE)
SELECT count(*) SELECT count(*)
FROM lineitem_mx, orders_mx, customer_mx, supplier_mx FROM lineitem_mx, orders_mx, customer_mx, supplier_mx

View File

@ -166,7 +166,6 @@ SELECT * FROM repartition_udt JOIN repartition_udt_other
(0 rows) (0 rows)
-- Query that should result in a repartition join on UDT column. -- Query that should result in a repartition join on UDT column.
SET citus.large_table_shard_count = 1;
SET citus.log_multi_join_order = true; SET citus.log_multi_join_order = true;
EXPLAIN SELECT * FROM repartition_udt JOIN repartition_udt_other EXPLAIN SELECT * FROM repartition_udt JOIN repartition_udt_other
ON repartition_udt.udtcol = repartition_udt_other.udtcol ON repartition_udt.udtcol = repartition_udt_other.udtcol

View File

@ -4,7 +4,6 @@
\c - - - :worker_1_port \c - - - :worker_1_port
SET client_min_messages = LOG; SET client_min_messages = LOG;
-- Query that should result in a repartition join on UDT column. -- Query that should result in a repartition join on UDT column.
SET citus.large_table_shard_count = 1;
SET citus.task_executor_type = 'task-tracker'; SET citus.task_executor_type = 'task-tracker';
SET citus.log_multi_join_order = true; SET citus.log_multi_join_order = true;
-- Query that should result in a repartition -- Query that should result in a repartition

View File

@ -4,7 +4,6 @@
\c - - - :worker_2_port \c - - - :worker_2_port
SET client_min_messages = LOG; SET client_min_messages = LOG;
-- Query that should result in a repartition join on UDT column. -- Query that should result in a repartition join on UDT column.
SET citus.large_table_shard_count = 1;
SET citus.task_executor_type = 'task-tracker'; SET citus.task_executor_type = 'task-tracker';
SET citus.log_multi_join_order = true; SET citus.log_multi_join_order = true;
-- Query that should result in a repartition -- Query that should result in a repartition

View File

@ -57,7 +57,6 @@ INSERT INTO articles_hash_mx VALUES (48, 8, 'alkylic', 18610);
INSERT INTO articles_hash_mx VALUES (49, 9, 'anyone', 2681); INSERT INTO articles_hash_mx VALUES (49, 9, 'anyone', 2681);
INSERT INTO articles_hash_mx VALUES (50, 10, 'anjanette', 19519); INSERT INTO articles_hash_mx VALUES (50, 10, 'anjanette', 19519);
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO 'DEBUG2'; SET client_min_messages TO 'DEBUG2';
-- insert a single row for the test -- insert a single row for the test
INSERT INTO articles_single_shard_hash_mx VALUES (50, 10, 'anjanette', 19519); INSERT INTO articles_single_shard_hash_mx VALUES (50, 10, 'anjanette', 19519);

View File

@ -3,8 +3,6 @@
-- --
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #1 from the TPC-H decision support benchmark -- Query #1 from the TPC-H decision support benchmark
SELECT SELECT
l_returnflag, l_returnflag,
@ -37,8 +35,6 @@ ORDER BY
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #1 from the TPC-H decision support benchmark -- Query #1 from the TPC-H decision support benchmark
SELECT SELECT
l_returnflag, l_returnflag,
@ -71,8 +67,6 @@ ORDER BY
-- connect to the other node -- connect to the other node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #1 from the TPC-H decision support benchmark -- Query #1 from the TPC-H decision support benchmark
SELECT SELECT
l_returnflag, l_returnflag,

View File

@ -1,9 +1,7 @@
-- --
-- MULTI_MX_TPCH_QUERY10 -- MULTI_MX_TPCH_QUERY10
-- --
-- Query #10 from the TPC-H decision support benchmark. Unlike other TPC-H tests, -- Query #10 from the TPC-H decision support benchmark.
-- we don't set citus.large_table_shard_count here, and instead use the default value
-- coming from postgresql.conf or multi_task_tracker_executor.conf.
-- connect to master -- connect to master
\c - - - :master_port \c - - - :master_port
SELECT SELECT

View File

@ -3,8 +3,6 @@
-- --
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #12 from the TPC-H decision support benchmark -- Query #12 from the TPC-H decision support benchmark
SELECT SELECT
l_shipmode, l_shipmode,
@ -42,8 +40,6 @@ ORDER BY
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #12 from the TPC-H decision support benchmark -- Query #12 from the TPC-H decision support benchmark
SELECT SELECT
l_shipmode, l_shipmode,
@ -81,8 +77,6 @@ ORDER BY
-- connect to the other worker node -- connect to the other worker node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #12 from the TPC-H decision support benchmark -- Query #12 from the TPC-H decision support benchmark
SELECT SELECT
l_shipmode, l_shipmode,

View File

@ -3,8 +3,6 @@
-- --
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #14 from the TPC-H decision support benchmark -- Query #14 from the TPC-H decision support benchmark
SELECT SELECT
100.00 * sum(case 100.00 * sum(case
@ -26,8 +24,6 @@ WHERE
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #14 from the TPC-H decision support benchmark -- Query #14 from the TPC-H decision support benchmark
SELECT SELECT
100.00 * sum(case 100.00 * sum(case
@ -49,8 +45,6 @@ WHERE
-- connect to the other node -- connect to the other node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #14 from the TPC-H decision support benchmark -- Query #14 from the TPC-H decision support benchmark
SELECT SELECT
100.00 * sum(case 100.00 * sum(case

View File

@ -3,8 +3,6 @@
-- --
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #19 from the TPC-H decision support benchmark. Note that we modified -- Query #19 from the TPC-H decision support benchmark. Note that we modified
-- the query from its original to make it work on smaller data sets. -- the query from its original to make it work on smaller data sets.
SELECT SELECT
@ -43,8 +41,6 @@ WHERE
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #19 from the TPC-H decision support benchmark. Note that we modified -- Query #19 from the TPC-H decision support benchmark. Note that we modified
-- the query from its original to make it work on smaller data sets. -- the query from its original to make it work on smaller data sets.
SELECT SELECT
@ -83,8 +79,6 @@ WHERE
-- connect to the other node -- connect to the other node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #19 from the TPC-H decision support benchmark. Note that we modified -- Query #19 from the TPC-H decision support benchmark. Note that we modified
-- the query from its original to make it work on smaller data sets. -- the query from its original to make it work on smaller data sets.
SELECT SELECT

View File

@ -1,9 +1,7 @@
-- --
-- MULTI_MX_TPCH_QUERY3 -- MULTI_MX_TPCH_QUERY3
-- --
-- Query #3 from the TPC-H decision support benchmark. Unlike other TPC-H tests, -- Query #3 from the TPC-H decision support benchmark.
-- we don't set citus.large_table_shard_count here, and instead use the default value
-- coming from postgresql.conf or multi_task_tracker_executor.conf.
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
SELECT SELECT

View File

@ -3,8 +3,6 @@
-- --
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
SELECT SELECT
sum(l_extendedprice * l_discount) as revenue sum(l_extendedprice * l_discount) as revenue
@ -22,8 +20,6 @@ WHERE
-- connect to one of the worker nodes -- connect to one of the worker nodes
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
SELECT SELECT
sum(l_extendedprice * l_discount) as revenue sum(l_extendedprice * l_discount) as revenue
@ -41,8 +37,6 @@ WHERE
-- connect to the other worker node -- connect to the other worker node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
SELECT SELECT
sum(l_extendedprice * l_discount) as revenue sum(l_extendedprice * l_discount) as revenue

View File

@ -3,8 +3,6 @@
-- --
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem AND orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H decision support benchmark -- Query #7 from the TPC-H decision support benchmark
SELECT SELECT
supp_nation, supp_nation,
@ -52,8 +50,6 @@ ORDER BY
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem AND orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H decision support benchmark -- Query #7 from the TPC-H decision support benchmark
SELECT SELECT
supp_nation, supp_nation,
@ -101,8 +97,6 @@ ORDER BY
-- connect to the other worker node -- connect to the other worker node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem AND orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H decision support benchmark -- Query #7 from the TPC-H decision support benchmark
SELECT SELECT
supp_nation, supp_nation,

View File

@ -3,8 +3,6 @@
-- --
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem AND orders tables AS large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H benchmark; modified to include sub-selects -- Query #7 from the TPC-H benchmark; modified to include sub-selects
SELECT SELECT
supp_nation, supp_nation,
@ -61,8 +59,6 @@ ORDER BY
-- connect to one of the workers -- connect to one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem AND orders tables AS large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H benchmark; modified to include sub-selects -- Query #7 from the TPC-H benchmark; modified to include sub-selects
SELECT SELECT
supp_nation, supp_nation,
@ -119,8 +115,6 @@ ORDER BY
-- connect to the coordinator -- connect to the coordinator
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem AND orders tables AS large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H benchmark; modified to include sub-selects -- Query #7 from the TPC-H benchmark; modified to include sub-selects
SELECT SELECT
supp_nation, supp_nation,

View File

@ -18,7 +18,6 @@ SET citus.explain_all_tasks TO on;
-- because were testing pruning here. -- because were testing pruning here.
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';
-- Change configuration to treat lineitem and orders tables as large -- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
SET citus.log_multi_join_order to true; SET citus.log_multi_join_order to true;
SET citus.enable_repartition_joins to ON; SET citus.enable_repartition_joins to ON;
SELECT shardminvalue, shardmaxvalue from pg_dist_shard WHERE shardid = 290000; SELECT shardminvalue, shardmaxvalue from pg_dist_shard WHERE shardid = 290000;

View File

@ -18,7 +18,6 @@ SET citus.explain_all_tasks TO on;
-- because were testing pruning here. -- because were testing pruning here.
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';
-- Change configuration to treat lineitem and orders tables as large -- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
SET citus.log_multi_join_order to true; SET citus.log_multi_join_order to true;
SET citus.enable_repartition_joins to ON; SET citus.enable_repartition_joins to ON;
SELECT shardminvalue, shardmaxvalue from pg_dist_shard WHERE shardid = 290000; SELECT shardminvalue, shardmaxvalue from pg_dist_shard WHERE shardid = 290000;

View File

@ -18,7 +18,6 @@ SET citus.explain_all_tasks TO on;
-- because were testing pruning here. -- because were testing pruning here.
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';
-- Change configuration to treat lineitem and orders tables as large -- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
SET citus.log_multi_join_order to true; SET citus.log_multi_join_order to true;
SET citus.enable_repartition_joins to ON; SET citus.enable_repartition_joins to ON;
SELECT shardminvalue, shardmaxvalue from pg_dist_shard WHERE shardid = 290000; SELECT shardminvalue, shardmaxvalue from pg_dist_shard WHERE shardid = 290000;

View File

@ -1,7 +1,7 @@
-- --
-- MULTI_LARGE_TABLE_PLANNING -- MULTI_REPARTITION_JOIN_PLANNING
-- --
-- Tests that cover large table join planning. Note that we explicitly start a -- Tests that cover repartition join planning. Note that we explicitly start a
-- transaction block here so that we don't emit debug messages with changing -- transaction block here so that we don't emit debug messages with changing
-- transaction ids in them. Also, we set the executor type to task tracker -- transaction ids in them. Also, we set the executor type to task tracker
-- executor here, as we cannot run repartition jobs with real time executor. -- executor here, as we cannot run repartition jobs with real time executor.
@ -17,7 +17,6 @@ SELECT substring(:'server_version', '\d+')::int > 9 AS version_above_nine;
BEGIN; BEGIN;
SET client_min_messages TO DEBUG4; SET client_min_messages TO DEBUG4;
SET citus.large_table_shard_count TO 2;
SET citus.task_executor_type TO 'task-tracker'; SET citus.task_executor_type TO 'task-tracker';
-- Debug4 log messages display jobIds within them. We explicitly set the jobId -- Debug4 log messages display jobIds within them. We explicitly set the jobId
-- sequence here so that the regression output becomes independent of the number -- sequence here so that the regression output becomes independent of the number

View File

@ -1,7 +1,7 @@
-- --
-- MULTI_LARGE_TABLE_PLANNING -- MULTI_REPARTITION_JOIN_PLANNING
-- --
-- Tests that cover large table join planning. Note that we explicitly start a -- Tests that cover repartition join planning. Note that we explicitly start a
-- transaction block here so that we don't emit debug messages with changing -- transaction block here so that we don't emit debug messages with changing
-- transaction ids in them. Also, we set the executor type to task tracker -- transaction ids in them. Also, we set the executor type to task tracker
-- executor here, as we cannot run repartition jobs with real time executor. -- executor here, as we cannot run repartition jobs with real time executor.
@ -18,10 +18,6 @@ SELECT substring(:'server_version', '\d+')::int > 9 AS version_above_nine;
BEGIN; BEGIN;
SET client_min_messages TO DEBUG4; SET client_min_messages TO DEBUG4;
DEBUG: CommitTransactionCommand DEBUG: CommitTransactionCommand
SET citus.large_table_shard_count TO 2;
DEBUG: StartTransactionCommand
DEBUG: ProcessUtility
DEBUG: CommitTransactionCommand
SET citus.task_executor_type TO 'task-tracker'; SET citus.task_executor_type TO 'task-tracker';
DEBUG: StartTransactionCommand DEBUG: StartTransactionCommand
DEBUG: ProcessUtility DEBUG: ProcessUtility

View File

@ -1,11 +1,10 @@
-- --
-- MULTI_LARGE_TABLE_PRUNING -- MULTI_REPARTITION_JOIN_PRUNING
-- --
-- Tests covering partition and join-pruning for large table joins. Note that we -- Tests covering partition and join-pruning for repartition joins. Note that we
-- set executor type to task tracker executor here, as we cannot run repartition -- set executor type to task tracker executor here, as we cannot run repartition
-- jobs with real time executor. -- jobs with real time executor.
SET citus.next_shard_id TO 700000; SET citus.next_shard_id TO 700000;
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO DEBUG2; SET client_min_messages TO DEBUG2;
SET citus.task_executor_type TO 'task-tracker'; SET citus.task_executor_type TO 'task-tracker';
-- Single range-repartition join to test join-pruning behaviour. -- Single range-repartition join to test join-pruning behaviour.

View File

@ -1,5 +1,5 @@
-- --
-- MULTI_LARGE_TABLE_TASK_ASSIGNMENT -- MULTI_REPARTITION_JOIN_TASK_ASSIGNMENT
-- --
-- Tests which cover task assignment for MapMerge jobs for single range repartition -- Tests which cover task assignment for MapMerge jobs for single range repartition
-- and dual hash repartition joins. The tests also cover task assignment propagation -- and dual hash repartition joins. The tests also cover task assignment propagation
@ -16,7 +16,6 @@ SELECT substring(:'server_version', '\d+')::int > 9 AS version_above_nine;
BEGIN; BEGIN;
SET client_min_messages TO DEBUG3; SET client_min_messages TO DEBUG3;
SET citus.large_table_shard_count TO 2;
SET citus.task_executor_type TO 'task-tracker'; SET citus.task_executor_type TO 'task-tracker';
-- Single range repartition join to test anchor-shard based task assignment and -- Single range repartition join to test anchor-shard based task assignment and
-- assignment propagation to merge and data-fetch tasks. -- assignment propagation to merge and data-fetch tasks.
@ -51,8 +50,7 @@ DEBUG: assigned task 2 to node localhost:57637
-- Single range repartition join, along with a join with a small table containing -- Single range repartition join, along with a join with a small table containing
-- more than one shard. This situation results in multiple sql tasks depending on -- more than one shard. This situation results in multiple sql tasks depending on
-- the same merge task, and tests our constraint group creation and assignment -- the same merge task, and tests our constraint group creation and assignment
-- propagation. Here 'orders' is considered the small table. -- propagation.
SET citus.large_table_shard_count TO 3;
SELECT SELECT
count(*) count(*)
FROM FROM
@ -76,7 +74,6 @@ DEBUG: assigned task 2 to node localhost:57638
12000 12000
(1 row) (1 row)
SET citus.large_table_shard_count TO 2;
-- Dual hash repartition join which tests the separate hash repartition join -- Dual hash repartition join which tests the separate hash repartition join
-- task assignment algorithm. -- task assignment algorithm.
SELECT SELECT

View File

@ -1,5 +1,5 @@
-- --
-- MULTI_LARGE_TABLE_TASK_ASSIGNMENT -- MULTI_REPARTITION_JOIN_TASK_ASSIGNMENT
-- --
-- Tests which cover task assignment for MapMerge jobs for single range repartition -- Tests which cover task assignment for MapMerge jobs for single range repartition
-- and dual hash repartition joins. The tests also cover task assignment propagation -- and dual hash repartition joins. The tests also cover task assignment propagation
@ -17,10 +17,6 @@ SELECT substring(:'server_version', '\d+')::int > 9 AS version_above_nine;
BEGIN; BEGIN;
SET client_min_messages TO DEBUG3; SET client_min_messages TO DEBUG3;
DEBUG: CommitTransactionCommand DEBUG: CommitTransactionCommand
SET citus.large_table_shard_count TO 2;
DEBUG: StartTransactionCommand
DEBUG: ProcessUtility
DEBUG: CommitTransactionCommand
SET citus.task_executor_type TO 'task-tracker'; SET citus.task_executor_type TO 'task-tracker';
DEBUG: StartTransactionCommand DEBUG: StartTransactionCommand
DEBUG: ProcessUtility DEBUG: ProcessUtility
@ -60,11 +56,7 @@ DEBUG: CommitTransactionCommand
-- Single range repartition join, along with a join with a small table containing -- Single range repartition join, along with a join with a small table containing
-- more than one shard. This situation results in multiple sql tasks depending on -- more than one shard. This situation results in multiple sql tasks depending on
-- the same merge task, and tests our constraint group creation and assignment -- the same merge task, and tests our constraint group creation and assignment
-- propagation. Here 'orders' is considered the small table. -- propagation.
SET citus.large_table_shard_count TO 3;
DEBUG: StartTransactionCommand
DEBUG: ProcessUtility
DEBUG: CommitTransactionCommand
SELECT SELECT
count(*) count(*)
FROM FROM
@ -90,10 +82,6 @@ DEBUG: CommitTransactionCommand
12000 12000
(1 row) (1 row)
SET citus.large_table_shard_count TO 2;
DEBUG: StartTransactionCommand
DEBUG: ProcessUtility
DEBUG: CommitTransactionCommand
-- Dual hash repartition join which tests the separate hash repartition join -- Dual hash repartition join which tests the separate hash repartition join
-- task assignment algorithm. -- task assignment algorithm.
SELECT SELECT

View File

@ -175,7 +175,6 @@ SELECT * FROM repartition_udt JOIN repartition_udt_other
(0 rows) (0 rows)
-- Query that should result in a repartition join on UDT column. -- Query that should result in a repartition join on UDT column.
SET citus.large_table_shard_count = 1;
SET citus.task_executor_type = 'task-tracker'; SET citus.task_executor_type = 'task-tracker';
SET citus.log_multi_join_order = true; SET citus.log_multi_join_order = true;
EXPLAIN SELECT * FROM repartition_udt JOIN repartition_udt_other EXPLAIN SELECT * FROM repartition_udt JOIN repartition_udt_other

View File

@ -117,7 +117,6 @@ INSERT INTO articles_hash VALUES (48, 8, 'alkylic', 18610);
INSERT INTO articles_hash VALUES (49, 9, 'anyone', 2681); INSERT INTO articles_hash VALUES (49, 9, 'anyone', 2681);
INSERT INTO articles_hash VALUES (50, 10, 'anjanette', 19519); INSERT INTO articles_hash VALUES (50, 10, 'anjanette', 19519);
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO 'DEBUG2'; SET client_min_messages TO 'DEBUG2';
-- insert a single row for the test -- insert a single row for the test
INSERT INTO articles_single_shard_hash VALUES (50, 10, 'anjanette', 19519); INSERT INTO articles_single_shard_hash VALUES (50, 10, 'anjanette', 19519);

View File

@ -215,7 +215,6 @@ SELECT * FROM articles WHERE author_id IN (SELECT id FROM authors WHERE name LIK
(0 rows) (0 rows)
-- subqueries are supported in FROM clause -- subqueries are supported in FROM clause
SET citus.large_table_shard_count TO 1;
SELECT articles.id,test.word_count SELECT articles.id,test.word_count
FROM articles, (SELECT id, word_count FROM articles) AS test WHERE test.id = articles.id FROM articles, (SELECT id, word_count FROM articles) AS test WHERE test.id = articles.id
ORDER BY articles.id; ORDER BY articles.id;
@ -273,7 +272,6 @@ ORDER BY articles.id;
50 | 19519 50 | 19519
(50 rows) (50 rows)
RESET citus.large_table_shard_count;
-- subqueries are not supported in SELECT clause -- subqueries are not supported in SELECT clause
SELECT a.title AS name, (SELECT a2.id FROM articles_single_shard a2 WHERE a.id = a2.id LIMIT 1) SELECT a.title AS name, (SELECT a2.id FROM articles_single_shard a2 WHERE a.id = a2.id LIMIT 1)
AS special_price FROM articles a; AS special_price FROM articles a;
@ -408,7 +406,6 @@ SELECT o_orderstatus, sum(l_linenumber), avg(l_linenumber) FROM lineitem, orders
-- now, test the cases where Citus do or do not need to create -- now, test the cases where Citus do or do not need to create
-- the master queries -- the master queries
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO 'DEBUG2'; SET client_min_messages TO 'DEBUG2';
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';
-- start with the simple lookup query -- start with the simple lookup query

View File

@ -212,12 +212,10 @@ SELECT * FROM articles, position('om' in 'Thomas') ORDER BY 2 DESC, 1 DESC, 3 DE
SELECT * FROM articles WHERE author_id IN (SELECT id FROM authors WHERE name LIKE '%a'); SELECT * FROM articles WHERE author_id IN (SELECT id FROM authors WHERE name LIKE '%a');
ERROR: Complex subqueries and CTEs are not supported when task_executor_type is set to 'task-tracker' ERROR: Complex subqueries and CTEs are not supported when task_executor_type is set to 'task-tracker'
-- subqueries are supported in FROM clause -- subqueries are supported in FROM clause
SET citus.large_table_shard_count TO 1;
SELECT articles.id,test.word_count SELECT articles.id,test.word_count
FROM articles, (SELECT id, word_count FROM articles) AS test WHERE test.id = articles.id FROM articles, (SELECT id, word_count FROM articles) AS test WHERE test.id = articles.id
ORDER BY articles.id; ORDER BY articles.id;
ERROR: Complex subqueries and CTEs are not supported when task_executor_type is set to 'task-tracker' ERROR: Complex subqueries and CTEs are not supported when task_executor_type is set to 'task-tracker'
RESET citus.large_table_shard_count;
-- subqueries are not supported in SELECT clause -- subqueries are not supported in SELECT clause
SELECT a.title AS name, (SELECT a2.id FROM articles_single_shard a2 WHERE a.id = a2.id LIMIT 1) SELECT a.title AS name, (SELECT a2.id FROM articles_single_shard a2 WHERE a.id = a2.id LIMIT 1)
AS special_price FROM articles a; AS special_price FROM articles a;
@ -352,7 +350,6 @@ SELECT o_orderstatus, sum(l_linenumber), avg(l_linenumber) FROM lineitem, orders
-- now, test the cases where Citus do or do not need to create -- now, test the cases where Citus do or do not need to create
-- the master queries -- the master queries
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO 'DEBUG2'; SET client_min_messages TO 'DEBUG2';
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';
-- start with the simple lookup query -- start with the simple lookup query

View File

@ -1,8 +1,6 @@
-- --
-- MULTI_TPCH_QUERY1 -- MULTI_TPCH_QUERY1
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #1 from the TPC-H decision support benchmark -- Query #1 from the TPC-H decision support benchmark
SELECT SELECT
l_returnflag, l_returnflag,

View File

@ -1,9 +1,7 @@
-- --
-- MULTI_TPCH_QUERY10 -- MULTI_TPCH_QUERY10
-- --
-- Query #10 from the TPC-H decision support benchmark. Unlike other TPC-H tests, -- Query #10 from the TPC-H decision support benchmark.
-- we don't set citus.large_table_shard_count here, and instead use the default value
-- coming from postgresql.conf or multi_task_tracker_executor.conf.
SELECT SELECT
c_custkey, c_custkey,
c_name, c_name,

View File

@ -1,8 +1,6 @@
-- --
-- MULTI_TPCH_QUERY12 -- MULTI_TPCH_QUERY12
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #12 from the TPC-H decision support benchmark -- Query #12 from the TPC-H decision support benchmark
SELECT SELECT
l_shipmode, l_shipmode,

View File

@ -1,8 +1,6 @@
-- --
-- MULTI_TPCH_QUERY14 -- MULTI_TPCH_QUERY14
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #14 from the TPC-H decision support benchmark -- Query #14 from the TPC-H decision support benchmark
SELECT SELECT
100.00 * sum(case 100.00 * sum(case

View File

@ -1,8 +1,6 @@
-- --
-- MULTI_TPCH_QUERY19 -- MULTI_TPCH_QUERY19
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #19 from the TPC-H decision support benchmark. Note that we modified -- Query #19 from the TPC-H decision support benchmark. Note that we modified
-- the query from its original to make it work on smaller data sets. -- the query from its original to make it work on smaller data sets.
SELECT SELECT

View File

@ -1,9 +1,7 @@
-- --
-- MULTI_TPCH_QUERY3 -- MULTI_TPCH_QUERY3
-- --
-- Query #3 from the TPC-H decision support benchmark. Unlike other TPC-H tests, -- Query #3 from the TPC-H decision support benchmark.
-- we don't set citus.large_table_shard_count here, and instead use the default value
-- coming from postgresql.conf or multi_task_tracker_executor.conf.
SELECT SELECT
l_orderkey, l_orderkey,
sum(l_extendedprice * (1 - l_discount)) as revenue, sum(l_extendedprice * (1 - l_discount)) as revenue,

View File

@ -1,8 +1,6 @@
-- --
-- MULTI_TPCH_QUERY6 -- MULTI_TPCH_QUERY6
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
SELECT SELECT
sum(l_extendedprice * l_discount) as revenue sum(l_extendedprice * l_discount) as revenue

View File

@ -1,8 +1,6 @@
-- --
-- MULTI_TPCH_QUERY7 -- MULTI_TPCH_QUERY7
-- --
-- Change configuration to treat lineitem AND orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H decision support benchmark -- Query #7 from the TPC-H decision support benchmark
SELECT SELECT
supp_nation, supp_nation,

View File

@ -1,8 +1,6 @@
-- --
-- MULTI_TPCH_QUERY7_NESTED -- MULTI_TPCH_QUERY7_NESTED
-- --
-- Change configuration to treat lineitem AND orders tables AS large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H benchmark; modified to include sub-selects -- Query #7 from the TPC-H benchmark; modified to include sub-selects
SELECT SELECT
supp_nation, supp_nation,

View File

@ -39,7 +39,6 @@ SELECT * FROM lineitem_pricing_summary ORDER BY l_returnflag, l_linestatus;
(4 rows) (4 rows)
-- Test we can handle joins -- Test we can handle joins
SET citus.large_table_shard_count TO 2;
CREATE TABLE shipping_priority AS CREATE TABLE shipping_priority AS
( (
SELECT SELECT

View File

@ -9,7 +9,6 @@ SELECT master_create_distributed_table('test_table_1', 'id', 'append');
(1 row) (1 row)
SET citus.large_table_shard_count to 1;
\copy test_table_1 FROM STDIN DELIMITER ',' \copy test_table_1 FROM STDIN DELIMITER ','
\copy test_table_1 FROM STDIN DELIMITER ',' \copy test_table_1 FROM STDIN DELIMITER ','
CREATE TABLE test_table_2(id int, value_1 int); CREATE TABLE test_table_2(id int, value_1 int);

View File

@ -47,14 +47,12 @@ SELECT avg(distinct l_orderkey) FROM lineitem_range;
-- sharded table. For this test, we also change a config setting to ensure that -- sharded table. For this test, we also change a config setting to ensure that
-- we don't repartition any of the tables during the query. -- we don't repartition any of the tables during the query.
SET citus.large_table_shard_count TO 2;
SELECT p_partkey, count(distinct l_orderkey) FROM lineitem_range, part SELECT p_partkey, count(distinct l_orderkey) FROM lineitem_range, part
WHERE l_partkey = p_partkey WHERE l_partkey = p_partkey
GROUP BY p_partkey GROUP BY p_partkey
ORDER BY p_partkey LIMIT 10; ORDER BY p_partkey LIMIT 10;
RESET citus.large_table_shard_count;
-- Check that we support count(distinct) on non-partition column. -- Check that we support count(distinct) on non-partition column.
SELECT count(distinct l_partkey) FROM lineitem_range; SELECT count(distinct l_partkey) FROM lineitem_range;

View File

@ -2,7 +2,6 @@
SET citus.next_shard_id TO 310000; SET citus.next_shard_id TO 310000;
SET citus.large_table_shard_count TO 2;
SET citus.log_multi_join_order to true; SET citus.log_multi_join_order to true;
SET client_min_messages TO LOG; SET client_min_messages TO LOG;

View File

@ -85,14 +85,14 @@ test: multi_tpch_query7 multi_tpch_query7_nested
# ---------- # ----------
test: multi_join_order_tpch_small multi_join_order_additional test: multi_join_order_tpch_small multi_join_order_additional
test: multi_load_more_data test: multi_load_more_data
test: multi_join_order_tpch_large test: multi_join_order_tpch_repartition
# ---------- # ----------
# Tests for large-table join planning and execution. Be careful when creating # Tests for repartition join planning and execution. Be careful when creating
# new shards before these tests, as they expect specific shard identifiers in # new shards before these tests, as they expect specific shard identifiers in
# the output. # the output.
# ---------- # ----------
test: multi_large_table_join_planning multi_large_table_pruning multi_large_table_task_assignment test: multi_repartition_join_planning multi_repartition_join_pruning multi_repartition_join_task_assignment
# --------- # ---------
# Tests for recursive planning. # Tests for recursive planning.

View File

@ -51,7 +51,7 @@ test: multi_tpch_query7 multi_tpch_query7_nested
# below; and therefore these tests should come after the execution tests. # below; and therefore these tests should come after the execution tests.
# ---------- # ----------
test: multi_load_more_data test: multi_load_more_data
test: multi_join_order_tpch_large test: multi_join_order_tpch_repartition
# ---------- # ----------
# Tests to check our large record loading and shard deletion behavior # Tests to check our large record loading and shard deletion behavior

View File

@ -53,7 +53,6 @@ SELECT avg(distinct l_orderkey) FROM lineitem_range;
-- Run count(distinct) on join between a range partitioned table and a single -- Run count(distinct) on join between a range partitioned table and a single
-- sharded table. For this test, we also change a config setting to ensure that -- sharded table. For this test, we also change a config setting to ensure that
-- we don't repartition any of the tables during the query. -- we don't repartition any of the tables during the query.
SET citus.large_table_shard_count TO 2;
SELECT p_partkey, count(distinct l_orderkey) FROM lineitem_range, part SELECT p_partkey, count(distinct l_orderkey) FROM lineitem_range, part
WHERE l_partkey = p_partkey WHERE l_partkey = p_partkey
GROUP BY p_partkey GROUP BY p_partkey
@ -72,7 +71,6 @@ SELECT p_partkey, count(distinct l_orderkey) FROM lineitem_range, part
222 | 1 222 | 1
(10 rows) (10 rows)
RESET citus.large_table_shard_count;
-- Check that we support count(distinct) on non-partition column. -- Check that we support count(distinct) on non-partition column.
SELECT count(distinct l_partkey) FROM lineitem_range; SELECT count(distinct l_partkey) FROM lineitem_range;
count count

View File

@ -1,5 +1,4 @@
SET citus.next_shard_id TO 310000; SET citus.next_shard_id TO 310000;
SET citus.large_table_shard_count TO 2;
SET citus.log_multi_join_order to true; SET citus.log_multi_join_order to true;
SET client_min_messages TO LOG; SET client_min_messages TO LOG;
CREATE TABLE multi_outer_join_left CREATE TABLE multi_outer_join_left

View File

@ -400,7 +400,6 @@ EXPLAIN (COSTS FALSE)
SELECT avg(l_linenumber) FROM lineitem WHERE l_orderkey > 9030; SELECT avg(l_linenumber) FROM lineitem WHERE l_orderkey > 9030;
-- Test re-partition join -- Test re-partition join
SET citus.large_table_shard_count TO 1;
EXPLAIN (COSTS FALSE) EXPLAIN (COSTS FALSE)
SELECT count(*) SELECT count(*)

View File

@ -69,9 +69,6 @@ SET client_min_messages TO DEBUG2;
EXPLAIN SELECT l1.l_quantity FROM lineitem l1, lineitem l2 EXPLAIN SELECT l1.l_quantity FROM lineitem l1, lineitem l2
WHERE l1.l_orderkey = l2.l_orderkey AND l1.l_quantity > 5; WHERE l1.l_orderkey = l2.l_orderkey AND l1.l_quantity > 5;
-- Update configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO LOG; SET client_min_messages TO LOG;
-- The following queries check that we correctly handle joins and OR clauses. In -- The following queries check that we correctly handle joins and OR clauses. In
@ -85,14 +82,6 @@ EXPLAIN SELECT count(*) FROM lineitem, orders
EXPLAIN SELECT l_quantity FROM lineitem, orders EXPLAIN SELECT l_quantity FROM lineitem, orders
WHERE (l_orderkey = o_orderkey OR l_quantity > 5); WHERE (l_orderkey = o_orderkey OR l_quantity > 5);
-- The below queries modify the partition method in pg_dist_partition. We thus
-- begin a transaction here so the changes don't impact any other parallel
-- running tests.
BEGIN;
-- Validate that we take into account the partition method when building the
-- join-order plan.
EXPLAIN SELECT count(*) FROM orders, lineitem_hash EXPLAIN SELECT count(*) FROM orders, lineitem_hash
WHERE o_orderkey = l_orderkey; WHERE o_orderkey = l_orderkey;
@ -104,9 +93,6 @@ EXPLAIN SELECT count(*) FROM orders_hash, lineitem_hash
EXPLAIN SELECT count(*) FROM customer_hash, nation EXPLAIN SELECT count(*) FROM customer_hash, nation
WHERE c_nationkey = n_nationkey; WHERE c_nationkey = n_nationkey;
-- Update the large table shard count for all the following tests.
SET citus.large_table_shard_count TO 1;
-- Validate that we don't use a single-partition join method for a hash -- Validate that we don't use a single-partition join method for a hash
-- re-partitioned table, thus preventing a partition of just the customer table. -- re-partitioned table, thus preventing a partition of just the customer table.
EXPLAIN SELECT count(*) FROM orders, lineitem, customer_append EXPLAIN SELECT count(*) FROM orders, lineitem, customer_append
@ -122,8 +108,6 @@ EXPLAIN SELECT count(*) FROM orders, customer_hash
EXPLAIN SELECT count(*) FROM orders_hash, customer_append EXPLAIN SELECT count(*) FROM orders_hash, customer_append
WHERE c_custkey = o_custkey; WHERE c_custkey = o_custkey;
COMMIT;
-- Reset client logging level to its previous value -- Reset client logging level to its previous value
SET client_min_messages TO NOTICE; SET client_min_messages TO NOTICE;

View File

@ -1,5 +1,5 @@
-- --
-- MULTI_JOIN_ORDER_TPCH_LARGE -- MULTI_JOIN_ORDER_TPCH_REPARTITION
-- --
@ -13,13 +13,10 @@ SET citus.log_multi_join_order TO TRUE;
SET citus.task_executor_type = 'task-tracker'; -- can't explain all queries otherwise SET citus.task_executor_type = 'task-tracker'; -- can't explain all queries otherwise
SET client_min_messages TO LOG; SET client_min_messages TO LOG;
-- Change configuration to treat lineitem, orders, customer, and part tables as -- The following queries are basically the same as the ones in tpch_small
-- large. The following queries are basically the same as the ones in tpch_small
-- except that more data has been loaded into customer and part tables. Therefore, -- except that more data has been loaded into customer and part tables. Therefore,
-- we will apply different distributed join strategies for these queries. -- we will apply different distributed join strategies for these queries.
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
EXPLAIN SELECT EXPLAIN SELECT

View File

@ -8,10 +8,6 @@ SET citus.explain_distributed_queries TO off;
SET citus.log_multi_join_order TO TRUE; SET citus.log_multi_join_order TO TRUE;
SET client_min_messages TO LOG; SET client_min_messages TO LOG;
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
EXPLAIN SELECT EXPLAIN SELECT

View File

@ -3,18 +3,13 @@
-- --
-- Check that join-pruning works for joins between two relations. For now
-- Check that join-pruning works for joins between two large relations. For now
-- we only check for join-pruning between locally partitioned relations. In the -- we only check for join-pruning between locally partitioned relations. In the
-- future we want to check for pruning between re-partitioned relations as well. -- future we want to check for pruning between re-partitioned relations as well.
SET citus.explain_distributed_queries TO off; SET citus.explain_distributed_queries TO off;
SET client_min_messages TO DEBUG2; SET client_min_messages TO DEBUG2;
-- Change configuration to treat all tables as large
SET citus.large_table_shard_count TO 2;
SELECT sum(l_linenumber), avg(l_linenumber) FROM lineitem, orders SELECT sum(l_linenumber), avg(l_linenumber) FROM lineitem, orders
WHERE l_orderkey = o_orderkey; WHERE l_orderkey = o_orderkey;

View File

@ -34,12 +34,9 @@ SELECT c_custkey, c_name, count(*) as lineitem_count
GROUP BY c_custkey, c_name GROUP BY c_custkey, c_name
ORDER BY lineitem_count DESC, c_custkey LIMIT 10; ORDER BY lineitem_count DESC, c_custkey LIMIT 10;
-- Now, enable limit optimization to fetch half of each task's results. For this -- Now, enable limit optimization to fetch half of each task's results.
-- test, we also change a config setting to ensure that we don't repartition any
-- of the tables during the query.
SET citus.limit_clause_row_fetch_count TO 150; SET citus.limit_clause_row_fetch_count TO 150;
SET citus.large_table_shard_count TO 2;
SELECT c_custkey, c_name, count(*) as lineitem_count SELECT c_custkey, c_name, count(*) as lineitem_count
FROM customer, orders, lineitem FROM customer, orders, lineitem
@ -47,8 +44,6 @@ SELECT c_custkey, c_name, count(*) as lineitem_count
GROUP BY c_custkey, c_name GROUP BY c_custkey, c_name
ORDER BY lineitem_count DESC, c_custkey LIMIT 10; ORDER BY lineitem_count DESC, c_custkey LIMIT 10;
RESET citus.large_table_shard_count;
-- We now test scenarios where applying the limit optimization wouldn't produce -- We now test scenarios where applying the limit optimization wouldn't produce
-- meaningful results. First, we check that we don't push down the limit clause -- meaningful results. First, we check that we don't push down the limit clause
-- for non-commutative aggregates. -- for non-commutative aggregates.

View File

@ -173,7 +173,6 @@ EXPLAIN (COSTS FALSE)
SELECT avg(l_linenumber) FROM lineitem_mx WHERE l_orderkey > 9030; SELECT avg(l_linenumber) FROM lineitem_mx WHERE l_orderkey > 9030;
-- Test re-partition join -- Test re-partition join
SET citus.large_table_shard_count TO 1;
EXPLAIN (COSTS FALSE) EXPLAIN (COSTS FALSE)
SELECT count(*) SELECT count(*)

View File

@ -199,7 +199,6 @@ SELECT * FROM repartition_udt JOIN repartition_udt_other
ON repartition_udt.pk = repartition_udt_other.pk; ON repartition_udt.pk = repartition_udt_other.pk;
-- Query that should result in a repartition join on UDT column. -- Query that should result in a repartition join on UDT column.
SET citus.large_table_shard_count = 1;
SET citus.log_multi_join_order = true; SET citus.log_multi_join_order = true;
EXPLAIN SELECT * FROM repartition_udt JOIN repartition_udt_other EXPLAIN SELECT * FROM repartition_udt JOIN repartition_udt_other

View File

@ -5,7 +5,6 @@
\c - - - :worker_1_port \c - - - :worker_1_port
SET client_min_messages = LOG; SET client_min_messages = LOG;
-- Query that should result in a repartition join on UDT column. -- Query that should result in a repartition join on UDT column.
SET citus.large_table_shard_count = 1;
SET citus.task_executor_type = 'task-tracker'; SET citus.task_executor_type = 'task-tracker';
SET citus.log_multi_join_order = true; SET citus.log_multi_join_order = true;

View File

@ -5,7 +5,6 @@
\c - - - :worker_2_port \c - - - :worker_2_port
SET client_min_messages = LOG; SET client_min_messages = LOG;
-- Query that should result in a repartition join on UDT column. -- Query that should result in a repartition join on UDT column.
SET citus.large_table_shard_count = 1;
SET citus.task_executor_type = 'task-tracker'; SET citus.task_executor_type = 'task-tracker';
SET citus.log_multi_join_order = true; SET citus.log_multi_join_order = true;

View File

@ -65,7 +65,6 @@ INSERT INTO articles_hash_mx VALUES (50, 10, 'anjanette', 19519);
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO 'DEBUG2'; SET client_min_messages TO 'DEBUG2';
-- insert a single row for the test -- insert a single row for the test

View File

@ -6,10 +6,6 @@
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #1 from the TPC-H decision support benchmark -- Query #1 from the TPC-H decision support benchmark
SELECT SELECT
@ -37,10 +33,6 @@ ORDER BY
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #1 from the TPC-H decision support benchmark -- Query #1 from the TPC-H decision support benchmark
SELECT SELECT
@ -68,10 +60,6 @@ ORDER BY
-- connect to the other node -- connect to the other node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #1 from the TPC-H decision support benchmark -- Query #1 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -2,9 +2,7 @@
-- MULTI_MX_TPCH_QUERY10 -- MULTI_MX_TPCH_QUERY10
-- --
-- Query #10 from the TPC-H decision support benchmark. Unlike other TPC-H tests, -- Query #10 from the TPC-H decision support benchmark.
-- we don't set citus.large_table_shard_count here, and instead use the default value
-- coming from postgresql.conf or multi_task_tracker_executor.conf.
-- connect to master -- connect to master

View File

@ -6,10 +6,6 @@
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #12 from the TPC-H decision support benchmark -- Query #12 from the TPC-H decision support benchmark
SELECT SELECT
@ -44,10 +40,6 @@ ORDER BY
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #12 from the TPC-H decision support benchmark -- Query #12 from the TPC-H decision support benchmark
SELECT SELECT
@ -82,10 +74,6 @@ ORDER BY
-- connect to the other worker node -- connect to the other worker node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #12 from the TPC-H decision support benchmark -- Query #12 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -6,10 +6,6 @@
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #14 from the TPC-H decision support benchmark -- Query #14 from the TPC-H decision support benchmark
SELECT SELECT
@ -29,10 +25,6 @@ WHERE
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #14 from the TPC-H decision support benchmark -- Query #14 from the TPC-H decision support benchmark
SELECT SELECT
@ -52,10 +44,6 @@ WHERE
-- connect to the other node -- connect to the other node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #14 from the TPC-H decision support benchmark -- Query #14 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -6,10 +6,6 @@
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #19 from the TPC-H decision support benchmark. Note that we modified -- Query #19 from the TPC-H decision support benchmark. Note that we modified
-- the query from its original to make it work on smaller data sets. -- the query from its original to make it work on smaller data sets.
@ -46,10 +42,6 @@ WHERE
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #19 from the TPC-H decision support benchmark. Note that we modified -- Query #19 from the TPC-H decision support benchmark. Note that we modified
-- the query from its original to make it work on smaller data sets. -- the query from its original to make it work on smaller data sets.
@ -86,10 +78,6 @@ WHERE
-- connect to the other node -- connect to the other node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #19 from the TPC-H decision support benchmark. Note that we modified -- Query #19 from the TPC-H decision support benchmark. Note that we modified
-- the query from its original to make it work on smaller data sets. -- the query from its original to make it work on smaller data sets.

View File

@ -2,9 +2,7 @@
-- MULTI_MX_TPCH_QUERY3 -- MULTI_MX_TPCH_QUERY3
-- --
-- Query #3 from the TPC-H decision support benchmark. Unlike other TPC-H tests, -- Query #3 from the TPC-H decision support benchmark.
-- we don't set citus.large_table_shard_count here, and instead use the default value
-- coming from postgresql.conf or multi_task_tracker_executor.conf.
-- connect to the coordinator -- connect to the coordinator

View File

@ -6,10 +6,6 @@
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
SELECT SELECT
@ -25,10 +21,6 @@ WHERE
-- connect to one of the worker nodes -- connect to one of the worker nodes
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
SELECT SELECT
@ -44,10 +36,6 @@ WHERE
-- connect to the other worker node -- connect to the other worker node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -6,10 +6,6 @@
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem AND orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H decision support benchmark -- Query #7 from the TPC-H decision support benchmark
SELECT SELECT
@ -55,10 +51,6 @@ ORDER BY
-- connect one of the workers -- connect one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem AND orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H decision support benchmark -- Query #7 from the TPC-H decision support benchmark
SELECT SELECT
@ -104,10 +96,6 @@ ORDER BY
-- connect to the other worker node -- connect to the other worker node
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem AND orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H decision support benchmark -- Query #7 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -6,10 +6,6 @@
-- connect to the coordinator -- connect to the coordinator
\c - - - :master_port \c - - - :master_port
-- Change configuration to treat lineitem AND orders tables AS large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H benchmark; modified to include sub-selects -- Query #7 from the TPC-H benchmark; modified to include sub-selects
SELECT SELECT
@ -64,10 +60,6 @@ ORDER BY
-- connect to one of the workers -- connect to one of the workers
\c - - - :worker_1_port \c - - - :worker_1_port
-- Change configuration to treat lineitem AND orders tables AS large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H benchmark; modified to include sub-selects -- Query #7 from the TPC-H benchmark; modified to include sub-selects
SELECT SELECT
@ -122,10 +114,6 @@ ORDER BY
-- connect to the coordinator -- connect to the coordinator
\c - - - :worker_2_port \c - - - :worker_2_port
-- Change configuration to treat lineitem AND orders tables AS large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H benchmark; modified to include sub-selects -- Query #7 from the TPC-H benchmark; modified to include sub-selects
SELECT SELECT

View File

@ -20,7 +20,6 @@ SET citus.task_executor_type TO 'real-time';
-- Change configuration to treat lineitem and orders tables as large -- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
SET citus.log_multi_join_order to true; SET citus.log_multi_join_order to true;
SET citus.enable_repartition_joins to ON; SET citus.enable_repartition_joins to ON;

View File

@ -1,7 +1,7 @@
-- --
-- MULTI_LARGE_TABLE_PLANNING -- MULTI_REPARTITION_JOIN_PLANNING
-- --
-- Tests that cover large table join planning. Note that we explicitly start a -- Tests that cover repartition join planning. Note that we explicitly start a
-- transaction block here so that we don't emit debug messages with changing -- transaction block here so that we don't emit debug messages with changing
-- transaction ids in them. Also, we set the executor type to task tracker -- transaction ids in them. Also, we set the executor type to task tracker
-- executor here, as we cannot run repartition jobs with real time executor. -- executor here, as we cannot run repartition jobs with real time executor.
@ -16,7 +16,6 @@ SELECT substring(:'server_version', '\d+')::int > 9 AS version_above_nine;
BEGIN; BEGIN;
SET client_min_messages TO DEBUG4; SET client_min_messages TO DEBUG4;
SET citus.large_table_shard_count TO 2;
SET citus.task_executor_type TO 'task-tracker'; SET citus.task_executor_type TO 'task-tracker';
-- Debug4 log messages display jobIds within them. We explicitly set the jobId -- Debug4 log messages display jobIds within them. We explicitly set the jobId

View File

@ -1,7 +1,7 @@
-- --
-- MULTI_LARGE_TABLE_PRUNING -- MULTI_REPARTITION_JOIN_PRUNING
-- --
-- Tests covering partition and join-pruning for large table joins. Note that we -- Tests covering partition and join-pruning for repartition joins. Note that we
-- set executor type to task tracker executor here, as we cannot run repartition -- set executor type to task tracker executor here, as we cannot run repartition
-- jobs with real time executor. -- jobs with real time executor.
@ -9,7 +9,6 @@
SET citus.next_shard_id TO 700000; SET citus.next_shard_id TO 700000;
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO DEBUG2; SET client_min_messages TO DEBUG2;
SET citus.task_executor_type TO 'task-tracker'; SET citus.task_executor_type TO 'task-tracker';

View File

@ -1,5 +1,5 @@
-- --
-- MULTI_LARGE_TABLE_TASK_ASSIGNMENT -- MULTI_REPARTITION_JOIN_TASK_ASSIGNMENT
-- --
-- Tests which cover task assignment for MapMerge jobs for single range repartition -- Tests which cover task assignment for MapMerge jobs for single range repartition
-- and dual hash repartition joins. The tests also cover task assignment propagation -- and dual hash repartition joins. The tests also cover task assignment propagation
@ -16,7 +16,6 @@ SELECT substring(:'server_version', '\d+')::int > 9 AS version_above_nine;
BEGIN; BEGIN;
SET client_min_messages TO DEBUG3; SET client_min_messages TO DEBUG3;
SET citus.large_table_shard_count TO 2;
SET citus.task_executor_type TO 'task-tracker'; SET citus.task_executor_type TO 'task-tracker';
-- Single range repartition join to test anchor-shard based task assignment and -- Single range repartition join to test anchor-shard based task assignment and
@ -32,9 +31,7 @@ WHERE
-- Single range repartition join, along with a join with a small table containing -- Single range repartition join, along with a join with a small table containing
-- more than one shard. This situation results in multiple sql tasks depending on -- more than one shard. This situation results in multiple sql tasks depending on
-- the same merge task, and tests our constraint group creation and assignment -- the same merge task, and tests our constraint group creation and assignment
-- propagation. Here 'orders' is considered the small table. -- propagation.
SET citus.large_table_shard_count TO 3;
SELECT SELECT
count(*) count(*)
@ -44,7 +41,6 @@ WHERE
o_custkey = c_custkey AND o_custkey = c_custkey AND
o_orderkey = l_orderkey; o_orderkey = l_orderkey;
SET citus.large_table_shard_count TO 2;
-- Dual hash repartition join which tests the separate hash repartition join -- Dual hash repartition join which tests the separate hash repartition join
-- task assignment algorithm. -- task assignment algorithm.

View File

@ -197,7 +197,6 @@ SELECT * FROM repartition_udt JOIN repartition_udt_other
WHERE repartition_udt.pk = 1; WHERE repartition_udt.pk = 1;
-- Query that should result in a repartition join on UDT column. -- Query that should result in a repartition join on UDT column.
SET citus.large_table_shard_count = 1;
SET citus.task_executor_type = 'task-tracker'; SET citus.task_executor_type = 'task-tracker';
SET citus.log_multi_join_order = true; SET citus.log_multi_join_order = true;

View File

@ -104,7 +104,6 @@ INSERT INTO articles_hash VALUES (50, 10, 'anjanette', 19519);
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO 'DEBUG2'; SET client_min_messages TO 'DEBUG2';
-- insert a single row for the test -- insert a single row for the test

View File

@ -133,14 +133,10 @@ SELECT * FROM articles WHERE author_id IN (SELECT id FROM authors WHERE name LIK
-- subqueries are supported in FROM clause -- subqueries are supported in FROM clause
SET citus.large_table_shard_count TO 1;
SELECT articles.id,test.word_count SELECT articles.id,test.word_count
FROM articles, (SELECT id, word_count FROM articles) AS test WHERE test.id = articles.id FROM articles, (SELECT id, word_count FROM articles) AS test WHERE test.id = articles.id
ORDER BY articles.id; ORDER BY articles.id;
RESET citus.large_table_shard_count;
-- subqueries are not supported in SELECT clause -- subqueries are not supported in SELECT clause
SELECT a.title AS name, (SELECT a2.id FROM articles_single_shard a2 WHERE a.id = a2.id LIMIT 1) SELECT a.title AS name, (SELECT a2.id FROM articles_single_shard a2 WHERE a.id = a2.id LIMIT 1)
AS special_price FROM articles a; AS special_price FROM articles a;
@ -216,7 +212,6 @@ SELECT o_orderstatus, sum(l_linenumber), avg(l_linenumber) FROM lineitem, orders
-- now, test the cases where Citus do or do not need to create -- now, test the cases where Citus do or do not need to create
-- the master queries -- the master queries
SET citus.large_table_shard_count TO 2;
SET client_min_messages TO 'DEBUG2'; SET client_min_messages TO 'DEBUG2';
SET citus.task_executor_type TO 'real-time'; SET citus.task_executor_type TO 'real-time';

View File

@ -3,10 +3,6 @@
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #1 from the TPC-H decision support benchmark -- Query #1 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -2,9 +2,7 @@
-- MULTI_TPCH_QUERY10 -- MULTI_TPCH_QUERY10
-- --
-- Query #10 from the TPC-H decision support benchmark. Unlike other TPC-H tests, -- Query #10 from the TPC-H decision support benchmark.
-- we don't set citus.large_table_shard_count here, and instead use the default value
-- coming from postgresql.conf or multi_task_tracker_executor.conf.
SELECT SELECT

View File

@ -3,10 +3,6 @@
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #12 from the TPC-H decision support benchmark -- Query #12 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -3,10 +3,6 @@
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #14 from the TPC-H decision support benchmark -- Query #14 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -3,10 +3,6 @@
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #19 from the TPC-H decision support benchmark. Note that we modified -- Query #19 from the TPC-H decision support benchmark. Note that we modified
-- the query from its original to make it work on smaller data sets. -- the query from its original to make it work on smaller data sets.

View File

@ -2,9 +2,7 @@
-- MULTI_TPCH_QUERY3 -- MULTI_TPCH_QUERY3
-- --
-- Query #3 from the TPC-H decision support benchmark. Unlike other TPC-H tests, -- Query #3 from the TPC-H decision support benchmark.
-- we don't set citus.large_table_shard_count here, and instead use the default value
-- coming from postgresql.conf or multi_task_tracker_executor.conf.
SELECT SELECT

View File

@ -3,10 +3,6 @@
-- --
-- Change configuration to treat lineitem and orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #6 from the TPC-H decision support benchmark -- Query #6 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -3,10 +3,6 @@
-- --
-- Change configuration to treat lineitem AND orders tables as large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H decision support benchmark -- Query #7 from the TPC-H decision support benchmark
SELECT SELECT

View File

@ -3,10 +3,6 @@
-- --
-- Change configuration to treat lineitem AND orders tables AS large
SET citus.large_table_shard_count TO 2;
-- Query #7 from the TPC-H benchmark; modified to include sub-selects -- Query #7 from the TPC-H benchmark; modified to include sub-selects
SELECT SELECT

View File

@ -39,8 +39,6 @@ SELECT * FROM lineitem_pricing_summary ORDER BY l_returnflag, l_linestatus;
-- Test we can handle joins -- Test we can handle joins
SET citus.large_table_shard_count TO 2;
CREATE TABLE shipping_priority AS CREATE TABLE shipping_priority AS
( (
SELECT SELECT

View File

@ -6,7 +6,6 @@
CREATE TABLE test_table_1(id int, value_1 int); CREATE TABLE test_table_1(id int, value_1 int);
SELECT master_create_distributed_table('test_table_1', 'id', 'append'); SELECT master_create_distributed_table('test_table_1', 'id', 'append');
SET citus.large_table_shard_count to 1;
\copy test_table_1 FROM STDIN DELIMITER ',' \copy test_table_1 FROM STDIN DELIMITER ','
1,2 1,2