Skip to content

Commit

Permalink
[FLINK-19619][e2e] Pin CloudSDK version to have access to pubsub emul…
Browse files Browse the repository at this point in the history
…ator in test

The :latest version of google/cloud-sdk:latest has the pubsub emulator disabled.

Google plans to add it again at a later point. See GoogleCloudPlatform/cloud-sdk-docker#225 for details.
  • Loading branch information
rmetzger committed Oct 19, 2020
1 parent 9eae578 commit 5ffdc4e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ public class GCloudEmulatorManager {
private static String dockerIpAddress = "127.0.0.1";

public static final String INTERNAL_PUBSUB_PORT = "22222";
public static final String DOCKER_IMAGE_NAME = "google/cloud-sdk:latest";
// TODO: use :latest again once https://github.com/GoogleCloudPlatform/cloud-sdk-docker/issues/225 is resolved.
public static final String DOCKER_IMAGE_NAME = "google/cloud-sdk:313.0.0";

private static String pubsubPort;

Expand Down Expand Up @@ -120,6 +121,7 @@ public static void launchDocker() throws DockerException, InterruptedException,
.cmd("sh", "-c", "mkdir -p /opt/data/pubsub ; gcloud beta emulators pubsub start --data-dir=/opt/data/pubsub --host-port=0.0.0.0:" + INTERNAL_PUBSUB_PORT)
.build();

LOG.debug("Launching container with configuration {}", containerConfig);
final ContainerCreation creation = docker.createContainer(containerConfig, CONTAINER_NAME_JUNIT);
id = creation.id();

Expand Down
3 changes: 1 addition & 2 deletions flink-end-to-end-tests/run-nightly-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,7 @@ if [[ ${PROFILE} != *"jdk11"* ]]; then
run_test "Run Mesos multiple submission test" "$END_TO_END_DIR/test-scripts/test_mesos_multiple_submissions.sh"

# `google/cloud-sdk` docker image doesn't support aarch64 currently.
# Disabled until https://issues.apache.org/jira/browse/FLINK-19619 is fixed.
#run_test "Test PubSub connector with Docker based Google PubSub Emulator" "$END_TO_END_DIR/test-scripts/test_streaming_gcp_pubsub.sh"
run_test "Test PubSub connector with Docker based Google PubSub Emulator" "$END_TO_END_DIR/test-scripts/test_streaming_gcp_pubsub.sh"
fi
fi

Expand Down

0 comments on commit 5ffdc4e

Please sign in to comment.