From 84b8498d72256b399db699e78140706ce6ddba95 Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Fri, 4 Oct 2024 19:08:12 +0530 Subject: [PATCH 01/12] refactor: update partition IDs in cluster metadata --- protocol/serializer/cluster_metadata.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/protocol/serializer/cluster_metadata.go b/protocol/serializer/cluster_metadata.go index e86c015..32fbbef 100644 --- a/protocol/serializer/cluster_metadata.go +++ b/protocol/serializer/cluster_metadata.go @@ -94,7 +94,7 @@ func writeClusterMetadata(path string, topic1Name string, topic1UUID string, top Type: 3, Version: 1, Data: &kafkaapi.PartitionRecord{ - PartitionID: 1, + PartitionID: 0, TopicUUID: topic3UUID, Replicas: []int32{1}, ISReplicas: []int32{1}, @@ -112,7 +112,7 @@ func writeClusterMetadata(path string, topic1Name string, topic1UUID string, top Type: 3, Version: 1, Data: &kafkaapi.PartitionRecord{ - PartitionID: 0, + PartitionID: 1, TopicUUID: topic3UUID, Replicas: []int32{1}, ISReplicas: []int32{1}, @@ -129,7 +129,7 @@ func writeClusterMetadata(path string, topic1Name string, topic1UUID string, top BaseOffset: 1, PartitionLeaderEpoch: 1, Attributes: 0, - LastOffsetDelta: 3, + LastOffsetDelta: 0, FirstTimestamp: 1726045943832, MaxTimestamp: 1726045943832, ProducerId: -1, @@ -206,7 +206,7 @@ func writeClusterMetadata(path string, topic1Name string, topic1UUID string, top BaseOffset: int64(len(recordBatch3.Records) + int(recordBatch3.BaseOffset)), PartitionLeaderEpoch: 1, Attributes: 0, - LastOffsetDelta: 1, + LastOffsetDelta: 2, FirstTimestamp: 1726045957397, MaxTimestamp: 1726045957397, ProducerId: -1, From 07812b09c5cb6ac74dc784572dbc3afa4b9fcd48 Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Fri, 4 Oct 2024 19:11:29 +0530 Subject: [PATCH 02/12] refactor: update LastOffsetDelta in cluster metadata serialization --- protocol/serializer/cluster_metadata.go | 8 ++++---- protocol/serializer/cluster_metadata_binspec.go | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/protocol/serializer/cluster_metadata.go b/protocol/serializer/cluster_metadata.go index 32fbbef..805921a 100644 --- a/protocol/serializer/cluster_metadata.go +++ b/protocol/serializer/cluster_metadata.go @@ -129,7 +129,7 @@ func writeClusterMetadata(path string, topic1Name string, topic1UUID string, top BaseOffset: 1, PartitionLeaderEpoch: 1, Attributes: 0, - LastOffsetDelta: 0, + LastOffsetDelta: 0, // len(records) - 1 FirstTimestamp: 1726045943832, MaxTimestamp: 1726045943832, ProducerId: -1, @@ -150,7 +150,7 @@ func writeClusterMetadata(path string, topic1Name string, topic1UUID string, top BaseOffset: int64(len(recordBatch1.Records) + int(recordBatch1.BaseOffset)), PartitionLeaderEpoch: 1, Attributes: 0, - LastOffsetDelta: 1, + LastOffsetDelta: 1, // len(records) - 1 FirstTimestamp: 1726045957397, MaxTimestamp: 1726045957397, ProducerId: -1, @@ -178,7 +178,7 @@ func writeClusterMetadata(path string, topic1Name string, topic1UUID string, top BaseOffset: int64(len(recordBatch2.Records) + int(recordBatch2.BaseOffset)), PartitionLeaderEpoch: 1, Attributes: 0, - LastOffsetDelta: 1, + LastOffsetDelta: 1, // len(records) - 1 FirstTimestamp: 1726045957397, MaxTimestamp: 1726045957397, ProducerId: -1, @@ -206,7 +206,7 @@ func writeClusterMetadata(path string, topic1Name string, topic1UUID string, top BaseOffset: int64(len(recordBatch3.Records) + int(recordBatch3.BaseOffset)), PartitionLeaderEpoch: 1, Attributes: 0, - LastOffsetDelta: 2, + LastOffsetDelta: 2, // len(records) - 1 FirstTimestamp: 1726045957397, MaxTimestamp: 1726045957397, ProducerId: -1, diff --git a/protocol/serializer/cluster_metadata_binspec.go b/protocol/serializer/cluster_metadata_binspec.go index 5c42528..df977ba 100644 --- a/protocol/serializer/cluster_metadata_binspec.go +++ b/protocol/serializer/cluster_metadata_binspec.go @@ -98,7 +98,7 @@ func writeClusterMetadataBinSpec(path string, directoryUUID string, logger *logg BaseOffset: int64(0 + 0), PartitionLeaderEpoch: 1, Attributes: 0, - LastOffsetDelta: 2, // ToDo len(records) - 1 + LastOffsetDelta: 2, // len(records) - 1 FirstTimestamp: 1726045957397, MaxTimestamp: 1726045957397, ProducerId: -1, From b545882ae84fc2950dd371531f415fe0bdccff69 Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Fri, 4 Oct 2024 20:15:34 +0530 Subject: [PATCH 03/12] refactor: add custom byte matching logic --- internal/stagef5.go | 10 ++++---- internal/stagef6.go | 56 +++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 58 insertions(+), 8 deletions(-) diff --git a/internal/stagef5.go b/internal/stagef5.go index 9bed602..033095e 100644 --- a/internal/stagef5.go +++ b/internal/stagef5.go @@ -109,8 +109,8 @@ func testFetchWithSingleMessage(stageHarness *test_case_harness.TestCaseHarness) Magic: 0, Attributes: 0, LastOffsetDelta: 0, - FirstTimestamp: 0, - MaxTimestamp: 0, + FirstTimestamp: 1726045973899, + MaxTimestamp: 1726045973899, ProducerId: 0, ProducerEpoch: 0, BaseSequence: 0, @@ -120,7 +120,7 @@ func testFetchWithSingleMessage(stageHarness *test_case_harness.TestCaseHarness) Attributes: 0, TimestampDelta: 0, OffsetDelta: 0, - Key: []byte{}, + Key: nil, Value: []byte(common.MESSAGE1), Headers: []kafkaapi.RecordHeader{}, }, @@ -134,11 +134,9 @@ func testFetchWithSingleMessage(stageHarness *test_case_harness.TestCaseHarness) }, } - // Byte to Byte comparison for RecordBatches - // Wire up ByteDiffVisualizer - return assertions.NewFetchResponseAssertion(*responseBody, expectedFetchResponse, logger). AssertBody([]string{"ThrottleTimeMs", "ErrorCode"}). AssertTopics([]string{"Topic"}, []string{"ErrorCode", "PartitionIndex"}, []string{"BaseOffset"}, []string{"Value"}). + AssertRecordBatchBytes(). Run() } diff --git a/internal/stagef6.go b/internal/stagef6.go index 51aeaca..d9d3a71 100644 --- a/internal/stagef6.go +++ b/internal/stagef6.go @@ -1,12 +1,16 @@ package internal import ( + "fmt" + "github.com/codecrafters-io/kafka-tester/internal/assertions" "github.com/codecrafters-io/kafka-tester/internal/kafka_executable" "github.com/codecrafters-io/kafka-tester/protocol" kafkaapi "github.com/codecrafters-io/kafka-tester/protocol/api" "github.com/codecrafters-io/kafka-tester/protocol/common" + realencoder "github.com/codecrafters-io/kafka-tester/protocol/encoder" "github.com/codecrafters-io/kafka-tester/protocol/serializer" + "github.com/codecrafters-io/tester-utils/bytes_diff_visualizer" "github.com/codecrafters-io/tester-utils/test_case_harness" ) @@ -133,8 +137,8 @@ func testFetchMultipleMessages(stageHarness *test_case_harness.TestCaseHarness) Magic: 0, Attributes: 0, LastOffsetDelta: 0, - FirstTimestamp: 0, - MaxTimestamp: 0, + FirstTimestamp: 1726045973899, + MaxTimestamp: 1726045973899, ProducerId: 0, ProducerEpoch: 0, BaseSequence: 0, @@ -158,8 +162,56 @@ func testFetchMultipleMessages(stageHarness *test_case_harness.TestCaseHarness) }, } + expectedRecordBatchBytes := serializeTopicData([]string{common.MESSAGE2, common.MESSAGE3}) + + encoder := realencoder.RealEncoder{} + encoder.Init(make([]byte, 4096)) + responseBody.TopicResponses[0].PartitionResponses[0].RecordBatches[0].Encode(&encoder) + responseBody.TopicResponses[0].PartitionResponses[0].RecordBatches[1].Encode(&encoder) + actualRecordBatchBytes := encoder.Bytes()[:encoder.Offset()] + + // fmt.Println(expectedRecordBatchBytes) + // fmt.Println(actualRecordBatchBytes) + // fmt.Println(bytes.Equal(expectedRecordBatchBytes, actualRecordBatchBytes)) + + result := bytes_diff_visualizer.VisualizeByteDiff(expectedRecordBatchBytes, actualRecordBatchBytes) + for i := range len(result) { + fmt.Println(result[i]) + } return assertions.NewFetchResponseAssertion(*responseBody, expectedFetchResponse, logger). AssertBody([]string{"ThrottleTimeMs", "ErrorCode"}). AssertTopics([]string{"Topic"}, []string{"ErrorCode", "PartitionIndex"}, []string{"BaseOffset"}, []string{"Value"}). + // AssertRecordBatchBytes(). // TODO: why this not working ? Run() } + +func serializeTopicData(messages []string) []byte { + encoder := realencoder.RealEncoder{} + encoder.Init(make([]byte, 4096)) + + for i, message := range messages { + recordBatch := kafkaapi.RecordBatch{ + BaseOffset: int64(i), + PartitionLeaderEpoch: 0, + Attributes: 0, + LastOffsetDelta: 0, + FirstTimestamp: 1726045973899, + MaxTimestamp: 1726045973899, + ProducerId: 0, + ProducerEpoch: 0, + BaseSequence: 0, + Records: []kafkaapi.Record{ + { + Attributes: 0, + TimestampDelta: 0, + Key: nil, + Value: []byte(message), + Headers: []kafkaapi.RecordHeader{}, + }, + }, + } + recordBatch.Encode(&encoder) + } + + return encoder.Bytes()[:encoder.Offset()] +} From dc05e8869fc57f4e8bfb21f901c3ec381ff752fd Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Fri, 4 Oct 2024 20:15:54 +0530 Subject: [PATCH 04/12] refactor: add recordBatch byte matching logic to assertion framework --- .../assertions/fetch_response_assertion.go | 48 +++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/internal/assertions/fetch_response_assertion.go b/internal/assertions/fetch_response_assertion.go index 6a6f3d5..23069e2 100644 --- a/internal/assertions/fetch_response_assertion.go +++ b/internal/assertions/fetch_response_assertion.go @@ -6,6 +6,8 @@ import ( "github.com/codecrafters-io/kafka-tester/protocol" kafkaapi "github.com/codecrafters-io/kafka-tester/protocol/api" + realencoder "github.com/codecrafters-io/kafka-tester/protocol/encoder" + "github.com/codecrafters-io/tester-utils/bytes_diff_visualizer" "github.com/codecrafters-io/tester-utils/logger" ) @@ -220,6 +222,41 @@ func (a *FetchResponseAssertion) assertRecords(expectedRecords []kafkaapi.Record return a } +func (a *FetchResponseAssertion) AssertRecordBatchBytes() *FetchResponseAssertion { + if a.err != nil { + return a + } + + actualRecordBatches := []kafkaapi.RecordBatch{} + for _, topic := range a.ActualValue.TopicResponses { + for _, partition := range topic.PartitionResponses { + actualRecordBatches = append(actualRecordBatches, partition.RecordBatches...) + } + } + + expectedRecordBatches := []kafkaapi.RecordBatch{} + for _, topic := range a.ExpectedValue.TopicResponses { + for _, partition := range topic.PartitionResponses { + expectedRecordBatches = append(expectedRecordBatches, partition.RecordBatches...) + } + } + + expectedRecordBatchBytes := encodeRecordBatch(expectedRecordBatches) + actualRecordBatchBytes := encodeRecordBatch(actualRecordBatches) + if !bytes.Equal(expectedRecordBatchBytes, actualRecordBatchBytes) { + result := bytes_diff_visualizer.VisualizeByteDiff(expectedRecordBatchBytes, actualRecordBatchBytes) + for _, line := range result { + a.logger.Errorf(line) + } + a.err = fmt.Errorf("RecordBatch bytes do not match with the contents on disk") + return a + } + + a.logger.Successf("✓ RecordBatch bytes match with the contents on disk") + return a + +} + func (a FetchResponseAssertion) Run() error { // firstLevelFields: ["ThrottleTimeMs", "ErrorCode", "SessionID"] // secondLevelFields (Topics): ["Topic"] @@ -228,3 +265,14 @@ func (a FetchResponseAssertion) Run() error { // fifthLevelFields (Records): ["Value"] return a.err } + +func encodeRecordBatch(recordBatches []kafkaapi.RecordBatch) []byte { + // Could also use: serializer.SerializeTopicData([]string{common.MESSAGE1}) + + encoder := realencoder.RealEncoder{} + encoder.Init(make([]byte, 4096)) + for _, recordBatch := range recordBatches { + recordBatch.Encode(&encoder) + } + return encoder.Bytes()[:encoder.Offset()] +} From 87dd6c208499e26de42b409e831deb7799f1f85e Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Fri, 4 Oct 2024 20:16:02 +0530 Subject: [PATCH 05/12] refactor: update BaseOffset in cluster metadata serialization --- protocol/serializer/cluster_metadata_binspec.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/protocol/serializer/cluster_metadata_binspec.go b/protocol/serializer/cluster_metadata_binspec.go index df977ba..9719b46 100644 --- a/protocol/serializer/cluster_metadata_binspec.go +++ b/protocol/serializer/cluster_metadata_binspec.go @@ -74,7 +74,7 @@ func writeClusterMetadataBinSpec(path string, directoryUUID string, logger *logg } recordBatch1 := kafkaapi.RecordBatch{ - BaseOffset: 1, + BaseOffset: 0, PartitionLeaderEpoch: 1, Attributes: 0, LastOffsetDelta: 0, // len(records) - 1 @@ -95,7 +95,7 @@ func writeClusterMetadataBinSpec(path string, directoryUUID string, logger *logg } recordBatch4 := kafkaapi.RecordBatch{ - BaseOffset: int64(0 + 0), + BaseOffset: 1, PartitionLeaderEpoch: 1, Attributes: 0, LastOffsetDelta: 2, // len(records) - 1 From 2b320f3fad1ad7344e9edb148ccb9b5b7851fba9 Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Thu, 17 Oct 2024 13:58:04 +0530 Subject: [PATCH 06/12] refactor: update logging and add comments for byte comparison --- internal/assertions/fetch_response_assertion.go | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/internal/assertions/fetch_response_assertion.go b/internal/assertions/fetch_response_assertion.go index 23069e2..aad3004 100644 --- a/internal/assertions/fetch_response_assertion.go +++ b/internal/assertions/fetch_response_assertion.go @@ -241,13 +241,18 @@ func (a *FetchResponseAssertion) AssertRecordBatchBytes() *FetchResponseAssertio } } - expectedRecordBatchBytes := encodeRecordBatch(expectedRecordBatches) - actualRecordBatchBytes := encodeRecordBatch(actualRecordBatches) + expectedRecordBatchBytes := encodeRecordBatches(expectedRecordBatches) + actualRecordBatchBytes := encodeRecordBatches(actualRecordBatches) + // Byte Comparison for expected v actual RecordBatch bytes + // As we write them to disk, and expect users to not change the values + // we can use a simple byte comparison here. if !bytes.Equal(expectedRecordBatchBytes, actualRecordBatchBytes) { result := bytes_diff_visualizer.VisualizeByteDiff(expectedRecordBatchBytes, actualRecordBatchBytes) + a.logger.Errorf("") for _, line := range result { a.logger.Errorf(line) } + a.logger.Errorf("") a.err = fmt.Errorf("RecordBatch bytes do not match with the contents on disk") return a } @@ -266,8 +271,9 @@ func (a FetchResponseAssertion) Run() error { return a.err } -func encodeRecordBatch(recordBatches []kafkaapi.RecordBatch) []byte { - // Could also use: serializer.SerializeTopicData([]string{common.MESSAGE1}) +func encodeRecordBatches(recordBatches []kafkaapi.RecordBatch) []byte { + // Given an array of RecordBatch, encodes them using the encoder.RealEncoder + // and returns the resulting bytes. encoder := realencoder.RealEncoder{} encoder.Init(make([]byte, 4096)) From 62085ecfc91ae7cf1c397cb3c69aaa939c65387b Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Thu, 17 Oct 2024 13:58:33 +0530 Subject: [PATCH 07/12] fix: fix byte comparison issue in f6 --- internal/stagef6.go | 57 +++------------------------------------------ 1 file changed, 3 insertions(+), 54 deletions(-) diff --git a/internal/stagef6.go b/internal/stagef6.go index d9d3a71..99b7f66 100644 --- a/internal/stagef6.go +++ b/internal/stagef6.go @@ -1,16 +1,12 @@ package internal import ( - "fmt" - "github.com/codecrafters-io/kafka-tester/internal/assertions" "github.com/codecrafters-io/kafka-tester/internal/kafka_executable" "github.com/codecrafters-io/kafka-tester/protocol" kafkaapi "github.com/codecrafters-io/kafka-tester/protocol/api" "github.com/codecrafters-io/kafka-tester/protocol/common" - realencoder "github.com/codecrafters-io/kafka-tester/protocol/encoder" "github.com/codecrafters-io/kafka-tester/protocol/serializer" - "github.com/codecrafters-io/tester-utils/bytes_diff_visualizer" "github.com/codecrafters-io/tester-utils/test_case_harness" ) @@ -113,8 +109,8 @@ func testFetchMultipleMessages(stageHarness *test_case_harness.TestCaseHarness) Magic: 0, Attributes: 0, LastOffsetDelta: 0, - FirstTimestamp: 0, - MaxTimestamp: 0, + FirstTimestamp: 1726045973899, + MaxTimestamp: 1726045973899, ProducerId: 0, ProducerEpoch: 0, BaseSequence: 0, @@ -162,56 +158,9 @@ func testFetchMultipleMessages(stageHarness *test_case_harness.TestCaseHarness) }, } - expectedRecordBatchBytes := serializeTopicData([]string{common.MESSAGE2, common.MESSAGE3}) - - encoder := realencoder.RealEncoder{} - encoder.Init(make([]byte, 4096)) - responseBody.TopicResponses[0].PartitionResponses[0].RecordBatches[0].Encode(&encoder) - responseBody.TopicResponses[0].PartitionResponses[0].RecordBatches[1].Encode(&encoder) - actualRecordBatchBytes := encoder.Bytes()[:encoder.Offset()] - - // fmt.Println(expectedRecordBatchBytes) - // fmt.Println(actualRecordBatchBytes) - // fmt.Println(bytes.Equal(expectedRecordBatchBytes, actualRecordBatchBytes)) - - result := bytes_diff_visualizer.VisualizeByteDiff(expectedRecordBatchBytes, actualRecordBatchBytes) - for i := range len(result) { - fmt.Println(result[i]) - } return assertions.NewFetchResponseAssertion(*responseBody, expectedFetchResponse, logger). AssertBody([]string{"ThrottleTimeMs", "ErrorCode"}). AssertTopics([]string{"Topic"}, []string{"ErrorCode", "PartitionIndex"}, []string{"BaseOffset"}, []string{"Value"}). - // AssertRecordBatchBytes(). // TODO: why this not working ? + AssertRecordBatchBytes(). Run() } - -func serializeTopicData(messages []string) []byte { - encoder := realencoder.RealEncoder{} - encoder.Init(make([]byte, 4096)) - - for i, message := range messages { - recordBatch := kafkaapi.RecordBatch{ - BaseOffset: int64(i), - PartitionLeaderEpoch: 0, - Attributes: 0, - LastOffsetDelta: 0, - FirstTimestamp: 1726045973899, - MaxTimestamp: 1726045973899, - ProducerId: 0, - ProducerEpoch: 0, - BaseSequence: 0, - Records: []kafkaapi.Record{ - { - Attributes: 0, - TimestampDelta: 0, - Key: nil, - Value: []byte(message), - Headers: []kafkaapi.RecordHeader{}, - }, - }, - } - recordBatch.Encode(&encoder) - } - - return encoder.Bytes()[:encoder.Offset()] -} From fa05c6522a176a183962ae4e5d3a5840a9302b6d Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Thu, 17 Oct 2024 13:59:30 +0530 Subject: [PATCH 08/12] chores: add comments --- protocol/serializer/topic_data.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/protocol/serializer/topic_data.go b/protocol/serializer/topic_data.go index 6592102..7329c02 100644 --- a/protocol/serializer/topic_data.go +++ b/protocol/serializer/topic_data.go @@ -10,6 +10,8 @@ import ( ) func serializeTopicData(messages []string) []byte { + // Given an array of messages, generates the RecordBatch struct first, + // then uses the encoder.RealEncoder to encode them into bytes. encoder := kafkaencoder.RealEncoder{} encoder.Init(make([]byte, 4096)) From a7950fa9b66bf7b5c33787a6276323d27405442d Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Thu, 17 Oct 2024 14:16:27 +0530 Subject: [PATCH 09/12] tests: add tests and update fixtures --- Makefile | 9 +- internal/stages_test.go | 4 +- internal/test_helpers/fixtures/fetch/pass | 1080 +++++++++++++-------- 3 files changed, 665 insertions(+), 428 deletions(-) diff --git a/Makefile b/Makefile index dc5a088..95e7fee 100644 --- a/Makefile +++ b/Makefile @@ -26,7 +26,7 @@ test_concurrent_requests_with_kafka: build dist/main.out -test_current: +test_all: make test_base_with_kafka make test_concurrent_requests_with_kafka make test_describe_topic_partitions_with_kafka @@ -34,12 +34,7 @@ test_current: test_fetch_with_kafka: build CODECRAFTERS_REPOSITORY_DIR=./internal/test_helpers/pass_all \ - CODECRAFTERS_TEST_CASES_JSON="[{\"slug\":\"gs0\",\"tester_log_prefix\":\"stage-F1\",\"title\":\"Stage #F1: API Version with Fetch Key\"}, {\"slug\":\"dh6\",\"tester_log_prefix\":\"stage-F2\",\"title\":\"Stage #F2: Fetch with no topics\"}, {\"slug\":\"hn6\",\"tester_log_prefix\":\"stage-F3\",\"title\":\"Stage #F3: Fetch with unknown topic\"}, {\"slug\":\"cm4\",\"tester_log_prefix\":\"stage-F4\",\"title\":\"Stage #F4: Fetch with empty topic\"}, {\"slug\":\"eg2\",\"tester_log_prefix\":\"stage-F5\",\"title\":\"Stage #F5: Single Fetch from Disk\"}, {\"slug\":\"fd8\",\"tester_log_prefix\":\"stage-F6\",\"title\":\"Stage #F6: Multi Fetch from Disk\"}]" \ - dist/main.out - -test_75_with_kafka: build - CODECRAFTERS_REPOSITORY_DIR=./internal/test_helpers/pass_all \ - CODECRAFTERS_TEST_CASES_JSON="[{\"slug\":\"fd8\",\"tester_log_prefix\":\"stage-F6\",\"title\":\"Stage #F6: Multi Fetch from Disk\"}]" \ + CODECRAFTERS_TEST_CASES_JSON="[{\"slug\":\"gs0\",\"tester_log_prefix\":\"stage-F1\",\"title\":\"Stage #F1: API Version with Fetch Key\"}, {\"slug\":\"dh6\",\"tester_log_prefix\":\"stage-F2\",\"title\":\"Stage #F2: Fetch with no topics\"}, {\"slug\":\"hn6\",\"tester_log_prefix\":\"stage-F3\",\"title\":\"Stage #F3: Fetch with unknown topic\"}, {\"slug\":\"cm4\",\"tester_log_prefix\":\"stage-F4\",\"title\":\"Stage #F4: Fetch with empty topic\"}, {\"slug\":\"eg2\",\"tester_log_prefix\":\"stage-F5\",\"title\":\"Stage #F5: Single Fetch from Disk\"}, {\"slug\":\"fd8\",\"tester_log_prefix\":\"stage-F6\",\"title\":\"Stage #F6: Multi Fetch from Disk\"}, ]" \ dist/main.out test: diff --git a/internal/stages_test.go b/internal/stages_test.go index 4a5469d..b365f65 100644 --- a/internal/stages_test.go +++ b/internal/stages_test.go @@ -34,7 +34,7 @@ func TestStages(t *testing.T) { NormalizeOutputFunc: normalizeTesterOutput, }, "fetch_pass": { - StageSlugs: []string{"gs0", "dh6", "hn6", "cm4"}, + StageSlugs: []string{"gs0", "dh6", "hn6", "cm4", "eg2", "fd8"}, CodePath: "./test_helpers/pass_all", ExpectedExitCode: 0, StdoutFixturePath: "./test_helpers/fixtures/fetch/pass", @@ -60,7 +60,7 @@ func normalizeTesterOutput(testerOutput []byte) []byte { "Name": {regexp.MustCompile(`✓ Topic Name: [0-9A-Za-z]{3}`)}, "UUID": {regexp.MustCompile(`✓ Topic UUID: [0-9]{8}-[0-9]{4}-[0-9]{4}-[0-9]{4}-[0-9]{12}`)}, "value_length": {regexp.MustCompile(`- .value_length \([0-9]{1,}\)`)}, - "value": {regexp.MustCompile(`- .value \("[A-Za-z0-9 !]{1,}"\)`)}, + "value": {regexp.MustCompile(`- .[vV]alue \("[A-Za-z0-9 !]{1,}"\)`)}, "name": {regexp.MustCompile(`- .name \([A-Za-z -]{1,}\)`)}, "topic_name": {regexp.MustCompile(`- .topic_name \([A-Za-z0-9 ]{1,}\)`)}, "next_cursor": {regexp.MustCompile(`- .next_cursor \(\{[A-Za-z0-9 ]{1,}\}\)`)}, diff --git a/internal/test_helpers/fixtures/fetch/pass b/internal/test_helpers/fixtures/fetch/pass index 6431d53..0cee0aa 100644 --- a/internal/test_helpers/fixtures/fetch/pass +++ b/internal/test_helpers/fixtures/fetch/pass @@ -1,379 +1,504 @@ Debug = true -[stage-4] Running tests for Stage #4: gs0 +[stage-6] Running tests for Stage #6: gs0 +[stage-6] $ ./your_program.sh /tmp/server.properties +[stage-6] Connecting to broker at: localhost:9092 +[stage-6] Connection to broker at localhost:9092 successful +[stage-6] Sending "ApiVersions" (version: 4) request (Correlation id: 177586623) +[stage-6] Hexdump of sent "ApiVersions" request:  +[stage-6] Idx | Hex | ASCII +[stage-6] -----+-------------------------------------------------+----------------- +[stage-6] 0000 | 00 00 00 23 00 12 00 04 0a 95 c1 bf 00 09 6b 61 | ...#..........ka +[stage-6] 0010 | 66 6b 61 2d 63 6c 69 00 0a 6b 61 66 6b 61 2d 63 | fka-cli..kafka-c +[stage-6] 0020 | 6c 69 04 30 2e 31 00 | li.0.1. +[stage-6]  +[stage-6] Hexdump of received "ApiVersions" response:  +[stage-6] Idx | Hex | ASCII +[stage-6] -----+-------------------------------------------------+----------------- +[stage-6] 0000 | 0a 95 c1 bf 00 00 3e 00 00 00 00 00 0b 00 00 01 | ......>......... +[stage-6] 0010 | 00 00 00 11 00 00 02 00 00 00 09 00 00 03 00 00 | ................ +[stage-6] 0020 | 00 0c 00 00 08 00 00 00 09 00 00 09 00 00 00 09 | ................ +[stage-6] 0030 | 00 00 0a 00 00 00 06 00 00 0b 00 00 00 09 00 00 | ................ +[stage-6] 0040 | 0c 00 00 00 04 00 00 0d 00 00 00 05 00 00 0e 00 | ................ +[stage-6] 0050 | 00 00 05 00 00 0f 00 00 00 05 00 00 10 00 00 00 | ................ +[stage-6] 0060 | 05 00 00 11 00 00 00 01 00 00 12 00 00 00 04 00 | ................ +[stage-6] 0070 | 00 13 00 00 00 07 00 00 14 00 00 00 06 00 00 15 | ................ +[stage-6] 0080 | 00 00 00 02 00 00 16 00 00 00 05 00 00 17 00 00 | ................ +[stage-6] 0090 | 00 04 00 00 18 00 00 00 05 00 00 19 00 00 00 04 | ................ +[stage-6] 00a0 | 00 00 1a 00 00 00 04 00 00 1b 00 00 00 01 00 00 | ................ +[stage-6] 00b0 | 1c 00 00 00 04 00 00 1d 00 00 00 03 00 00 1e 00 | ................ +[stage-6] 00c0 | 00 00 03 00 00 1f 00 00 00 03 00 00 20 00 00 00 | ............ ... +[stage-6] 00d0 | 04 00 00 21 00 00 00 02 00 00 22 00 00 00 02 00 | ...!......"..... +[stage-6] 00e0 | 00 23 00 00 00 04 00 00 24 00 00 00 02 00 00 25 | .#......$......% +[stage-6] 00f0 | 00 00 00 03 00 00 26 00 00 00 03 00 00 27 00 00 | ......&......'.. +[stage-6] 0100 | 00 02 00 00 28 00 00 00 02 00 00 29 00 00 00 03 | ....(......).... +[stage-6] 0110 | 00 00 2a 00 00 00 02 00 00 2b 00 00 00 02 00 00 | ..*......+...... +[stage-6] 0120 | 2c 00 00 00 01 00 00 2d 00 00 00 00 00 00 2e 00 | ,......-........ +[stage-6] 0130 | 00 00 00 00 00 2f 00 00 00 00 00 00 30 00 00 00 | ...../......0... +[stage-6] 0140 | 01 00 00 31 00 00 00 01 00 00 32 00 00 00 00 00 | ...1......2..... +[stage-6] 0150 | 00 33 00 00 00 00 00 00 37 00 00 00 02 00 00 39 | .3......7......9 +[stage-6] 0160 | 00 00 00 01 00 00 3c 00 00 00 01 00 00 3d 00 00 | ......<......=.. +[stage-6] 0170 | 00 00 00 00 40 00 00 00 00 00 00 41 00 00 00 00 | ....@......A.... +[stage-6] 0180 | 00 00 42 00 00 00 01 00 00 44 00 00 00 00 00 00 | ..B......D...... +[stage-6] 0190 | 45 00 00 00 00 00 00 4a 00 00 00 00 00 00 4b 00 | E......J......K. +[stage-6] 01a0 | 00 00 00 00 00 50 00 00 00 00 00 00 51 00 00 00 | .....P......Q... +[stage-6] 01b0 | 00 00 00 00 00 00 03 00 3d 04 0e 67 72 6f 75 70 | ........=..group +[stage-6] 01c0 | 2e 76 65 72 73 69 6f 6e 00 00 00 01 00 0e 6b 72 | .version......kr +[stage-6] 01d0 | 61 66 74 2e 76 65 72 73 69 6f 6e 00 00 00 01 00 | aft.version..... +[stage-6] 01e0 | 11 6d 65 74 61 64 61 74 61 2e 76 65 72 73 69 6f | .metadata.versio +[stage-6] 01f0 | 6e 00 01 00 16 00 01 08 00 00 00 00 00 00 00 0d | n............... +[stage-6] 0200 | 02 17 02 11 6d 65 74 61 64 61 74 61 2e 76 65 72 | ....metadata.ver +[stage-6] 0210 | 73 69 6f 6e 00 14 00 14 00 | sion..... +[stage-6]  +[stage-6] [Decoder] - .ResponseHeader +[stage-6] [Decoder]  - .correlation_id (177586623) +[stage-6] [Decoder] - .ResponseBody +[stage-6] [Decoder]  - .error_code (0) +[stage-6] [Decoder]  - .num_api_keys (61) +[stage-6] [Decoder]  - .ApiKeys[0] +[stage-6] [Decoder]  - .api_key (0) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (11) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[1] +[stage-6] [Decoder]  - .api_key (1) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (17) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[2] +[stage-6] [Decoder]  - .api_key (2) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (9) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[3] +[stage-6] [Decoder]  - .api_key (3) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (12) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[4] +[stage-6] [Decoder]  - .api_key (8) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (9) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[5] +[stage-6] [Decoder]  - .api_key (9) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (9) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[6] +[stage-6] [Decoder]  - .api_key (10) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (6) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[7] +[stage-6] [Decoder]  - .api_key (11) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (9) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[8] +[stage-6] [Decoder]  - .api_key (12) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (4) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[9] +[stage-6] [Decoder]  - .api_key (13) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (5) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[10] +[stage-6] [Decoder]  - .api_key (14) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (5) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[11] +[stage-6] [Decoder]  - .api_key (15) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (5) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[12] +[stage-6] [Decoder]  - .api_key (16) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (5) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[13] +[stage-6] [Decoder]  - .api_key (17) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (1) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[14] +[stage-6] [Decoder]  - .api_key (18) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (4) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[15] +[stage-6] [Decoder]  - .api_key (19) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (7) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[16] +[stage-6] [Decoder]  - .api_key (20) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (6) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[17] +[stage-6] [Decoder]  - .api_key (21) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (2) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[18] +[stage-6] [Decoder]  - .api_key (22) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (5) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[19] +[stage-6] [Decoder]  - .api_key (23) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (4) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[20] +[stage-6] [Decoder]  - .api_key (24) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (5) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[21] +[stage-6] [Decoder]  - .api_key (25) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (4) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[22] +[stage-6] [Decoder]  - .api_key (26) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (4) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[23] +[stage-6] [Decoder]  - .api_key (27) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (1) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[24] +[stage-6] [Decoder]  - .api_key (28) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (4) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[25] +[stage-6] [Decoder]  - .api_key (29) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (3) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[26] +[stage-6] [Decoder]  - .api_key (30) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (3) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[27] +[stage-6] [Decoder]  - .api_key (31) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (3) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[28] +[stage-6] [Decoder]  - .api_key (32) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (4) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[29] +[stage-6] [Decoder]  - .api_key (33) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (2) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[30] +[stage-6] [Decoder]  - .api_key (34) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (2) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[31] +[stage-6] [Decoder]  - .api_key (35) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (4) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[32] +[stage-6] [Decoder]  - .api_key (36) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (2) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[33] +[stage-6] [Decoder]  - .api_key (37) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (3) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[34] +[stage-6] [Decoder]  - .api_key (38) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (3) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[35] +[stage-6] [Decoder]  - .api_key (39) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (2) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[36] +[stage-6] [Decoder]  - .api_key (40) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (2) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[37] +[stage-6] [Decoder]  - .api_key (41) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (3) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[38] +[stage-6] [Decoder]  - .api_key (42) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (2) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[39] +[stage-6] [Decoder]  - .api_key (43) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (2) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[40] +[stage-6] [Decoder]  - .api_key (44) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (1) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[41] +[stage-6] [Decoder]  - .api_key (45) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[42] +[stage-6] [Decoder]  - .api_key (46) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[43] +[stage-6] [Decoder]  - .api_key (47) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[44] +[stage-6] [Decoder]  - .api_key (48) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (1) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[45] +[stage-6] [Decoder]  - .api_key (49) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (1) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[46] +[stage-6] [Decoder]  - .api_key (50) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[47] +[stage-6] [Decoder]  - .api_key (51) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[48] +[stage-6] [Decoder]  - .api_key (55) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (2) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[49] +[stage-6] [Decoder]  - .api_key (57) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (1) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[50] +[stage-6] [Decoder]  - .api_key (60) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (1) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[51] +[stage-6] [Decoder]  - .api_key (61) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[52] +[stage-6] [Decoder]  - .api_key (64) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[53] +[stage-6] [Decoder]  - .api_key (65) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[54] +[stage-6] [Decoder]  - .api_key (66) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (1) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[55] +[stage-6] [Decoder]  - .api_key (68) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[56] +[stage-6] [Decoder]  - .api_key (69) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[57] +[stage-6] [Decoder]  - .api_key (74) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[58] +[stage-6] [Decoder]  - .api_key (75) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[59] +[stage-6] [Decoder]  - .api_key (80) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .ApiKeys[60] +[stage-6] [Decoder]  - .api_key (81) +[stage-6] [Decoder]  - .min_version (0) +[stage-6] [Decoder]  - .max_version (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] [Decoder]  - .throttle_time_ms (0) +[stage-6] [Decoder]  - .TAG_BUFFER +[stage-6] ✓ Correlation ID: 177586623 +[stage-6] ✓ Error code: 0 (NO_ERROR) +[stage-6] ✓ API keys array length: 61 +[stage-6] ✓ MinVersion for FETCH is <= 16 & >= 0 +[stage-6] ✓ MaxVersion for FETCH is >= 16 +[stage-6] ✓ MinVersion for API_VERSIONS is <= 4 & >= 0 +[stage-6] ✓ MaxVersion for API_VERSIONS is >= 4 +[stage-6] Test passed. +[stage-6] Terminating program +[stage-6] Program terminated successfully + +[stage-5] Running tests for Stage #5: dh6 +[stage-5] $ ./your_program.sh /tmp/server.properties +[stage-5] [Serializer] Writing log files to: /tmp/kraft-combined-logs +[stage-5] [Serializer]  - Wrote file to: /tmp/server.properties +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/meta.properties +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log +[stage-5] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs +[stage-5] Connecting to broker at: localhost:9092 +[stage-5] Connection to broker at localhost:9092 successful +[stage-5] Sending "Fetch" (version: 16) request (Correlation id: 1616512461) +[stage-5] Hexdump of sent "Fetch" request:  +[stage-5] Idx | Hex | ASCII +[stage-5] -----+-------------------------------------------------+----------------- +[stage-5] 0000 | 00 00 00 30 00 01 00 10 60 5a 05 cd 00 0c 6b 61 | ...0....`Z....ka +[stage-5] 0010 | 66 6b 61 2d 74 65 73 74 65 72 00 00 00 01 f4 00 | fka-tester...... +[stage-5] 0020 | 00 00 01 03 20 00 00 00 00 00 00 00 00 00 00 00 | .... ........... +[stage-5] 0030 | 01 01 01 00 | .... +[stage-5]  +[stage-5] Hexdump of received "Fetch" response:  +[stage-5] Idx | Hex | ASCII +[stage-5] -----+-------------------------------------------------+----------------- +[stage-5] 0000 | 60 5a 05 cd 00 00 00 00 00 00 00 0f 32 04 12 01 | `Z..........2... +[stage-5] 0010 | 00 | . +[stage-5]  +[stage-5] [Decoder] - .ResponseHeader +[stage-5] [Decoder]  - .correlation_id (1616512461) +[stage-5] [Decoder]  - .TAG_BUFFER +[stage-5] [Decoder] - .ResponseBody +[stage-5] [Decoder]  - .throttle_time_ms (0) +[stage-5] [Decoder]  - .error_code (0) +[stage-5] [Decoder]  - .session_id (254936082) +[stage-5] [Decoder]  - .num_responses (0) +[stage-5] [Decoder]  - .TAG_BUFFER +[stage-5] ✓ Correlation ID: 1616512461 +[stage-5] ✓ Throttle Time: 0 +[stage-5] ✓ Error Code: 0 (NO_ERROR) +[stage-5]  ✓ TopicResponses: [] +[stage-5] Test passed. +[stage-5] Terminating program +[stage-5] Program terminated successfully + +[stage-4] Running tests for Stage #4: hn6 [stage-4] $ ./your_program.sh /tmp/server.properties +[stage-4] [Serializer] Writing log files to: /tmp/kraft-combined-logs +[stage-4] [Serializer]  - Wrote file to: /tmp/server.properties +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/meta.properties +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log +[stage-4] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs [stage-4] Connecting to broker at: localhost:9092 [stage-4] Connection to broker at localhost:9092 successful -[stage-4] Sending "ApiVersions" (version: 4) request (Correlation id: 177586623) -[stage-4] Hexdump of sent "ApiVersions" request:  +[stage-4] Sending "Fetch" (version: 16) request (Correlation id: 96710698) +[stage-4] Hexdump of sent "Fetch" request:  [stage-4] Idx | Hex | ASCII [stage-4] -----+-------------------------------------------------+----------------- -[stage-4] 0000 | 00 00 00 23 00 12 00 04 0a 95 c1 bf 00 09 6b 61 | ...#..........ka -[stage-4] 0010 | 66 6b 61 2d 63 6c 69 00 0a 6b 61 66 6b 61 2d 63 | fka-cli..kafka-c -[stage-4] 0020 | 6c 69 04 30 2e 31 00 | li.0.1. +[stage-4] 0000 | 00 00 00 60 00 01 00 10 05 c3 b0 2a 00 09 6b 61 | ...`.......*..ka +[stage-4] 0010 | 66 6b 61 2d 63 6c 69 00 00 00 01 f4 00 00 00 01 | fka-cli......... +[stage-4] 0020 | 03 20 00 00 00 00 00 00 00 00 00 00 00 02 00 00 | . .............. +[stage-4] 0030 | 00 00 00 00 00 00 00 00 00 00 00 00 11 09 02 00 | ................ +[stage-4] 0040 | 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 ff | ................ +[stage-4] 0050 | ff ff ff ff ff ff ff ff ff ff ff 00 10 00 00 00 | ................ +[stage-4] 0060 | 00 01 01 00 | .... [stage-4]  -[stage-4] Hexdump of received "ApiVersions" response:  +[stage-4] Hexdump of received "Fetch" response:  [stage-4] Idx | Hex | ASCII [stage-4] -----+-------------------------------------------------+----------------- -[stage-4] 0000 | 0a 95 c1 bf 00 00 3e 00 00 00 00 00 0b 00 00 01 | ......>......... -[stage-4] 0010 | 00 00 00 11 00 00 02 00 00 00 09 00 00 03 00 00 | ................ -[stage-4] 0020 | 00 0c 00 00 08 00 00 00 09 00 00 09 00 00 00 09 | ................ -[stage-4] 0030 | 00 00 0a 00 00 00 06 00 00 0b 00 00 00 09 00 00 | ................ -[stage-4] 0040 | 0c 00 00 00 04 00 00 0d 00 00 00 05 00 00 0e 00 | ................ -[stage-4] 0050 | 00 00 05 00 00 0f 00 00 00 05 00 00 10 00 00 00 | ................ -[stage-4] 0060 | 05 00 00 11 00 00 00 01 00 00 12 00 00 00 04 00 | ................ -[stage-4] 0070 | 00 13 00 00 00 07 00 00 14 00 00 00 06 00 00 15 | ................ -[stage-4] 0080 | 00 00 00 02 00 00 16 00 00 00 05 00 00 17 00 00 | ................ -[stage-4] 0090 | 00 04 00 00 18 00 00 00 05 00 00 19 00 00 00 04 | ................ -[stage-4] 00a0 | 00 00 1a 00 00 00 04 00 00 1b 00 00 00 01 00 00 | ................ -[stage-4] 00b0 | 1c 00 00 00 04 00 00 1d 00 00 00 03 00 00 1e 00 | ................ -[stage-4] 00c0 | 00 00 03 00 00 1f 00 00 00 03 00 00 20 00 00 00 | ............ ... -[stage-4] 00d0 | 04 00 00 21 00 00 00 02 00 00 22 00 00 00 02 00 | ...!......"..... -[stage-4] 00e0 | 00 23 00 00 00 04 00 00 24 00 00 00 02 00 00 25 | .#......$......% -[stage-4] 00f0 | 00 00 00 03 00 00 26 00 00 00 03 00 00 27 00 00 | ......&......'.. -[stage-4] 0100 | 00 02 00 00 28 00 00 00 02 00 00 29 00 00 00 03 | ....(......).... -[stage-4] 0110 | 00 00 2a 00 00 00 02 00 00 2b 00 00 00 02 00 00 | ..*......+...... -[stage-4] 0120 | 2c 00 00 00 01 00 00 2d 00 00 00 00 00 00 2e 00 | ,......-........ -[stage-4] 0130 | 00 00 00 00 00 2f 00 00 00 00 00 00 30 00 00 00 | ...../......0... -[stage-4] 0140 | 01 00 00 31 00 00 00 01 00 00 32 00 00 00 00 00 | ...1......2..... -[stage-4] 0150 | 00 33 00 00 00 00 00 00 37 00 00 00 02 00 00 39 | .3......7......9 -[stage-4] 0160 | 00 00 00 01 00 00 3c 00 00 00 01 00 00 3d 00 00 | ......<......=.. -[stage-4] 0170 | 00 00 00 00 40 00 00 00 00 00 00 41 00 00 00 00 | ....@......A.... -[stage-4] 0180 | 00 00 42 00 00 00 01 00 00 44 00 00 00 00 00 00 | ..B......D...... -[stage-4] 0190 | 45 00 00 00 00 00 00 4a 00 00 00 00 00 00 4b 00 | E......J......K. -[stage-4] 01a0 | 00 00 00 00 00 50 00 00 00 00 00 00 51 00 00 00 | .....P......Q... -[stage-4] 01b0 | 00 00 00 00 00 00 03 00 3d 04 0e 67 72 6f 75 70 | ........=..group -[stage-4] 01c0 | 2e 76 65 72 73 69 6f 6e 00 00 00 01 00 0e 6b 72 | .version......kr -[stage-4] 01d0 | 61 66 74 2e 76 65 72 73 69 6f 6e 00 00 00 01 00 | aft.version..... -[stage-4] 01e0 | 11 6d 65 74 61 64 61 74 61 2e 76 65 72 73 69 6f | .metadata.versio -[stage-4] 01f0 | 6e 00 01 00 16 00 01 08 00 00 00 00 00 00 00 0c | n............... -[stage-4] 0200 | 02 17 02 11 6d 65 74 61 64 61 74 61 2e 76 65 72 | ....metadata.ver -[stage-4] 0210 | 73 69 6f 6e 00 14 00 14 00 | sion..... +[stage-4] 0000 | 05 c3 b0 2a 00 00 00 00 00 00 00 08 61 5f ef 02 | ...*........a_.. +[stage-4] 0010 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 11 09 | ................ +[stage-4] 0020 | 02 00 00 00 00 00 64 ff ff ff ff ff ff ff ff ff | ......d......... +[stage-4] 0030 | ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff 01 | ................ +[stage-4] 0040 | ff ff ff ff 01 00 00 00 | ........ [stage-4]  [stage-4] [Decoder] - .ResponseHeader -[stage-4] [Decoder]  - .correlation_id (177586623) +[stage-4] [Decoder]  - .correlation_id (96710698) +[stage-4] [Decoder]  - .TAG_BUFFER [stage-4] [Decoder] - .ResponseBody +[stage-4] [Decoder]  - .throttle_time_ms (0) [stage-4] [Decoder]  - .error_code (0) -[stage-4] [Decoder]  - .num_api_keys (61) -[stage-4] [Decoder]  - .ApiKeys[0] -[stage-4] [Decoder]  - .api_key (0) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (11) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[1] -[stage-4] [Decoder]  - .api_key (1) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (17) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[2] -[stage-4] [Decoder]  - .api_key (2) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (9) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[3] -[stage-4] [Decoder]  - .api_key (3) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (12) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[4] -[stage-4] [Decoder]  - .api_key (8) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (9) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[5] -[stage-4] [Decoder]  - .api_key (9) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (9) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[6] -[stage-4] [Decoder]  - .api_key (10) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (6) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[7] -[stage-4] [Decoder]  - .api_key (11) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (9) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[8] -[stage-4] [Decoder]  - .api_key (12) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (4) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[9] -[stage-4] [Decoder]  - .api_key (13) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (5) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[10] -[stage-4] [Decoder]  - .api_key (14) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (5) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[11] -[stage-4] [Decoder]  - .api_key (15) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (5) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[12] -[stage-4] [Decoder]  - .api_key (16) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (5) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[13] -[stage-4] [Decoder]  - .api_key (17) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (1) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[14] -[stage-4] [Decoder]  - .api_key (18) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (4) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[15] -[stage-4] [Decoder]  - .api_key (19) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (7) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[16] -[stage-4] [Decoder]  - .api_key (20) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (6) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[17] -[stage-4] [Decoder]  - .api_key (21) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (2) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[18] -[stage-4] [Decoder]  - .api_key (22) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (5) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[19] -[stage-4] [Decoder]  - .api_key (23) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (4) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[20] -[stage-4] [Decoder]  - .api_key (24) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (5) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[21] -[stage-4] [Decoder]  - .api_key (25) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (4) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[22] -[stage-4] [Decoder]  - .api_key (26) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (4) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[23] -[stage-4] [Decoder]  - .api_key (27) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (1) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[24] -[stage-4] [Decoder]  - .api_key (28) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (4) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[25] -[stage-4] [Decoder]  - .api_key (29) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (3) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[26] -[stage-4] [Decoder]  - .api_key (30) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (3) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[27] -[stage-4] [Decoder]  - .api_key (31) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (3) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[28] -[stage-4] [Decoder]  - .api_key (32) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (4) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[29] -[stage-4] [Decoder]  - .api_key (33) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (2) +[stage-4] [Decoder]  - .session_id (140599279) +[stage-4] [Decoder]  - .num_responses (1) +[stage-4] [Decoder]  - .TopicResponse[0] +[stage-4] [Decoder]  - .topic_id (00000000-0000-0000-0000-000000001109) +[stage-4] [Decoder]  - .num_partitions (1) +[stage-4] [Decoder]  - .PartitionResponse[0] +[stage-4] [Decoder]  - .partition_index (0) +[stage-4] [Decoder]  - .error_code (100) +[stage-4] [Decoder]  - .high_watermark (-1) +[stage-4] [Decoder]  - .last_stable_offset (-1) +[stage-4] [Decoder]  - .log_start_offset (-1) +[stage-4] [Decoder]  - .num_aborted_transactions (0) +[stage-4] [Decoder]  - .preferred_read_replica (-1) +[stage-4] [Decoder]  - .compact_records_length (0) +[stage-4] [Decoder]  - .TAG_BUFFER [stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[30] -[stage-4] [Decoder]  - .api_key (34) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (2) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[31] -[stage-4] [Decoder]  - .api_key (35) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (4) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[32] -[stage-4] [Decoder]  - .api_key (36) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (2) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[33] -[stage-4] [Decoder]  - .api_key (37) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (3) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[34] -[stage-4] [Decoder]  - .api_key (38) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (3) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[35] -[stage-4] [Decoder]  - .api_key (39) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (2) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[36] -[stage-4] [Decoder]  - .api_key (40) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (2) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[37] -[stage-4] [Decoder]  - .api_key (41) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (3) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[38] -[stage-4] [Decoder]  - .api_key (42) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (2) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[39] -[stage-4] [Decoder]  - .api_key (43) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (2) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[40] -[stage-4] [Decoder]  - .api_key (44) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (1) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[41] -[stage-4] [Decoder]  - .api_key (45) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[42] -[stage-4] [Decoder]  - .api_key (46) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[43] -[stage-4] [Decoder]  - .api_key (47) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[44] -[stage-4] [Decoder]  - .api_key (48) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (1) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[45] -[stage-4] [Decoder]  - .api_key (49) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (1) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[46] -[stage-4] [Decoder]  - .api_key (50) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[47] -[stage-4] [Decoder]  - .api_key (51) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[48] -[stage-4] [Decoder]  - .api_key (55) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (2) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[49] -[stage-4] [Decoder]  - .api_key (57) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (1) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[50] -[stage-4] [Decoder]  - .api_key (60) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (1) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[51] -[stage-4] [Decoder]  - .api_key (61) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[52] -[stage-4] [Decoder]  - .api_key (64) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[53] -[stage-4] [Decoder]  - .api_key (65) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[54] -[stage-4] [Decoder]  - .api_key (66) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (1) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[55] -[stage-4] [Decoder]  - .api_key (68) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[56] -[stage-4] [Decoder]  - .api_key (69) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[57] -[stage-4] [Decoder]  - .api_key (74) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[58] -[stage-4] [Decoder]  - .api_key (75) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[59] -[stage-4] [Decoder]  - .api_key (80) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .ApiKeys[60] -[stage-4] [Decoder]  - .api_key (81) -[stage-4] [Decoder]  - .min_version (0) -[stage-4] [Decoder]  - .max_version (0) -[stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] [Decoder]  - .throttle_time_ms (0) [stage-4] [Decoder]  - .TAG_BUFFER -[stage-4] ✓ Correlation ID: 177586623 -[stage-4] ✓ Error code: 0 (NO_ERROR) -[stage-4] ✓ API keys array length: 61 -[stage-4] ✓ MinVersion for FETCH is <= 16 & >= 0 -[stage-4] ✓ MaxVersion for FETCH is >= 16 -[stage-4] ✓ MinVersion for API_VERSIONS is <= 4 & >= 0 -[stage-4] ✓ MaxVersion for API_VERSIONS is >= 4 +[stage-4] ✓ Correlation ID: 96710698 +[stage-4] ✓ Throttle Time: 0 +[stage-4] ✓ Error Code: 0 (NO_ERROR) +[stage-4]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-0000-0000-000000001109 +[stage-4]  ✓ PartitionResponse[0] Error code: 100 (UNKNOWN_TOPIC_ID) +[stage-4]  ✓ PartitionResponse[0] Partition Index: 0 +[stage-4]  ✓ RecordBatches: [] [stage-4] Test passed. [stage-4] Terminating program [stage-4] Program terminated successfully -[stage-3] Running tests for Stage #3: dh6 +[stage-3] Running tests for Stage #3: cm4 [stage-3] $ ./your_program.sh /tmp/server.properties [stage-3] [Serializer] Writing log files to: /tmp/kraft-combined-logs [stage-3] [Serializer]  - Wrote file to: /tmp/server.properties @@ -381,50 +506,73 @@ Debug = true [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata -[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/partition.metadata -[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/partition.metadata +[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata +[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log -[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/00000000000000000000.log -[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/00000000000000000000.log +[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log +[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log [stage-3] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs [stage-3] Connecting to broker at: localhost:9092 [stage-3] Connection to broker at localhost:9092 successful -[stage-3] Sending "Fetch" (version: 16) request (Correlation id: 1616512461) +[stage-3] Sending "Fetch" (version: 16) request (Correlation id: 254678266) [stage-3] Hexdump of sent "Fetch" request:  [stage-3] Idx | Hex | ASCII [stage-3] -----+-------------------------------------------------+----------------- -[stage-3] 0000 | 00 00 00 30 00 01 00 10 60 5a 05 cd 00 0c 6b 61 | ...0....`Z....ka -[stage-3] 0010 | 66 6b 61 2d 74 65 73 74 65 72 00 00 00 01 f4 00 | fka-tester...... -[stage-3] 0020 | 00 00 01 03 20 00 00 00 00 00 00 00 00 00 00 00 | .... ........... -[stage-3] 0030 | 01 01 01 00 | .... +[stage-3] 0000 | 00 00 00 60 00 01 00 10 0f 2e 14 fa 00 09 6b 61 | ...`..........ka +[stage-3] 0010 | 66 6b 61 2d 63 6c 69 00 00 00 01 f4 00 00 00 01 | fka-cli......... +[stage-3] 0020 | 03 20 00 00 00 00 00 00 00 00 00 00 00 02 00 00 | . .............. +[stage-3] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 31 02 00 | ....@........1.. +[stage-3] 0040 | 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 ff | ................ +[stage-3] 0050 | ff ff ff ff ff ff ff ff ff ff ff 00 10 00 00 00 | ................ +[stage-3] 0060 | 00 01 01 00 | .... [stage-3]  [stage-3] Hexdump of received "Fetch" response:  [stage-3] Idx | Hex | ASCII [stage-3] -----+-------------------------------------------------+----------------- -[stage-3] 0000 | 60 5a 05 cd 00 00 00 00 00 00 00 08 09 e5 58 01 | `Z............X. -[stage-3] 0010 | 00 | . +[stage-3] 0000 | 0f 2e 14 fa 00 00 00 00 00 00 00 0e 3f 6d 78 02 | ............?mx. +[stage-3] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 31 | ......@........1 +[stage-3] 0020 | 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................ +[stage-3] 0030 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................ +[stage-3] 0040 | ff ff ff ff 01 00 00 00 | ........ [stage-3]  [stage-3] [Decoder] - .ResponseHeader -[stage-3] [Decoder]  - .correlation_id (1616512461) +[stage-3] [Decoder]  - .correlation_id (254678266) [stage-3] [Decoder]  - .TAG_BUFFER [stage-3] [Decoder] - .ResponseBody [stage-3] [Decoder]  - .throttle_time_ms (0) [stage-3] [Decoder]  - .error_code (0) -[stage-3] [Decoder]  - .session_id (134866264) -[stage-3] [Decoder]  - .num_responses (0) +[stage-3] [Decoder]  - .session_id (239037816) +[stage-3] [Decoder]  - .num_responses (1) +[stage-3] [Decoder]  - .TopicResponse[0] +[stage-3] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000031) +[stage-3] [Decoder]  - .num_partitions (1) +[stage-3] [Decoder]  - .PartitionResponse[0] +[stage-3] [Decoder]  - .partition_index (0) +[stage-3] [Decoder]  - .error_code (0) +[stage-3] [Decoder]  - .high_watermark (0) +[stage-3] [Decoder]  - .last_stable_offset (0) +[stage-3] [Decoder]  - .log_start_offset (0) +[stage-3] [Decoder]  - .num_aborted_transactions (0) +[stage-3] [Decoder]  - .preferred_read_replica (-1) +[stage-3] [Decoder]  - .compact_records_length (0) +[stage-3] [Decoder]  - .TAG_BUFFER +[stage-3] [Decoder]  - .TAG_BUFFER [stage-3] [Decoder]  - .TAG_BUFFER -[stage-3] ✓ Correlation ID: 1616512461 +[stage-3] ✓ Correlation ID: 254678266 [stage-3] ✓ Throttle Time: 0 [stage-3] ✓ Error Code: 0 (NO_ERROR) -[stage-3]  ✓ TopicResponses: [] +[stage-3]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000031 +[stage-3]  ✓ PartitionResponse[0] Error code: 0 (NO_ERROR) +[stage-3]  ✓ PartitionResponse[0] Partition Index: 0 +[stage-3]  ✓ RecordBatches: [] [stage-3] Test passed. [stage-3] Terminating program [stage-3] Program terminated successfully -[stage-2] Running tests for Stage #2: hn6 +[stage-2] Running tests for Stage #2: eg2 [stage-2] $ ./your_program.sh /tmp/server.properties [stage-2] [Serializer] Writing log files to: /tmp/kraft-combined-logs [stage-2] [Serializer]  - Wrote file to: /tmp/server.properties @@ -432,25 +580,25 @@ Debug = true [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata -[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/partition.metadata -[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/partition.metadata +[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata +[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log -[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/00000000000000000000.log -[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/00000000000000000000.log +[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log +[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log [stage-2] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs [stage-2] Connecting to broker at: localhost:9092 [stage-2] Connection to broker at localhost:9092 successful -[stage-2] Sending "Fetch" (version: 16) request (Correlation id: 96710698) +[stage-2] Sending "Fetch" (version: 16) request (Correlation id: 1893237013) [stage-2] Hexdump of sent "Fetch" request:  [stage-2] Idx | Hex | ASCII [stage-2] -----+-------------------------------------------------+----------------- -[stage-2] 0000 | 00 00 00 60 00 01 00 10 05 c3 b0 2a 00 09 6b 61 | ...`.......*..ka +[stage-2] 0000 | 00 00 00 60 00 01 00 10 70 d8 81 15 00 09 6b 61 | ...`....p.....ka [stage-2] 0010 | 66 6b 61 2d 63 6c 69 00 00 00 01 f4 00 00 00 01 | fka-cli......... [stage-2] 0020 | 03 20 00 00 00 00 00 00 00 00 00 00 00 02 00 00 | . .............. -[stage-2] 0030 | 00 00 00 00 00 00 00 00 00 00 00 00 15 33 02 00 | .............3.. +[stage-2] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 32 02 00 | ....@........2.. [stage-2] 0040 | 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 ff | ................ [stage-2] 0050 | ff ff ff ff ff ff ff ff ff ff ff 00 10 00 00 00 | ................ [stage-2] 0060 | 00 01 01 00 | .... @@ -458,47 +606,78 @@ Debug = true [stage-2] Hexdump of received "Fetch" response:  [stage-2] Idx | Hex | ASCII [stage-2] -----+-------------------------------------------------+----------------- -[stage-2] 0000 | 05 c3 b0 2a 00 00 00 00 00 00 00 00 d3 31 b9 02 | ...*.........1.. -[stage-2] 0010 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 15 33 | ...............3 -[stage-2] 0020 | 02 00 00 00 00 00 64 ff ff ff ff ff ff ff ff ff | ......d......... -[stage-2] 0030 | ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff 01 | ................ -[stage-2] 0040 | ff ff ff ff 01 00 00 00 | ........ +[stage-2] 0000 | 70 d8 81 15 00 00 00 00 00 00 00 0b 66 6c 3f 02 | p...........fl?. +[stage-2] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 32 | ......@........2 +[stage-2] 0020 | 02 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 | ................ +[stage-2] 0030 | 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 | ................ +[stage-2] 0040 | ff ff ff ff 51 00 00 00 00 00 00 00 00 00 00 00 | ....Q........... +[stage-2] 0050 | 44 00 00 00 00 02 98 ec 18 d3 00 00 00 00 00 00 | D............... +[stage-2] 0060 | 00 00 01 91 e0 5b 6d 8b 00 00 01 91 e0 5b 6d 8b | .....[m......[m. +[stage-2] 0070 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................ +[stage-2] 0080 | 00 01 24 00 00 00 01 18 48 65 6c 6c 6f 20 57 6f | ..$.....Hello Wo +[stage-2] 0090 | 72 6c 64 21 00 00 00 00 | rld!.... [stage-2]  [stage-2] [Decoder] - .ResponseHeader -[stage-2] [Decoder]  - .correlation_id (96710698) +[stage-2] [Decoder]  - .correlation_id (1893237013) [stage-2] [Decoder]  - .TAG_BUFFER [stage-2] [Decoder] - .ResponseBody [stage-2] [Decoder]  - .throttle_time_ms (0) [stage-2] [Decoder]  - .error_code (0) -[stage-2] [Decoder]  - .session_id (13840825) +[stage-2] [Decoder]  - .session_id (191261759) [stage-2] [Decoder]  - .num_responses (1) [stage-2] [Decoder]  - .TopicResponse[0] -[stage-2] [Decoder]  - .topic_id (00000000-0000-0000-0000-000000001533) +[stage-2] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000032) [stage-2] [Decoder]  - .num_partitions (1) [stage-2] [Decoder]  - .PartitionResponse[0] [stage-2] [Decoder]  - .partition_index (0) -[stage-2] [Decoder]  - .error_code (100) -[stage-2] [Decoder]  - .high_watermark (-1) -[stage-2] [Decoder]  - .last_stable_offset (-1) -[stage-2] [Decoder]  - .log_start_offset (-1) +[stage-2] [Decoder]  - .error_code (0) +[stage-2] [Decoder]  - .high_watermark (1) +[stage-2] [Decoder]  - .last_stable_offset (1) +[stage-2] [Decoder]  - .log_start_offset (0) [stage-2] [Decoder]  - .num_aborted_transactions (0) [stage-2] [Decoder]  - .preferred_read_replica (-1) -[stage-2] [Decoder]  - .compact_records_length (0) +[stage-2] [Decoder]  - .compact_records_length (80) +[stage-2] [Decoder]  - .RecordBatch[0] +[stage-2] [Decoder]  - .base_offset (0) +[stage-2] [Decoder]  - .batch_length (68) +[stage-2] [Decoder]  - .partition_leader_epoch (0) +[stage-2] [Decoder]  - .magic_byte (2) +[stage-2] [Decoder]  - .crc (-1729357613) +[stage-2] [Decoder]  - .record_attributes (0) +[stage-2] [Decoder]  - .last_offset_delta (0) +[stage-2] [Decoder]  - .base_timestamp (1726045973899) +[stage-2] [Decoder]  - .max_timestamp (1726045973899) +[stage-2] [Decoder]  - .producer_id (0) +[stage-2] [Decoder]  - .producer_epoch (0) +[stage-2] [Decoder]  - .base_sequence (0) +[stage-2] [Decoder]  - .num_records (1) +[stage-2] [Decoder]  - .Record[0] +[stage-2] [Decoder]  - .length (18) +[stage-2] [Decoder]  - .attributes (0) +[stage-2] [Decoder]  - .timestamp_delta (0) +[stage-2] [Decoder]  - .offset_delta (0) +[stage-2] [Decoder]  - .key_length (-1) +[stage-2] [Decoder]  - .key ("") +[stage-2] [Decoder]  - .value_length (12) +[stage-2] [Decoder]  - .value ("Hello World!") +[stage-2] [Decoder]  - .num_headers (0) [stage-2] [Decoder]  - .TAG_BUFFER [stage-2] [Decoder]  - .TAG_BUFFER [stage-2] [Decoder]  - .TAG_BUFFER -[stage-2] ✓ Correlation ID: 96710698 +[stage-2] ✓ Correlation ID: 1893237013 [stage-2] ✓ Throttle Time: 0 [stage-2] ✓ Error Code: 0 (NO_ERROR) -[stage-2]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-0000-0000-000000001533 -[stage-2]  ✓ PartitionResponse[0] Error code: 100 (UNKNOWN_TOPIC_ID) +[stage-2]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000032 +[stage-2]  ✓ PartitionResponse[0] Error code: 0 (NO_ERROR) [stage-2]  ✓ PartitionResponse[0] Partition Index: 0 -[stage-2]  ✓ RecordBatches: [] +[stage-2]  ✓ RecordBatch[0] BaseOffset: 0 +[stage-2]  ✓ Record[0] Value: Hello World! +[stage-2] ✓ RecordBatch bytes match with the contents on disk [stage-2] Test passed. [stage-2] Terminating program [stage-2] Program terminated successfully -[stage-1] Running tests for Stage #1: cm4 +[stage-1] Running tests for Stage #1: fd8 [stage-1] $ ./your_program.sh /tmp/server.properties [stage-1] [Serializer] Writing log files to: /tmp/kraft-combined-logs [stage-1] [Serializer]  - Wrote file to: /tmp/server.properties @@ -506,25 +685,25 @@ Debug = true [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata -[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/partition.metadata -[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/partition.metadata +[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata +[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log -[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/00000000000000000000.log -[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/00000000000000000000.log +[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log +[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log [stage-1] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs [stage-1] Connecting to broker at: localhost:9092 [stage-1] Connection to broker at localhost:9092 successful -[stage-1] Sending "Fetch" (version: 16) request (Correlation id: 254678266) +[stage-1] Sending "Fetch" (version: 16) request (Correlation id: 1698452642) [stage-1] Hexdump of sent "Fetch" request:  [stage-1] Idx | Hex | ASCII [stage-1] -----+-------------------------------------------------+----------------- -[stage-1] 0000 | 00 00 00 60 00 01 00 10 0f 2e 14 fa 00 09 6b 61 | ...`..........ka +[stage-1] 0000 | 00 00 00 60 00 01 00 10 65 3c 54 a2 00 09 6b 61 | ...`....e Date: Thu, 17 Oct 2024 14:31:42 +0530 Subject: [PATCH 10/12] refactor: add regex replace for Record Value and RecordBatch BaseOffset --- Makefile | 2 +- internal/stages_test.go | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 95e7fee..c2a8cc9 100644 --- a/Makefile +++ b/Makefile @@ -34,7 +34,7 @@ test_all: test_fetch_with_kafka: build CODECRAFTERS_REPOSITORY_DIR=./internal/test_helpers/pass_all \ - CODECRAFTERS_TEST_CASES_JSON="[{\"slug\":\"gs0\",\"tester_log_prefix\":\"stage-F1\",\"title\":\"Stage #F1: API Version with Fetch Key\"}, {\"slug\":\"dh6\",\"tester_log_prefix\":\"stage-F2\",\"title\":\"Stage #F2: Fetch with no topics\"}, {\"slug\":\"hn6\",\"tester_log_prefix\":\"stage-F3\",\"title\":\"Stage #F3: Fetch with unknown topic\"}, {\"slug\":\"cm4\",\"tester_log_prefix\":\"stage-F4\",\"title\":\"Stage #F4: Fetch with empty topic\"}, {\"slug\":\"eg2\",\"tester_log_prefix\":\"stage-F5\",\"title\":\"Stage #F5: Single Fetch from Disk\"}, {\"slug\":\"fd8\",\"tester_log_prefix\":\"stage-F6\",\"title\":\"Stage #F6: Multi Fetch from Disk\"}, ]" \ + CODECRAFTERS_TEST_CASES_JSON="[{\"slug\":\"gs0\",\"tester_log_prefix\":\"stage-F1\",\"title\":\"Stage #F1: API Version with Fetch Key\"}, {\"slug\":\"dh6\",\"tester_log_prefix\":\"stage-F2\",\"title\":\"Stage #F2: Fetch with no topics\"}, {\"slug\":\"hn6\",\"tester_log_prefix\":\"stage-F3\",\"title\":\"Stage #F3: Fetch with unknown topic\"}, {\"slug\":\"cm4\",\"tester_log_prefix\":\"stage-F4\",\"title\":\"Stage #F4: Fetch with empty topic\"}, {\"slug\":\"eg2\",\"tester_log_prefix\":\"stage-F5\",\"title\":\"Stage #F5: Single Fetch from Disk\"}, {\"slug\":\"fd8\",\"tester_log_prefix\":\"stage-F6\",\"title\":\"Stage #F6: Multi Fetch from Disk\"}]" \ dist/main.out test: diff --git a/internal/stages_test.go b/internal/stages_test.go index b365f65..2d14c62 100644 --- a/internal/stages_test.go +++ b/internal/stages_test.go @@ -67,6 +67,8 @@ func normalizeTesterOutput(testerOutput []byte) []byte { "Messages": {regexp.MustCompile(`✓ Messages: \["[A-Za-z !]{1,}"\]`)}, "Topic Name": {regexp.MustCompile(`✓ TopicResponse\[[0-9]{1,}\] Topic Name: [A-Za-z -]{3,}`)}, "Topic UUID": {regexp.MustCompile(`✓ TopicResponse\[[0-9]{1,}\] Topic UUID: [0-9 -]{1,}`)}, + "Record Value": {regexp.MustCompile(`✓ Record\[[0-9]{1,}\] Value: [A-Za-z0-9 !]{1,}`)}, + "RecordBatch BaseOffset": {regexp.MustCompile(`✓ RecordBatch\[[0-9]{1,}\] BaseOffset: [0-9]{1,}`)}, } for replacement, regexes := range replacements { From 3c92ab91e59780f90abfb58f61e3b1bfec8543d4 Mon Sep 17 00:00:00 2001 From: Ryan Gang Date: Thu, 17 Oct 2024 14:36:45 +0530 Subject: [PATCH 11/12] tests: update fixtures --- internal/test_helpers/fixtures/fetch/pass | 160 +++++++++++----------- 1 file changed, 80 insertions(+), 80 deletions(-) diff --git a/internal/test_helpers/fixtures/fetch/pass b/internal/test_helpers/fixtures/fetch/pass index 0cee0aa..c7c48f9 100644 --- a/internal/test_helpers/fixtures/fetch/pass +++ b/internal/test_helpers/fixtures/fetch/pass @@ -381,13 +381,13 @@ Debug = true [stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown [stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata [stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata -[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata -[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/partition.metadata +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/partition.metadata [stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata [stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log [stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log -[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log -[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/00000000000000000000.log +[stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/00000000000000000000.log [stage-5] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log [stage-5] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs [stage-5] Connecting to broker at: localhost:9092 @@ -404,7 +404,7 @@ Debug = true [stage-5] Hexdump of received "Fetch" response:  [stage-5] Idx | Hex | ASCII [stage-5] -----+-------------------------------------------------+----------------- -[stage-5] 0000 | 60 5a 05 cd 00 00 00 00 00 00 00 0f 32 04 12 01 | `Z..........2... +[stage-5] 0000 | 60 5a 05 cd 00 00 00 00 00 00 00 07 a5 ef 2e 01 | `Z.............. [stage-5] 0010 | 00 | . [stage-5]  [stage-5] [Decoder] - .ResponseHeader @@ -413,7 +413,7 @@ Debug = true [stage-5] [Decoder] - .ResponseBody [stage-5] [Decoder]  - .throttle_time_ms (0) [stage-5] [Decoder]  - .error_code (0) -[stage-5] [Decoder]  - .session_id (254936082) +[stage-5] [Decoder]  - .session_id (128315182) [stage-5] [Decoder]  - .num_responses (0) [stage-5] [Decoder]  - .TAG_BUFFER [stage-5] ✓ Correlation ID: 1616512461 @@ -432,13 +432,13 @@ Debug = true [stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown [stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata [stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata -[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata -[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/partition.metadata +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/partition.metadata [stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata [stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log [stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log -[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log -[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/00000000000000000000.log +[stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/00000000000000000000.log [stage-4] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log [stage-4] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs [stage-4] Connecting to broker at: localhost:9092 @@ -450,7 +450,7 @@ Debug = true [stage-4] 0000 | 00 00 00 60 00 01 00 10 05 c3 b0 2a 00 09 6b 61 | ...`.......*..ka [stage-4] 0010 | 66 6b 61 2d 63 6c 69 00 00 00 01 f4 00 00 00 01 | fka-cli......... [stage-4] 0020 | 03 20 00 00 00 00 00 00 00 00 00 00 00 02 00 00 | . .............. -[stage-4] 0030 | 00 00 00 00 00 00 00 00 00 00 00 00 11 09 02 00 | ................ +[stage-4] 0030 | 00 00 00 00 00 00 00 00 00 00 00 00 11 08 02 00 | ................ [stage-4] 0040 | 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 ff | ................ [stage-4] 0050 | ff ff ff ff ff ff ff ff ff ff ff 00 10 00 00 00 | ................ [stage-4] 0060 | 00 01 01 00 | .... @@ -458,8 +458,8 @@ Debug = true [stage-4] Hexdump of received "Fetch" response:  [stage-4] Idx | Hex | ASCII [stage-4] -----+-------------------------------------------------+----------------- -[stage-4] 0000 | 05 c3 b0 2a 00 00 00 00 00 00 00 08 61 5f ef 02 | ...*........a_.. -[stage-4] 0010 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 11 09 | ................ +[stage-4] 0000 | 05 c3 b0 2a 00 00 00 00 00 00 00 02 09 4b 77 02 | ...*.........Kw. +[stage-4] 0010 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 11 08 | ................ [stage-4] 0020 | 02 00 00 00 00 00 64 ff ff ff ff ff ff ff ff ff | ......d......... [stage-4] 0030 | ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff 01 | ................ [stage-4] 0040 | ff ff ff ff 01 00 00 00 | ........ @@ -470,10 +470,10 @@ Debug = true [stage-4] [Decoder] - .ResponseBody [stage-4] [Decoder]  - .throttle_time_ms (0) [stage-4] [Decoder]  - .error_code (0) -[stage-4] [Decoder]  - .session_id (140599279) +[stage-4] [Decoder]  - .session_id (34163575) [stage-4] [Decoder]  - .num_responses (1) [stage-4] [Decoder]  - .TopicResponse[0] -[stage-4] [Decoder]  - .topic_id (00000000-0000-0000-0000-000000001109) +[stage-4] [Decoder]  - .topic_id (00000000-0000-0000-0000-000000001108) [stage-4] [Decoder]  - .num_partitions (1) [stage-4] [Decoder]  - .PartitionResponse[0] [stage-4] [Decoder]  - .partition_index (0) @@ -490,7 +490,7 @@ Debug = true [stage-4] ✓ Correlation ID: 96710698 [stage-4] ✓ Throttle Time: 0 [stage-4] ✓ Error Code: 0 (NO_ERROR) -[stage-4]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-0000-0000-000000001109 +[stage-4]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-0000-0000-000000001108 [stage-4]  ✓ PartitionResponse[0] Error code: 100 (UNKNOWN_TOPIC_ID) [stage-4]  ✓ PartitionResponse[0] Partition Index: 0 [stage-4]  ✓ RecordBatches: [] @@ -506,13 +506,13 @@ Debug = true [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata -[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata -[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata +[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/partition.metadata +[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/partition.metadata [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log -[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log -[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log +[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/00000000000000000000.log +[stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/00000000000000000000.log [stage-3] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log [stage-3] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs [stage-3] Connecting to broker at: localhost:9092 @@ -524,7 +524,7 @@ Debug = true [stage-3] 0000 | 00 00 00 60 00 01 00 10 0f 2e 14 fa 00 09 6b 61 | ...`..........ka [stage-3] 0010 | 66 6b 61 2d 63 6c 69 00 00 00 01 f4 00 00 00 01 | fka-cli......... [stage-3] 0020 | 03 20 00 00 00 00 00 00 00 00 00 00 00 02 00 00 | . .............. -[stage-3] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 31 02 00 | ....@........1.. +[stage-3] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 61 02 00 | ....@........a.. [stage-3] 0040 | 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 ff | ................ [stage-3] 0050 | ff ff ff ff ff ff ff ff ff ff ff 00 10 00 00 00 | ................ [stage-3] 0060 | 00 01 01 00 | .... @@ -532,8 +532,8 @@ Debug = true [stage-3] Hexdump of received "Fetch" response:  [stage-3] Idx | Hex | ASCII [stage-3] -----+-------------------------------------------------+----------------- -[stage-3] 0000 | 0f 2e 14 fa 00 00 00 00 00 00 00 0e 3f 6d 78 02 | ............?mx. -[stage-3] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 31 | ......@........1 +[stage-3] 0000 | 0f 2e 14 fa 00 00 00 00 00 00 00 06 c7 4f bd 02 | .............O.. +[stage-3] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 61 | ......@........a [stage-3] 0020 | 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................ [stage-3] 0030 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................ [stage-3] 0040 | ff ff ff ff 01 00 00 00 | ........ @@ -544,10 +544,10 @@ Debug = true [stage-3] [Decoder] - .ResponseBody [stage-3] [Decoder]  - .throttle_time_ms (0) [stage-3] [Decoder]  - .error_code (0) -[stage-3] [Decoder]  - .session_id (239037816) +[stage-3] [Decoder]  - .session_id (113725373) [stage-3] [Decoder]  - .num_responses (1) [stage-3] [Decoder]  - .TopicResponse[0] -[stage-3] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000031) +[stage-3] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000061) [stage-3] [Decoder]  - .num_partitions (1) [stage-3] [Decoder]  - .PartitionResponse[0] [stage-3] [Decoder]  - .partition_index (0) @@ -564,7 +564,7 @@ Debug = true [stage-3] ✓ Correlation ID: 254678266 [stage-3] ✓ Throttle Time: 0 [stage-3] ✓ Error Code: 0 (NO_ERROR) -[stage-3]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000031 +[stage-3]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000061 [stage-3]  ✓ PartitionResponse[0] Error code: 0 (NO_ERROR) [stage-3]  ✓ PartitionResponse[0] Partition Index: 0 [stage-3]  ✓ RecordBatches: [] @@ -580,13 +580,13 @@ Debug = true [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata -[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata -[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata +[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/partition.metadata +[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/partition.metadata [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log -[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log -[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log +[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/00000000000000000000.log +[stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/00000000000000000000.log [stage-2] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log [stage-2] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs [stage-2] Connecting to broker at: localhost:9092 @@ -598,7 +598,7 @@ Debug = true [stage-2] 0000 | 00 00 00 60 00 01 00 10 70 d8 81 15 00 09 6b 61 | ...`....p.....ka [stage-2] 0010 | 66 6b 61 2d 63 6c 69 00 00 00 01 f4 00 00 00 01 | fka-cli......... [stage-2] 0020 | 03 20 00 00 00 00 00 00 00 00 00 00 00 02 00 00 | . .............. -[stage-2] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 32 02 00 | ....@........2.. +[stage-2] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 84 02 00 | ....@........... [stage-2] 0040 | 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 ff | ................ [stage-2] 0050 | ff ff ff ff ff ff ff ff ff ff ff 00 10 00 00 00 | ................ [stage-2] 0060 | 00 01 01 00 | .... @@ -606,16 +606,17 @@ Debug = true [stage-2] Hexdump of received "Fetch" response:  [stage-2] Idx | Hex | ASCII [stage-2] -----+-------------------------------------------------+----------------- -[stage-2] 0000 | 70 d8 81 15 00 00 00 00 00 00 00 0b 66 6c 3f 02 | p...........fl?. -[stage-2] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 32 | ......@........2 +[stage-2] 0000 | 70 d8 81 15 00 00 00 00 00 00 00 0a f4 fb c2 02 | p............... +[stage-2] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 84 | ......@......... [stage-2] 0020 | 02 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 | ................ [stage-2] 0030 | 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 | ................ -[stage-2] 0040 | ff ff ff ff 51 00 00 00 00 00 00 00 00 00 00 00 | ....Q........... -[stage-2] 0050 | 44 00 00 00 00 02 98 ec 18 d3 00 00 00 00 00 00 | D............... +[stage-2] 0040 | ff ff ff ff 5f 00 00 00 00 00 00 00 00 00 00 00 | ...._........... +[stage-2] 0050 | 52 00 00 00 00 02 8b aa 87 2a 00 00 00 00 00 00 | R........*...... [stage-2] 0060 | 00 00 01 91 e0 5b 6d 8b 00 00 01 91 e0 5b 6d 8b | .....[m......[m. [stage-2] 0070 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................ -[stage-2] 0080 | 00 01 24 00 00 00 01 18 48 65 6c 6c 6f 20 57 6f | ..$.....Hello Wo -[stage-2] 0090 | 72 6c 64 21 00 00 00 00 | rld!.... +[stage-2] 0080 | 00 01 40 00 00 00 01 34 48 65 6c 6c 6f 20 52 65 | ..@....4Hello Re +[stage-2] 0090 | 76 65 72 73 65 20 45 6e 67 69 6e 65 65 72 69 6e | verse Engineerin +[stage-2] 00a0 | 67 21 00 00 00 00 | g!.... [stage-2]  [stage-2] [Decoder] - .ResponseHeader [stage-2] [Decoder]  - .correlation_id (1893237013) @@ -623,10 +624,10 @@ Debug = true [stage-2] [Decoder] - .ResponseBody [stage-2] [Decoder]  - .throttle_time_ms (0) [stage-2] [Decoder]  - .error_code (0) -[stage-2] [Decoder]  - .session_id (191261759) +[stage-2] [Decoder]  - .session_id (183827394) [stage-2] [Decoder]  - .num_responses (1) [stage-2] [Decoder]  - .TopicResponse[0] -[stage-2] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000032) +[stage-2] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000084) [stage-2] [Decoder]  - .num_partitions (1) [stage-2] [Decoder]  - .PartitionResponse[0] [stage-2] [Decoder]  - .partition_index (0) @@ -636,13 +637,13 @@ Debug = true [stage-2] [Decoder]  - .log_start_offset (0) [stage-2] [Decoder]  - .num_aborted_transactions (0) [stage-2] [Decoder]  - .preferred_read_replica (-1) -[stage-2] [Decoder]  - .compact_records_length (80) +[stage-2] [Decoder]  - .compact_records_length (94) [stage-2] [Decoder]  - .RecordBatch[0] [stage-2] [Decoder]  - .base_offset (0) -[stage-2] [Decoder]  - .batch_length (68) +[stage-2] [Decoder]  - .batch_length (82) [stage-2] [Decoder]  - .partition_leader_epoch (0) [stage-2] [Decoder]  - .magic_byte (2) -[stage-2] [Decoder]  - .crc (-1729357613) +[stage-2] [Decoder]  - .crc (-1951758550) [stage-2] [Decoder]  - .record_attributes (0) [stage-2] [Decoder]  - .last_offset_delta (0) [stage-2] [Decoder]  - .base_timestamp (1726045973899) @@ -652,14 +653,14 @@ Debug = true [stage-2] [Decoder]  - .base_sequence (0) [stage-2] [Decoder]  - .num_records (1) [stage-2] [Decoder]  - .Record[0] -[stage-2] [Decoder]  - .length (18) +[stage-2] [Decoder]  - .length (32) [stage-2] [Decoder]  - .attributes (0) [stage-2] [Decoder]  - .timestamp_delta (0) [stage-2] [Decoder]  - .offset_delta (0) [stage-2] [Decoder]  - .key_length (-1) [stage-2] [Decoder]  - .key ("") -[stage-2] [Decoder]  - .value_length (12) -[stage-2] [Decoder]  - .value ("Hello World!") +[stage-2] [Decoder]  - .value_length (26) +[stage-2] [Decoder]  - .value ("Hello Reverse Engineering!") [stage-2] [Decoder]  - .num_headers (0) [stage-2] [Decoder]  - .TAG_BUFFER [stage-2] [Decoder]  - .TAG_BUFFER @@ -667,11 +668,11 @@ Debug = true [stage-2] ✓ Correlation ID: 1893237013 [stage-2] ✓ Throttle Time: 0 [stage-2] ✓ Error Code: 0 (NO_ERROR) -[stage-2]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000032 +[stage-2]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000084 [stage-2]  ✓ PartitionResponse[0] Error code: 0 (NO_ERROR) [stage-2]  ✓ PartitionResponse[0] Partition Index: 0 [stage-2]  ✓ RecordBatch[0] BaseOffset: 0 -[stage-2]  ✓ Record[0] Value: Hello World! +[stage-2]  ✓ Record[0] Value: Hello Reverse Engineering! [stage-2] ✓ RecordBatch bytes match with the contents on disk [stage-2] Test passed. [stage-2] Terminating program @@ -685,13 +686,13 @@ Debug = true [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/.kafka_cleanshutdown [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/partition.metadata [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/partition.metadata -[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/partition.metadata -[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/partition.metadata +[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/partition.metadata +[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/partition.metadata [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/partition.metadata [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/bar-0/00000000000000000000.log [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/baz-0/00000000000000000000.log -[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-0/00000000000000000000.log -[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/quz-1/00000000000000000000.log +[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-0/00000000000000000000.log +[stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/foo-1/00000000000000000000.log [stage-1] [Serializer]  - Wrote file to: /tmp/kraft-combined-logs/__cluster_metadata-0/00000000000000000000.log [stage-1] [Serializer] Finished writing log files to: /tmp/kraft-combined-logs [stage-1] Connecting to broker at: localhost:9092 @@ -703,7 +704,7 @@ Debug = true [stage-1] 0000 | 00 00 00 60 00 01 00 10 65 3c 54 a2 00 09 6b 61 | ...`....e Date: Thu, 24 Oct 2024 14:08:03 +0530 Subject: [PATCH 12/12] tests: update fixtures --- internal/test_helpers/fixtures/fetch/pass | 120 +++++++++++----------- 1 file changed, 60 insertions(+), 60 deletions(-) diff --git a/internal/test_helpers/fixtures/fetch/pass b/internal/test_helpers/fixtures/fetch/pass index c7c48f9..5180c89 100644 --- a/internal/test_helpers/fixtures/fetch/pass +++ b/internal/test_helpers/fixtures/fetch/pass @@ -404,7 +404,7 @@ Debug = true [stage-5] Hexdump of received "Fetch" response:  [stage-5] Idx | Hex | ASCII [stage-5] -----+-------------------------------------------------+----------------- -[stage-5] 0000 | 60 5a 05 cd 00 00 00 00 00 00 00 07 a5 ef 2e 01 | `Z.............. +[stage-5] 0000 | 60 5a 05 cd 00 00 00 00 00 00 00 0e ac d6 13 01 | `Z.............. [stage-5] 0010 | 00 | . [stage-5]  [stage-5] [Decoder] - .ResponseHeader @@ -413,7 +413,7 @@ Debug = true [stage-5] [Decoder] - .ResponseBody [stage-5] [Decoder]  - .throttle_time_ms (0) [stage-5] [Decoder]  - .error_code (0) -[stage-5] [Decoder]  - .session_id (128315182) +[stage-5] [Decoder]  - .session_id (246208019) [stage-5] [Decoder]  - .num_responses (0) [stage-5] [Decoder]  - .TAG_BUFFER [stage-5] ✓ Correlation ID: 1616512461 @@ -450,7 +450,7 @@ Debug = true [stage-4] 0000 | 00 00 00 60 00 01 00 10 05 c3 b0 2a 00 09 6b 61 | ...`.......*..ka [stage-4] 0010 | 66 6b 61 2d 63 6c 69 00 00 00 01 f4 00 00 00 01 | fka-cli......... [stage-4] 0020 | 03 20 00 00 00 00 00 00 00 00 00 00 00 02 00 00 | . .............. -[stage-4] 0030 | 00 00 00 00 00 00 00 00 00 00 00 00 11 08 02 00 | ................ +[stage-4] 0030 | 00 00 00 00 00 00 00 00 00 00 00 00 25 58 02 00 | ............%X.. [stage-4] 0040 | 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 ff | ................ [stage-4] 0050 | ff ff ff ff ff ff ff ff ff ff ff 00 10 00 00 00 | ................ [stage-4] 0060 | 00 01 01 00 | .... @@ -458,8 +458,8 @@ Debug = true [stage-4] Hexdump of received "Fetch" response:  [stage-4] Idx | Hex | ASCII [stage-4] -----+-------------------------------------------------+----------------- -[stage-4] 0000 | 05 c3 b0 2a 00 00 00 00 00 00 00 02 09 4b 77 02 | ...*.........Kw. -[stage-4] 0010 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 11 08 | ................ +[stage-4] 0000 | 05 c3 b0 2a 00 00 00 00 00 00 00 01 d3 9f 5d 02 | ...*..........]. +[stage-4] 0010 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 25 58 | ..............%X [stage-4] 0020 | 02 00 00 00 00 00 64 ff ff ff ff ff ff ff ff ff | ......d......... [stage-4] 0030 | ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff 01 | ................ [stage-4] 0040 | ff ff ff ff 01 00 00 00 | ........ @@ -470,10 +470,10 @@ Debug = true [stage-4] [Decoder] - .ResponseBody [stage-4] [Decoder]  - .throttle_time_ms (0) [stage-4] [Decoder]  - .error_code (0) -[stage-4] [Decoder]  - .session_id (34163575) +[stage-4] [Decoder]  - .session_id (30646109) [stage-4] [Decoder]  - .num_responses (1) [stage-4] [Decoder]  - .TopicResponse[0] -[stage-4] [Decoder]  - .topic_id (00000000-0000-0000-0000-000000001108) +[stage-4] [Decoder]  - .topic_id (00000000-0000-0000-0000-000000002558) [stage-4] [Decoder]  - .num_partitions (1) [stage-4] [Decoder]  - .PartitionResponse[0] [stage-4] [Decoder]  - .partition_index (0) @@ -490,7 +490,7 @@ Debug = true [stage-4] ✓ Correlation ID: 96710698 [stage-4] ✓ Throttle Time: 0 [stage-4] ✓ Error Code: 0 (NO_ERROR) -[stage-4]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-0000-0000-000000001108 +[stage-4]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-0000-0000-000000002558 [stage-4]  ✓ PartitionResponse[0] Error code: 100 (UNKNOWN_TOPIC_ID) [stage-4]  ✓ PartitionResponse[0] Partition Index: 0 [stage-4]  ✓ RecordBatches: [] @@ -524,7 +524,7 @@ Debug = true [stage-3] 0000 | 00 00 00 60 00 01 00 10 0f 2e 14 fa 00 09 6b 61 | ...`..........ka [stage-3] 0010 | 66 6b 61 2d 63 6c 69 00 00 00 01 f4 00 00 00 01 | fka-cli......... [stage-3] 0020 | 03 20 00 00 00 00 00 00 00 00 00 00 00 02 00 00 | . .............. -[stage-3] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 61 02 00 | ....@........a.. +[stage-3] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 44 02 00 | ....@........D.. [stage-3] 0040 | 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 ff | ................ [stage-3] 0050 | ff ff ff ff ff ff ff ff ff ff ff 00 10 00 00 00 | ................ [stage-3] 0060 | 00 01 01 00 | .... @@ -532,8 +532,8 @@ Debug = true [stage-3] Hexdump of received "Fetch" response:  [stage-3] Idx | Hex | ASCII [stage-3] -----+-------------------------------------------------+----------------- -[stage-3] 0000 | 0f 2e 14 fa 00 00 00 00 00 00 00 06 c7 4f bd 02 | .............O.. -[stage-3] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 61 | ......@........a +[stage-3] 0000 | 0f 2e 14 fa 00 00 00 00 00 00 00 04 43 50 5b 02 | ............CP[. +[stage-3] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 44 | ......@........D [stage-3] 0020 | 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................ [stage-3] 0030 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................ [stage-3] 0040 | ff ff ff ff 01 00 00 00 | ........ @@ -544,10 +544,10 @@ Debug = true [stage-3] [Decoder] - .ResponseBody [stage-3] [Decoder]  - .throttle_time_ms (0) [stage-3] [Decoder]  - .error_code (0) -[stage-3] [Decoder]  - .session_id (113725373) +[stage-3] [Decoder]  - .session_id (71520347) [stage-3] [Decoder]  - .num_responses (1) [stage-3] [Decoder]  - .TopicResponse[0] -[stage-3] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000061) +[stage-3] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000044) [stage-3] [Decoder]  - .num_partitions (1) [stage-3] [Decoder]  - .PartitionResponse[0] [stage-3] [Decoder]  - .partition_index (0) @@ -564,7 +564,7 @@ Debug = true [stage-3] ✓ Correlation ID: 254678266 [stage-3] ✓ Throttle Time: 0 [stage-3] ✓ Error Code: 0 (NO_ERROR) -[stage-3]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000061 +[stage-3]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000044 [stage-3]  ✓ PartitionResponse[0] Error code: 0 (NO_ERROR) [stage-3]  ✓ PartitionResponse[0] Partition Index: 0 [stage-3]  ✓ RecordBatches: [] @@ -598,7 +598,7 @@ Debug = true [stage-2] 0000 | 00 00 00 60 00 01 00 10 70 d8 81 15 00 09 6b 61 | ...`....p.....ka [stage-2] 0010 | 66 6b 61 2d 63 6c 69 00 00 00 01 f4 00 00 00 01 | fka-cli......... [stage-2] 0020 | 03 20 00 00 00 00 00 00 00 00 00 00 00 02 00 00 | . .............. -[stage-2] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 84 02 00 | ....@........... +[stage-2] 0030 | 00 00 00 00 40 00 80 00 00 00 00 00 00 30 02 00 | ....@........0.. [stage-2] 0040 | 00 00 00 ff ff ff ff 00 00 00 00 00 00 00 00 ff | ................ [stage-2] 0050 | ff ff ff ff ff ff ff ff ff ff ff 00 10 00 00 00 | ................ [stage-2] 0060 | 00 01 01 00 | .... @@ -606,17 +606,16 @@ Debug = true [stage-2] Hexdump of received "Fetch" response:  [stage-2] Idx | Hex | ASCII [stage-2] -----+-------------------------------------------------+----------------- -[stage-2] 0000 | 70 d8 81 15 00 00 00 00 00 00 00 0a f4 fb c2 02 | p............... -[stage-2] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 84 | ......@......... +[stage-2] 0000 | 70 d8 81 15 00 00 00 00 00 00 00 0f 0b 97 46 02 | p.............F. +[stage-2] 0010 | 00 00 00 00 00 00 40 00 80 00 00 00 00 00 00 30 | ......@........0 [stage-2] 0020 | 02 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 | ................ [stage-2] 0030 | 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 | ................ -[stage-2] 0040 | ff ff ff ff 5f 00 00 00 00 00 00 00 00 00 00 00 | ...._........... -[stage-2] 0050 | 52 00 00 00 00 02 8b aa 87 2a 00 00 00 00 00 00 | R........*...... +[stage-2] 0040 | ff ff ff ff 51 00 00 00 00 00 00 00 00 00 00 00 | ....Q........... +[stage-2] 0050 | 44 00 00 00 00 02 98 ec 18 d3 00 00 00 00 00 00 | D............... [stage-2] 0060 | 00 00 01 91 e0 5b 6d 8b 00 00 01 91 e0 5b 6d 8b | .....[m......[m. [stage-2] 0070 | 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 | ................ -[stage-2] 0080 | 00 01 40 00 00 00 01 34 48 65 6c 6c 6f 20 52 65 | ..@....4Hello Re -[stage-2] 0090 | 76 65 72 73 65 20 45 6e 67 69 6e 65 65 72 69 6e | verse Engineerin -[stage-2] 00a0 | 67 21 00 00 00 00 | g!.... +[stage-2] 0080 | 00 01 24 00 00 00 01 18 48 65 6c 6c 6f 20 57 6f | ..$.....Hello Wo +[stage-2] 0090 | 72 6c 64 21 00 00 00 00 | rld!.... [stage-2]  [stage-2] [Decoder] - .ResponseHeader [stage-2] [Decoder]  - .correlation_id (1893237013) @@ -624,10 +623,10 @@ Debug = true [stage-2] [Decoder] - .ResponseBody [stage-2] [Decoder]  - .throttle_time_ms (0) [stage-2] [Decoder]  - .error_code (0) -[stage-2] [Decoder]  - .session_id (183827394) +[stage-2] [Decoder]  - .session_id (252417862) [stage-2] [Decoder]  - .num_responses (1) [stage-2] [Decoder]  - .TopicResponse[0] -[stage-2] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000084) +[stage-2] [Decoder]  - .topic_id (00000000-0000-4000-8000-000000000030) [stage-2] [Decoder]  - .num_partitions (1) [stage-2] [Decoder]  - .PartitionResponse[0] [stage-2] [Decoder]  - .partition_index (0) @@ -637,13 +636,13 @@ Debug = true [stage-2] [Decoder]  - .log_start_offset (0) [stage-2] [Decoder]  - .num_aborted_transactions (0) [stage-2] [Decoder]  - .preferred_read_replica (-1) -[stage-2] [Decoder]  - .compact_records_length (94) +[stage-2] [Decoder]  - .compact_records_length (80) [stage-2] [Decoder]  - .RecordBatch[0] [stage-2] [Decoder]  - .base_offset (0) -[stage-2] [Decoder]  - .batch_length (82) +[stage-2] [Decoder]  - .batch_length (68) [stage-2] [Decoder]  - .partition_leader_epoch (0) [stage-2] [Decoder]  - .magic_byte (2) -[stage-2] [Decoder]  - .crc (-1951758550) +[stage-2] [Decoder]  - .crc (-1729357613) [stage-2] [Decoder]  - .record_attributes (0) [stage-2] [Decoder]  - .last_offset_delta (0) [stage-2] [Decoder]  - .base_timestamp (1726045973899) @@ -653,14 +652,14 @@ Debug = true [stage-2] [Decoder]  - .base_sequence (0) [stage-2] [Decoder]  - .num_records (1) [stage-2] [Decoder]  - .Record[0] -[stage-2] [Decoder]  - .length (32) +[stage-2] [Decoder]  - .length (18) [stage-2] [Decoder]  - .attributes (0) [stage-2] [Decoder]  - .timestamp_delta (0) [stage-2] [Decoder]  - .offset_delta (0) [stage-2] [Decoder]  - .key_length (-1) [stage-2] [Decoder]  - .key ("") -[stage-2] [Decoder]  - .value_length (26) -[stage-2] [Decoder]  - .value ("Hello Reverse Engineering!") +[stage-2] [Decoder]  - .value_length (12) +[stage-2] [Decoder]  - .value ("Hello World!") [stage-2] [Decoder]  - .num_headers (0) [stage-2] [Decoder]  - .TAG_BUFFER [stage-2] [Decoder]  - .TAG_BUFFER @@ -668,11 +667,11 @@ Debug = true [stage-2] ✓ Correlation ID: 1893237013 [stage-2] ✓ Throttle Time: 0 [stage-2] ✓ Error Code: 0 (NO_ERROR) -[stage-2]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000084 +[stage-2]  ✓ TopicResponse[0] Topic UUID: 00000000-0000-4000-8000-000000000030 [stage-2]  ✓ PartitionResponse[0] Error code: 0 (NO_ERROR) [stage-2]  ✓ PartitionResponse[0] Partition Index: 0 [stage-2]  ✓ RecordBatch[0] BaseOffset: 0 -[stage-2]  ✓ Record[0] Value: Hello Reverse Engineering! +[stage-2]  ✓ Record[0] Value: Hello World! [stage-2] ✓ RecordBatch bytes match with the contents on disk [stage-2] Test passed. [stage-2] Terminating program @@ -704,7 +703,7 @@ Debug = true [stage-1] 0000 | 00 00 00 60 00 01 00 10 65 3c 54 a2 00 09 6b 61 | ...`....e