booblik
Wiki

clients/dotnet/Booblik.Conformance

Generated page

Model gemma-mtp, commit ef58254ca7be, 2026-08-16, sources: 2. Edit the code or the hand-written documentation instead.

Diagram

Conformance Verbs

The command-line interface and supported operations for testing the broker. The program accepts a verb as the first argument args[0] and uses a switch statement to dispatch to specific logic Program.cs:38-59. Supported verbs include capabilities, metadata, produce, produce-keyed, and fetch.

More: Conformance Verbs

Metadata Retrieval

Fetching partition information, log start offsets, and high watermarks. The Metadata function calls connection.MetadataAsync to retrieve information for a specific topic Program.cs:97-109. For each partition found, it outputs the partition ID, the LogStartOffset, and the HighWatermark Program.cs:107.

More: Metadata Retrieval

Produce Operations

Sending records with different AckPolicy settings and keyed partitioning logic.

Ack PolicyMapping
noneAckPolicy.None
writtenAckPolicy.Written
forcedAckPolicy.Forced

The Produce function handles hex-encoded payloads and different acknowledgment requirements Program.cs:111-139. Additionally, ProduceKeyed exercises the partitioner by using topic.PartitionFor(key) to determine the destination partition before sending the record Program.cs:143-158.

Fetch Operations

Retrieving records and handling edge cases like truncated tails and maxBytes limits. The Fetch function retrieves records via connection.FetchAsync and reports the HighWatermark Program.cs:72-81. It specifically handles cases where a response is truncated because a record exceeds the maxBytes limit, reporting recordExceedsMaxBytes Program.cs:85-89.

Broker Refusal Handling

How the client reports BrokerException results via stdout without exiting with error. When a BrokerException is caught, the program prints error={refusal.Code.WireName()} to stdout and exits with code 0, as a refusal is considered a valid result rather than a program failure Program.cs:61-65.

Key files

FileLinesWhat is there
…/Booblik.Conformance/Booblik.Conformance.csproj1-21Project configuration for a .NET 8.0 console application.
…/Booblik.Conformance/Program.cs1-158The main entry point containing the conformance test logic and verbs.

Behaviour that surprise

  • A BrokerException is caught and reported as a successful execution (exit code 0) with an error=CODE message on stdout rather than a process failure Program.cs:61-65.
  • In ProduceKeyed, the client performs the partitioning logic itself using topic.PartitionFor(key) because the broker does not receive the key Program.cs:141-152.
  • When Fetch encounters a truncated record due to size limits, it reports recordExceedsMaxBytes instead of simply returning an empty list Program.cs:85-89.

On this page