mirror of https://github.com/citusdata/citus.git
Increase parallelism
parent
d9e36820f4
commit
56abd3d501
|
@ -171,6 +171,7 @@ jobs:
|
|||
|
||||
test-arbitrary-configs:
|
||||
description: Runs tests on arbitrary configs
|
||||
parallelism: 6
|
||||
parameters:
|
||||
pg_major:
|
||||
description: 'postgres major version to use'
|
||||
|
@ -207,9 +208,14 @@ jobs:
|
|||
- run:
|
||||
name: 'Test arbitrary configs'
|
||||
command: |
|
||||
TESTS=$(src/test/regress/citus_tests/print_test_names.py | circleci tests split)
|
||||
# Our test suite expects comma separated values
|
||||
TESTS=$(echo $TESTS | tr ' ' ',')
|
||||
# TESTS will contain subset of configs that will be run on a container and we use multiple containers
|
||||
# to run the test suite
|
||||
gosu circleci \
|
||||
make -C src/test/regress \
|
||||
check-arbitrary-configs parallel=4
|
||||
check-arbitrary-configs parallel=4 CONFIGS=$TESTS
|
||||
no_output_timeout: 2m
|
||||
- run:
|
||||
name: 'Show regressions'
|
||||
|
|
|
@ -25,7 +25,6 @@ import concurrent.futures
|
|||
import multiprocessing
|
||||
from docopt import docopt
|
||||
import time
|
||||
import inspect
|
||||
import random
|
||||
|
||||
|
||||
|
@ -173,10 +172,7 @@ def read_configs(docoptRes):
|
|||
# We fill the configs from all of the possible classes in config.py so that if we add a new config,
|
||||
# we don't need to add it here. And this avoids the problem where we forget to add it here
|
||||
for x in cfg.__dict__.values():
|
||||
if inspect.isclass(x) and (
|
||||
issubclass(x, cfg.CitusMXBaseClusterConfig)
|
||||
or issubclass(x, cfg.CitusDefaultClusterConfig)
|
||||
):
|
||||
if cfg.should_include_config(x):
|
||||
configs.append(x(docoptRes))
|
||||
return configs
|
||||
|
||||
|
|
|
@ -5,6 +5,7 @@ from contextlib import closing
|
|||
import os
|
||||
import threading
|
||||
import common
|
||||
import inspect
|
||||
|
||||
COORDINATOR_NAME = "coordinator"
|
||||
WORKER1 = "worker1"
|
||||
|
@ -55,6 +56,16 @@ PORT_UPPER = 32768
|
|||
port_lock = threading.Lock()
|
||||
|
||||
|
||||
def should_include_config(class_name):
|
||||
|
||||
if inspect.isclass(class_name) and (
|
||||
issubclass(class_name, CitusMXBaseClusterConfig)
|
||||
or issubclass(class_name, CitusDefaultClusterConfig)
|
||||
):
|
||||
return True
|
||||
return False
|
||||
|
||||
|
||||
def find_free_port():
|
||||
global next_port
|
||||
with port_lock:
|
||||
|
|
|
@ -0,0 +1,23 @@
|
|||
#!/usr/bin/env python3
|
||||
|
||||
import config as cfg
|
||||
|
||||
|
||||
def read_config_names():
|
||||
config_names = []
|
||||
# We fill the configs from all of the possible classes in config.py so that if we add a new config,
|
||||
# we don't need to add it here. And this avoids the problem where we forget to add it here
|
||||
for x in cfg.__dict__.values():
|
||||
if cfg.should_include_config(x):
|
||||
config_names.append(x.__name__)
|
||||
return config_names
|
||||
|
||||
|
||||
def print_config_names():
|
||||
config_names = read_config_names()
|
||||
for config_name in config_names:
|
||||
print(config_name)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
print_config_names()
|
Loading…
Reference in New Issue