Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ST] default builders for plain/tls internal clients #9658

Merged
merged 18 commits into from
Mar 22, 2024

Conversation

henryZrncik
Copy link
Contributor

@henryZrncik henryZrncik commented Feb 8, 2024

Type of change

  • Refactoring

Description

Changes described by files:

TestConstants and TestStorage

Concerned mainly with new fields (added for smooth work with continuous clients)

  • continuousProducerName (All 3 same as their basic counterparts but with extra suffix)
  • continuousConsumerName
  • continuousTopicName
  • continuousMessageCount (300 in comparison to 100)

ClientUtils

Primarily following methods added:

  • getInstantPlainClientBuilder
  • getInstantTlsClientBuilder
  • getContinuousPlainClientBuilder
  • getContinuousTlsClientBuilder

Continuous methods are waiting for continuous, clients with respective teststorage.fields.

as these clients are basically hello world (used to be called that way).
there is additionaly namespace and default user which are there for completness.

Any of them can be changed and as can be seen in specific tests they sometimes are which makes it visible what is actually important about given producer/consumer.

additional helper method waitForContinuousClientSuccess which waits specifically for continuous clients.

<specific>ST classes

changes include:

  • replacing Environment.TEST_SUITE_NAMESPACE with testStorage atlernative.
  • removal of unncessary names for producer and consumers espcially with prefixes continuous or <random> if not needed
  • some continuous client time and message shortening due to very long waiting just for message sending
  • slight refactors and removals of unnecessary methods.

@see-quick
Copy link
Member

/azp run regression

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Member

@im-konge im-konge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't go through all the changes, but I have few comments that I would like to have addressed before continuing.

As I mentioned offline, having one or two "default" methods that sets completely everything makes the tests confusing and it's not really clear to me, what are the requirements that need to be met for successfully sending/receiving messages.

If you get this "default" clients with everything set, some of the newbies will don't know that for SCRAM-SHA you need to set the username and create a KafkaUser. Same for TLS.

So I would create methods for creating the clients based on TestStorage, yes, but I would not have one method for all of the use-cases, but multiple methods that will cover multiple auth options. At least that will be (for me and I guess for anyone else) clearer to see, what's really going on and what is needed to be done before the message transmission.

@im-konge
Copy link
Member

/azp run regression

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@henryZrncik
Copy link
Contributor Author

@strimzi-ci run tests --testcase=RackAwarenessST --profile=all --env=STRIMZI_FEATURE_GATES=-KafkaNodePools,-UnidirectionalTopicOperator,-UseKRaft

@strimzi-ci
Copy link

▶️ Build started - check Jenkins for more info. ▶️

@strimzi-ci
Copy link

✔️ Test Summary ✔️

TEST_PROFILE: all
GROUPS:
TEST_CASE: RackAwarenessST
TOTAL: 3
PASS: 3
FAIL: 0
SKIP: 0
BUILD_NUMBER: 9
OCP_VERSION: 4.15
BUILD_IMAGES: false
FIPS_ENABLED: false
PARALLEL_COUNT: 5
EXCLUDED_GROUPS: loadbalancer,nodeport,olm
ENV_VARIABLES: STRIMZI_FEATURE_GATES=-KafkaNodePools,-UnidirectionalTopicOperator,-UseKRaft

@henryZrncik
Copy link
Contributor Author

@strimzi-ci run tests --profile=all --env=STRIMZI_FEATURE_GATES=-KafkaNodePools,-UnidirectionalTopicOperator,-UseKRaft

@strimzi-ci
Copy link

▶️ Build started - check Jenkins for more info. ▶️

@strimzi-ci
Copy link

❌ Test Summary ❌

TEST_PROFILE: all
GROUPS:
TEST_CASE:
TOTAL: 191
PASS: 150
FAIL: 38
SKIP: 3
BUILD_NUMBER: 10
OCP_VERSION: 4.15
BUILD_IMAGES: false
FIPS_ENABLED: false
PARALLEL_COUNT: 5
EXCLUDED_GROUPS: loadbalancer,nodeport,olm
ENV_VARIABLES: STRIMZI_FEATURE_GATES=-KafkaNodePools,-UnidirectionalTopicOperator,-UseKRaft

❗ Test Failures ❗

  • testCorsForbidden in io.strimzi.systemtest.bridge.HttpBridgeCorsST
  • testSendSimpleMessage in io.strimzi.systemtest.bridge.HttpBridgeST
  • testReceiveSimpleMessageTlsScramSha in io.strimzi.systemtest.bridge.HttpBridgeScramShaST
  • testReceiveSimpleMessageTls in io.strimzi.systemtest.bridge.HttpBridgeTlsST
  • testKafkaQuotasPluginIntegration in io.strimzi.systemtest.kafka.QuotasST
  • testKafkaZookeeperAndKafkaConnectWithJMX in io.strimzi.systemtest.metrics.JmxST
  • io.strimzi.systemtest.metrics.MetricsST
  • testKafkaMirrorMaker2ConnectorsState in io.strimzi.systemtest.mirrormaker.MirrorMaker2ST
  • testScaleMirrorMakerUpAndDownToZero in io.strimzi.systemtest.mirrormaker.MirrorMakerST
  • testMultipleCOsInDifferentNamespaces in io.strimzi.systemtest.operators.MultipleClusterOperatorsST
  • testPauseReconciliationInKafkaRebalanceAndTopic in io.strimzi.systemtest.operators.ReconciliationST
  • testAddingAndRemovingJbodVolumes in io.strimzi.systemtest.rollingupdate.AlternativeReconcileTriggersST
  • testNPWhenOperatorIsInDifferentNamespaceThanOperand in io.strimzi.systemtest.security.NetworkPoliciesST
  • testAutoReplaceAllCaKeysTriggeredByAnno in io.strimzi.systemtest.security.SecurityST
  • io.strimzi.systemtest.security.oauth.OauthAuthorizationST
  • io.strimzi.systemtest.security.oauth.OauthPasswordGrantsST
  • io.strimzi.systemtest.security.oauth.OauthPlainST
  • io.strimzi.systemtest.security.oauth.OauthScopeST
  • io.strimzi.systemtest.security.oauth.OauthTlsST
  • testDrainCleanerWithComponents in io.strimzi.systemtest.specific.DrainCleanerST
  • testKafkaClusterUpgrade in io.strimzi.systemtest.upgrade.kraft.KRaftKafkaUpgradeDowngradeST
  • testDowngradeStrimziVersion testDowngradeStrimziVersion-HEAD-0.39.0 in io.strimzi.systemtest.upgrade.kraft.KRaftStrimziDowngradeST
  • testUpgradeAcrossVersionsWithNoKafkaVersion in io.strimzi.systemtest.upgrade.kraft.KRaftStrimziUpgradeST

Re-run command:
@strimzi-ci run tests --profile=all --testcase=io.strimzi.systemtest.bridge.HttpBridgeCorsST#testCorsForbidden,io.strimzi.systemtest.bridge.HttpBridgeST#testSendSimpleMessage,io.strimzi.systemtest.bridge.HttpBridgeScramShaST#testReceiveSimpleMessageTlsScramSha,io.strimzi.systemtest.bridge.HttpBridgeTlsST#testReceiveSimpleMessageTls,io.strimzi.systemtest.kafka.QuotasST#testKafkaQuotasPluginIntegration,io.strimzi.systemtest.metrics.JmxST#testKafkaZookeeperAndKafkaConnectWithJMX,io.strimzi.systemtest.metrics.MetricsST,io.strimzi.systemtest.mirrormaker.MirrorMaker2ST#testKafkaMirrorMaker2ConnectorsState,io.strimzi.systemtest.mirrormaker.MirrorMakerST#testScaleMirrorMakerUpAndDownToZero,io.strimzi.systemtest.operators.MultipleClusterOperatorsST#testMultipleCOsInDifferentNamespaces,io.strimzi.systemtest.operators.ReconciliationST#testPauseReconciliationInKafkaRebalanceAndTopic,io.strimzi.systemtest.rollingupdate.AlternativeReconcileTriggersST#testAddingAndRemovingJbodVolumes,io.strimzi.systemtest.security.NetworkPoliciesST#testNPWhenOperatorIsInDifferentNamespaceThanOperand,io.strimzi.systemtest.security.SecurityST#testAutoReplaceAllCaKeysTriggeredByAnno,io.strimzi.systemtest.security.oauth.OauthAuthorizationST,io.strimzi.systemtest.security.oauth.OauthPasswordGrantsST,io.strimzi.systemtest.security.oauth.OauthPlainST,io.strimzi.systemtest.security.oauth.OauthScopeST,io.strimzi.systemtest.security.oauth.OauthTlsST,io.strimzi.systemtest.specific.DrainCleanerST#testDrainCleanerWithComponents,io.strimzi.systemtest.upgrade.kraft.KRaftKafkaUpgradeDowngradeST#testKafkaClusterUpgrade,io.strimzi.systemtest.upgrade.kraft.KRaftStrimziDowngradeST#testDowngradeStrimziVersion testDowngradeStrimziVersion-HEAD-0.39.0,io.strimzi.systemtest.upgrade.kraft.KRaftStrimziUpgradeST#testUpgradeAcrossVersionsWithNoKafkaVersion

@henryZrncik
Copy link
Contributor Author

@strimzi-ci run tests --profile=all --env=STRIMZI_FEATURE_GATES=-KafkaNodePools,-UnidirectionalTopicOperator,-UseKRaft

@strimzi-ci
Copy link

▶️ Build started - check Jenkins for more info. ▶️

@strimzi-ci
Copy link

❌ Test Summary ❌

TEST_PROFILE: all
GROUPS:
TEST_CASE:
TOTAL: 191
PASS: 153
FAIL: 35
SKIP: 3
BUILD_NUMBER: 14
OCP_VERSION: 4.15
BUILD_IMAGES: false
FIPS_ENABLED: false
PARALLEL_COUNT: 5
EXCLUDED_GROUPS: loadbalancer,nodeport,olm
ENV_VARIABLES: STRIMZI_FEATURE_GATES=-KafkaNodePools,-UnidirectionalTopicOperator,-UseKRaft

❗ Test Failures ❗

  • testCorsForbidden in io.strimzi.systemtest.bridge.HttpBridgeCorsST
  • testReceiveSimpleMessage in io.strimzi.systemtest.bridge.HttpBridgeST
  • testReceiveSimpleMessageTlsScramSha in io.strimzi.systemtest.bridge.HttpBridgeScramShaST
  • testReceiveSimpleMessageTls in io.strimzi.systemtest.bridge.HttpBridgeTlsST
  • testKafkaQuotasPluginIntegration in io.strimzi.systemtest.kafka.QuotasST
  • testKafkaZookeeperAndKafkaConnectWithJMX in io.strimzi.systemtest.metrics.JmxST
  • io.strimzi.systemtest.metrics.MetricsST
  • testKMM2RollAfterSecretsCertsUpdateTLS in io.strimzi.systemtest.mirrormaker.MirrorMaker2ST
  • testScaleMirrorMakerUpAndDownToZero in io.strimzi.systemtest.mirrormaker.MirrorMakerST
  • testMultipleCOsInDifferentNamespaces in io.strimzi.systemtest.operators.MultipleClusterOperatorsST
  • testNPGenerationEnvironmentVariable in io.strimzi.systemtest.security.NetworkPoliciesST
  • testAutoReplaceAllCaKeysTriggeredByAnno in io.strimzi.systemtest.security.SecurityST
  • io.strimzi.systemtest.security.oauth.OauthAuthorizationST
  • io.strimzi.systemtest.security.oauth.OauthPasswordGrantsST
  • io.strimzi.systemtest.security.oauth.OauthPlainST
  • io.strimzi.systemtest.security.oauth.OauthScopeST
  • io.strimzi.systemtest.security.oauth.OauthTlsST
  • testDrainCleanerWithComponents in io.strimzi.systemtest.specific.DrainCleanerST
  • testKafkaClusterUpgrade in io.strimzi.systemtest.upgrade.kraft.KRaftKafkaUpgradeDowngradeST
  • testDowngradeStrimziVersion testDowngradeStrimziVersion-HEAD-0.39.0 in io.strimzi.systemtest.upgrade.kraft.KRaftStrimziDowngradeST
  • testUpgradeAcrossVersionsWithNoKafkaVersion in io.strimzi.systemtest.upgrade.kraft.KRaftStrimziUpgradeST

Re-run command:
@strimzi-ci run tests --profile=all --testcase=io.strimzi.systemtest.bridge.HttpBridgeCorsST#testCorsForbidden,io.strimzi.systemtest.bridge.HttpBridgeST#testReceiveSimpleMessage,io.strimzi.systemtest.bridge.HttpBridgeScramShaST#testReceiveSimpleMessageTlsScramSha,io.strimzi.systemtest.bridge.HttpBridgeTlsST#testReceiveSimpleMessageTls,io.strimzi.systemtest.kafka.QuotasST#testKafkaQuotasPluginIntegration,io.strimzi.systemtest.metrics.JmxST#testKafkaZookeeperAndKafkaConnectWithJMX,io.strimzi.systemtest.metrics.MetricsST,io.strimzi.systemtest.mirrormaker.MirrorMaker2ST#testKMM2RollAfterSecretsCertsUpdateTLS,io.strimzi.systemtest.mirrormaker.MirrorMakerST#testScaleMirrorMakerUpAndDownToZero,io.strimzi.systemtest.operators.MultipleClusterOperatorsST#testMultipleCOsInDifferentNamespaces,io.strimzi.systemtest.security.NetworkPoliciesST#testNPGenerationEnvironmentVariable,io.strimzi.systemtest.security.SecurityST#testAutoReplaceAllCaKeysTriggeredByAnno,io.strimzi.systemtest.security.oauth.OauthAuthorizationST,io.strimzi.systemtest.security.oauth.OauthPasswordGrantsST,io.strimzi.systemtest.security.oauth.OauthPlainST,io.strimzi.systemtest.security.oauth.OauthScopeST,io.strimzi.systemtest.security.oauth.OauthTlsST,io.strimzi.systemtest.specific.DrainCleanerST#testDrainCleanerWithComponents,io.strimzi.systemtest.upgrade.kraft.KRaftKafkaUpgradeDowngradeST#testKafkaClusterUpgrade,io.strimzi.systemtest.upgrade.kraft.KRaftStrimziDowngradeST#testDowngradeStrimziVersion testDowngradeStrimziVersion-HEAD-0.39.0,io.strimzi.systemtest.upgrade.kraft.KRaftStrimziUpgradeST#testUpgradeAcrossVersionsWithNoKafkaVersion

@see-quick
Copy link
Member

/azp list

@see-quick
Copy link
Member

/azp run feature-gates-regression

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@henryZrncik
Copy link
Contributor Author

@strimzi-ci run tests --profile=all --testcase=HttpBridgeST,MirrorMaker2ST --parallel-count=1 --env=STRIMZI_FEATURE_GATES=-KafkaNodePools,-UnidirectionalTopicOperator,-UseKRaft

@strimzi-ci
Copy link

▶️ Build started - check Jenkins for more info. ▶️

@strimzi-ci
Copy link

❌ Test Summary ❌

TEST_PROFILE: all
GROUPS:
TEST_CASE: HttpBridgeST,MirrorMaker2ST
TOTAL: 19
PASS: 17
FAIL: 2
SKIP: 0
BUILD_NUMBER: 30
OCP_VERSION: 4.15
BUILD_IMAGES: false
FIPS_ENABLED: false
PARALLEL_COUNT: 1
EXCLUDED_GROUPS: loadbalancer,nodeport,olm
ENV_VARIABLES: STRIMZI_FEATURE_GATES=-KafkaNodePools,-UnidirectionalTopicOperator,-UseKRaft

❗ Test Failures ❗

  • testSendSimpleMessage in io.strimzi.systemtest.bridge.HttpBridgeST

Re-run command:
@strimzi-ci run tests --profile=all --testcase=io.strimzi.systemtest.bridge.HttpBridgeST#testSendSimpleMessage

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
…using sink

Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
…well

Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
Signed-off-by: hzrncik <hzrncik@redhat.com>
@see-quick
Copy link
Member

/azp run regression

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@henryZrncik
Copy link
Contributor Author

@see-quick last fail unrelated to the PR.

@see-quick see-quick added the ready for merge Label for PRs which are ready for merge label Mar 22, 2024
@see-quick see-quick merged commit dd0826b into strimzi:main Mar 22, 2024
21 checks passed
steffen-karlsson pushed a commit to steffen-karlsson/strimzi-kafka-operator that referenced this pull request Apr 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready for merge Label for PRs which are ready for merge System tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants