Fix flaky Revised ITs failures on GHA runners (#14348)

* Fix read timed out failures and remove containers before test

* remove containers before loading images

* add labels to IT docker containers, download stable minio docker image release instead of latest
This commit is contained in:
Tejaswini Bandlamudi 2023-06-05 18:58:54 +05:30 committed by GitHub
parent 139156cf6b
commit 8e4f003f02
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 37 additions and 1 deletions

View File

@ -66,6 +66,8 @@ env:
AWS_ACCESS_KEY_ID: ${{ inputs.AWS_ACCESS_KEY_ID }} AWS_ACCESS_KEY_ID: ${{ inputs.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ inputs.AWS_SECRET_ACCESS_KEY }} AWS_SECRET_ACCESS_KEY: ${{ inputs.AWS_SECRET_ACCESS_KEY }}
SEGMENT_DOWNLOAD_TIMEOUT_MINS: 5 SEGMENT_DOWNLOAD_TIMEOUT_MINS: 5
DOCKER_CLIENT_TIMEOUT: 120
COMPOSE_HTTP_TIMEOUT: 120
jobs: jobs:
test: # GitHub job that runs a given revised/new IT against retrieved cached druid docker image test: # GitHub job that runs a given revised/new IT against retrieved cached druid docker image
@ -118,6 +120,12 @@ jobs:
echo $DRUID_IT_IMAGE_NAME echo $DRUID_IT_IMAGE_NAME
docker save "$DRUID_IT_IMAGE_NAME" | gzip > druid-container-jdk${{ inputs.build_jdk }}.tar.gz docker save "$DRUID_IT_IMAGE_NAME" | gzip > druid-container-jdk${{ inputs.build_jdk }}.tar.gz
- name: Stop and remove docker containers
run: |
echo "Force stopping all containers and pruning"
docker ps -aq --filter "label=druid-int-test=true" | xargs -r docker rm -f
docker system prune -af --volumes
- name: Load docker image - name: Load docker image
run: | run: |
docker load --input druid-container-jdk${{ inputs.build_jdk }}.tar.gz docker load --input druid-container-jdk${{ inputs.build_jdk }}.tar.gz

View File

@ -27,6 +27,8 @@ services:
zookeeper: zookeeper:
image: zookeeper:${ZK_VERSION} image: zookeeper:${ZK_VERSION}
container_name: zookeeper container_name: zookeeper
labels:
druid-int-test: "true"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.4 ipv4_address: 172.172.172.4
@ -42,6 +44,8 @@ services:
kafka: kafka:
image: bitnami/kafka:${KAFKA_VERSION} image: bitnami/kafka:${KAFKA_VERSION}
container_name: kafka container_name: kafka
labels:
druid-int-test: "true"
ports: ports:
- 9092:9092 - 9092:9092
- 9093:9093 - 9093:9093
@ -71,6 +75,8 @@ services:
# platform: linux/x86_64 # platform: linux/x86_64
image: mysql:$MYSQL_IMAGE_VERSION image: mysql:$MYSQL_IMAGE_VERSION
container_name: metadata container_name: metadata
labels:
druid-int-test: "true"
restart: always restart: always
command: command:
- --character-set-server=utf8mb4 - --character-set-server=utf8mb4
@ -89,11 +95,13 @@ services:
minio: minio:
container_name: minio container_name: minio
labels:
druid-int-test: "true"
command: server /data --console-address ":9001" command: server /data --console-address ":9001"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.5 ipv4_address: 172.172.172.5
image: minio/minio:latest image: minio/minio:RELEASE.2023-05-27T05-56-19Z
ports: ports:
- '9000:9000' - '9000:9000'
- '9001:9001' - '9001:9001'
@ -121,6 +129,8 @@ services:
openldap: openldap:
image: osixia/openldap:1.4.0 image: osixia/openldap:1.4.0
container_name: openldap container_name: openldap
labels:
druid-int-test: "true"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.102 ipv4_address: 172.172.172.102
@ -135,6 +145,8 @@ services:
schema-registry: schema-registry:
image: confluentinc/cp-schema-registry:5.5.1 image: confluentinc/cp-schema-registry:5.5.1
container_name: schema-registry container_name: schema-registry
labels:
druid-int-test: "true"
ports: ports:
- 8085:8085 - 8085:8085
networks: networks:
@ -157,6 +169,8 @@ services:
## Giving fake version ## Giving fake version
image: druid-it/hadoop:9.9.9 image: druid-it/hadoop:9.9.9
container_name: druid-it-hadoop container_name: druid-it-hadoop
labels:
druid-int-test: "true"
ports: ports:
- 2049:2049 - 2049:2049
- 2122:2122 - 2122:2122

View File

@ -48,6 +48,8 @@ services:
overlord: overlord:
image: ${DRUID_IT_IMAGE_NAME} image: ${DRUID_IT_IMAGE_NAME}
container_name: overlord container_name: overlord
labels:
druid-int-test: "true"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.10 ipv4_address: 172.172.172.10
@ -67,6 +69,8 @@ services:
coordinator: coordinator:
image: ${DRUID_IT_IMAGE_NAME} image: ${DRUID_IT_IMAGE_NAME}
container_name: coordinator container_name: coordinator
labels:
druid-int-test: "true"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.20 ipv4_address: 172.172.172.20
@ -86,6 +90,8 @@ services:
historical: historical:
image: ${DRUID_IT_IMAGE_NAME} image: ${DRUID_IT_IMAGE_NAME}
container_name: historical container_name: historical
labels:
druid-int-test: "true"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.30 ipv4_address: 172.172.172.30
@ -105,6 +111,8 @@ services:
middlemanager: middlemanager:
image: ${DRUID_IT_IMAGE_NAME} image: ${DRUID_IT_IMAGE_NAME}
container_name: middlemanager container_name: middlemanager
labels:
druid-int-test: "true"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.40 ipv4_address: 172.172.172.40
@ -136,6 +144,8 @@ services:
indexer: indexer:
image: ${DRUID_IT_IMAGE_NAME} image: ${DRUID_IT_IMAGE_NAME}
container_name: indexer container_name: indexer
labels:
druid-int-test: "true"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.50 ipv4_address: 172.172.172.50
@ -155,6 +165,8 @@ services:
broker: broker:
image: ${DRUID_IT_IMAGE_NAME} image: ${DRUID_IT_IMAGE_NAME}
container_name: broker container_name: broker
labels:
druid-int-test: "true"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.60 ipv4_address: 172.172.172.60
@ -174,6 +186,8 @@ services:
router: router:
image: ${DRUID_IT_IMAGE_NAME} image: ${DRUID_IT_IMAGE_NAME}
container_name: router container_name: router
labels:
druid-int-test: "true"
networks: networks:
druid-it-net: druid-it-net:
ipv4_address: 172.172.172.70 ipv4_address: 172.172.172.70