From 065c0a76e9ec9a773735ebe1d9de9a137ddfaa94 Mon Sep 17 00:00:00 2001 From: Yunze Xu Date: Sun, 4 Feb 2024 20:03:30 +0800 Subject: [PATCH] Disable topic level policies to make tests work --- pulsar-test-service-start.sh | 4 ++-- test-conf/standalone-ssl-mim.conf | 5 +++++ test-conf/standalone-ssl.conf | 9 +++++---- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/pulsar-test-service-start.sh b/pulsar-test-service-start.sh index 9c6209e7..23f70102 100755 --- a/pulsar-test-service-start.sh +++ b/pulsar-test-service-start.sh @@ -25,12 +25,12 @@ SRC_DIR=$PWD ./pulsar-test-service-stop.sh -CONTAINER_ID=$(docker run -i --user $(id -u) -p 8080:8080 -p 6650:6650 -p 8443:8443 -p 6651:6651 --rm --detach apachepulsar/pulsar:3.1.1 sleep 3600) +CONTAINER_ID=$(docker run -i --user $(id -u) -p 8080:8080 -p 6650:6650 -p 8443:8443 -p 6651:6651 --rm --detach apachepulsar/pulsar:latest sleep 3600) build-support/setup-test-service-container.sh $CONTAINER_ID start-test-service-inside-container.sh docker cp $CONTAINER_ID:/pulsar/data/tokens/token.txt .test-token.txt -CONTAINER_ID=$(docker run -i --user $(id -u) -p 8081:8081 -p 6652:6652 -p 8444:8444 -p 6653:6653 --rm --detach apachepulsar/pulsar:3.1.1 sleep 3600) +CONTAINER_ID=$(docker run -i --user $(id -u) -p 8081:8081 -p 6652:6652 -p 8444:8444 -p 6653:6653 --rm --detach apachepulsar/pulsar:latest sleep 3600) build-support/setup-test-service-container.sh $CONTAINER_ID start-mim-test-service-inside-container.sh echo "-- Ready to start tests" diff --git a/test-conf/standalone-ssl-mim.conf b/test-conf/standalone-ssl-mim.conf index 359645ea..198a9002 100644 --- a/test-conf/standalone-ssl-mim.conf +++ b/test-conf/standalone-ssl-mim.conf @@ -307,3 +307,8 @@ maxMessageSize=1024000 # Disable consistent hashing to fix flaky `KeySharedConsumerTest#testMultiTopics`. subscriptionKeySharedUseConsistentHashing=false + +# It's true by default since 2.11. After https://github.com/apache/pulsar/pull/21445, we must configure +# brokerClientAuthenticationPlugin and brokerClientAuthenticationParameters correctly when enabling topic +# level policies. Otherwise, no topic could be loaded. +topicLevelPoliciesEnabled=false diff --git a/test-conf/standalone-ssl.conf b/test-conf/standalone-ssl.conf index 4b150076..36ad9b56 100644 --- a/test-conf/standalone-ssl.conf +++ b/test-conf/standalone-ssl.conf @@ -19,10 +19,6 @@ ### --- General broker settings --- ### -# Disable system topic -systemTopicEnabled=false -topicLevelPoliciesEnabled=false - # Zookeeper quorum connection string zookeeperServers= @@ -317,3 +313,8 @@ subscriptionKeySharedUseConsistentHashing=false # Enable batch index ACK acknowledgmentAtBatchIndexLevelEnabled=true + +# It's true by default since 2.11. After https://github.com/apache/pulsar/pull/21445, we must configure +# brokerClientAuthenticationPlugin and brokerClientAuthenticationParameters correctly when enabling topic +# level policies. Otherwise, no topic could be loaded. +topicLevelPoliciesEnabled=false