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

Updating tests with distributed mode #338

Merged
merged 3 commits into from
Nov 12, 2024
Merged

Conversation

muralibasani
Copy link
Contributor

integration tests now run in connect distributed mode
verify offset storage keys

props.put(ConsumerConfig.AUTO_OFFSET_RESET_CONFIG, "earliest");

final Map<String, Object> messages = new HashMap<>();
Map<String, Object> offsetRec;
Copy link
Contributor

Choose a reason for hiding this comment

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

This variable declaration is redundant here and unnecessary widening the variable scope. It can be declared together with the assignment

while (messages.size() < expectedMessageCount) {
final ConsumerRecords<byte[], byte[]> records = consumer.poll(5L);
for (final ConsumerRecord<byte[], byte[]> record : records) {
offsetRec = OBJECT_MAPPER.readValue(new String(record.value(), StandardCharsets.UTF_8), // NOPMD
Copy link
Contributor

Choose a reason for hiding this comment

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

Conversion to String seems to be redundant, objectMapper is able to parse byte arrays.

Copy link
Contributor

@AnatolyPopov AnatolyPopov left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@aindriu-aiven aindriu-aiven left a comment

Choose a reason for hiding this comment

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

LGTM

@aindriu-aiven aindriu-aiven merged commit 3bd8a17 into s3-source-release Nov 12, 2024
8 checks passed
@aindriu-aiven aindriu-aiven deleted the add-intg-tests branch November 12, 2024 13:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants