Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion ci/jobs/scripts/clickhouse_proc.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,19 @@ def start_azurite(self):
command, stdout=log_file, stderr=subprocess.STDOUT, shell=True
)
print(f"Started azurite asynchronously with PID {self.azurite_proc.pid}")
return True

print("Waiting for azurite to start...")
for _ in range(10):
res = Shell.check(
"curl -s -o /dev/null -w '%{http_code}' http://127.0.0.1:10000/ | grep -qE '400|200'",
verbose=False,
)
if res:
print("Azurite started successfully")
return True
time.sleep(3)
print("Failed to start azurite")
return False

@staticmethod
def log_cluster_config():
Expand Down Expand Up @@ -1048,6 +1060,8 @@ def set_random_timezone():
param = sys.argv[2]
assert param in ["stateless"]
res = ch.start_minio(param)
elif command == "start_azurite":
res = ch.start_azurite()
else:
raise ValueError(f"Unknown command: {command}")
except Exception as e:
Expand Down
1 change: 1 addition & 0 deletions tests/docker_scripts/stress_runner.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ configure
cd /repo && python3 /repo/ci/jobs/scripts/clickhouse_proc.py logs_export_config || echo "ERROR: Failed to create log export config"

cd /repo && python3 /repo/ci/jobs/scripts/clickhouse_proc.py start_minio stateless || { echo "Failed to start minio"; exit 1; }
cd /repo && python3 /repo/ci/jobs/scripts/clickhouse_proc.py start_azurite || { echo "Failed to start azurite"; exit 1; }

start_server || { echo "Failed to start server"; exit 1; }

Expand Down
Loading