AutoMQ provides full Apache Kafka protocol compatibility for scalable, cloud-native messaging. This guide covers recommended client SDKs for various languages to ensure optimal performance and stability.
AutoMQ is fully compatible with the Apache Kafka protocol, allowing you to connect and exchange messages using standard Kafka client SDKs. This guide outlines the recommended clients for various programming languages and highlights important considerations for their use with AutoMQ.
Compatibility Notes
AutoMQ is compatible with the Apache Kafka protocol, supporting clients from Kafka versions 0.10 to 3.9. This compatibility ensures that any standard Kafka client for these versions can connect to AutoMQ without modification.
We strongly recommend using the latest stable version of your chosen client SDK to leverage recent performance enhancements, features, and critical bug fixes.
Recommended Client SDK List
The Apache Kafka community maintains a list of client SDKs for various programming languages, which you can find in the official documentation. Based on extensive testing and production use, we recommend the following clients for optimal performance and stability with AutoMQ. To help you get started, we provide code samples for each recommended client in our AutoMQ Labs repository.
If the SDK you are using is not among the recommended ones listed above, as long as it is compatible with the Apache Kafka protocol, you can continue to access AutoMQ. We suggest reviewing the known issues list below and adjusting parameters accordingly.
Client Parameter Tuning
When using the SDK to send and receive messages, in addition to selecting the recommended SDK version, you need to tune the key parameters of the Producer to achieve optimal performance. Below are the recommended Producer configurations for each SDK and Kafka Output.
Apache Kafka Java Client > 2.1
# https://kafka.apache.org/documentation/#producerconfigs# Batch size, up to 1MiB of data can be accumulated at a time.batch.size=1048576# Batch linger time. If the batch limit is not reached within this time, sending is triggered anyway. This represents the maximum send delay.linger.ms=1000
Apache Kafka Java Client <= 2.1
# https://kafka.apache.org/21/documentation.html#producerconfigs# Maximum retry countretries=2147483647# Initial backoff delay timeretry.backoff.ms=100# Maximum backoff delay timeretry.backoff.max.ms=1000# RPC timeout for each send requestrequest.timeout.ms=30000# Total timeout for the entire send call. No further retries after this time; an exception is returned to the caller.delivery.timeout.ms=120000# Batch size, up to 1MiB of data can be accumulated at a time.batch.size=1048576# Batch linger time. If the batch limit is not reached within this time, sending is triggered anyway. This represents the maximum send delay.linger.ms=1000
franz-go
package mainimport ( "time" "github.com/twmb/franz-go/pkg/kgo")func main() { client, err := kgo.NewClient( kgo.SeedBrokers("localhost:9092"), // Equivalent to the linger.ms configuration in the Java client, set to 1 second. kgo.ProducerLinger(1*time.Second), ) if err != nil { panic(err) } defer client.Close()}
kafka-go
// https://pkg.go.dev/github.com/segmentio/kafka-go#Writer// Configure kafka.Writer fields; values align with Apache Kafka Java producer defaults.writer := &kafka.Writer{ // Maximum number of attempts to deliver a message. // Aligned with the Apache Kafka Java Client retries parameter (Integer.MAX_VALUE). MaxAttempts: 2147483647, // Maximum number of messages to trigger a flush. BatchSize: 4096, // Number of acknowledges from partition replicas required before responding. RequiredAcks: kafka.RequireAll,}
Sarama
package mainimport ( "time" "github.com/IBM/sarama")func main() { // https://pkg.go.dev/github.com/IBM/sarama#Config config := sarama.NewConfig() // Byte threshold to trigger a flush. config.Producer.Flush.Bytes = 1048576 // Message count threshold to trigger a flush. config.Producer.Flush.Messages = 4096 // Maximum flush wait time, equivalent to the Kafka Java producer's linger.ms. config.Producer.Flush.Frequency = 1 * time.Second // Maximum retry count (default 3), equivalent to the Kafka Java producer's retries. config.Producer.Retry.Max = 2147483647 // Backoff wait time between retries (default 100ms), equivalent to the Kafka Java producer's retry.backoff.ms. config.Producer.Retry.Backoff = 1 * time.Second // TODO: use config to create a producer, e.g. sarama.NewSyncProducer(brokers, config) _ = config}
Logstash Kafka Output
# https://www.elastic.co/docs/reference/logstash/plugins/plugins-outputs-kafkaoutput { kafka { # other connection configs ... # Batch size in bytes, up to 1MiB of data can be accumulated at a time. batch_size => 1048576 # Batch linger time in ms. If the batch limit is not reached within this time, sending is triggered anyway. linger_ms => 1000 # The number of acknowledgments the producer requires the leader to have received. acks => "all" # Compression type for all data generated by the producer. compression_type => "lz4" # The amount of time to wait before attempting to retry a failed produce request. retry_backoff_ms => 1000 }}
Filebeat Kafka Output
# https://www.elastic.co/docs/reference/beats/filebeat/kafka-output# Retry backoff wait time during leader elections.retry.backoff: 3s# Wait time before sending bulk Kafka requests.bulk_flush_frequency: 1s
Fluentd Kafka Output
# https://github.com/fluent/fluent-plugin-kafka<match **> @type kafka2 # other connection configs ... <buffer> # use default configs </buffer></match>
Fluent Bit Kafka Output
# https://docs.fluentbit.io/manual/pipeline/outputs/kafkapipeline: outputs: - name: kafka match: '*' # other connection configs ... # Batch linger time in ms. rdkafka.queue.buffering.max.ms: 1000 # Compression type. rdkafka.compression.type: lz4
Vector Kafka Sink
# https://vector.dev/docs/reference/configuration/sinks/kafka/[sinks.my_kafka]type = "kafka"inputs = ["my-source-or-transform-id"]# other connection configs ...# Compression type for all data generated by the producer.compression = "lz4"# Batch linger time is controlled via librdkafka options.[sinks.my_kafka.librdkafka_options]"queue.buffering.max.ms" = "1000"
Phenomenon: When using async_producer to send messages and the corresponding Topic undergoes partition reassignment, the Producer’s memory usage can increase abnormally, potentially leading to OOM.
Cause: When async_producer receives server-side retryable errors (like NOT_LEADER_OR_FOLLOWER due to partition reassignment), it temporarily stores the messages in memory and retries according to the policy. However, this retry cache has no size limit, and if substantial and continuous retries occur, memory usage may unexpectedly increase.
Consumers Unable to Identify Group Coordinator Changes
Defect Version: V0.4.47
Issue: After partition reassignment of the __consumer_offsets topic, some groups experience consumption interruptions, with errors logged.
Cause: When the __consumer_offsets partitions are reassigned, the coordinator for some groups changes. Kafka-go does not correctly handle this situation, as it continues to send requests to the old coordinator following a change, resulting in NOT_COORDINATOR errors.
Temporarily restart the Consumer to recover.
Switch SDKs, and it is recommended to use the Franz-Go SDK as per the recommended versions in this document.
Issue: When the Consumer’s configured heartbeatInterval is too close to sessionTimeout, the Consumer may periodically Leave & Rejoin the Group (though it generally does not affect consumption), logging errors.
Cause: In kafkajs, the configuration of heartbeatInterval only guarantees the “minimum interval between two heartbeats.” This means that in certain scenarios (e.g., the Consumer reaches the end of the topic with no new messages to consume), the interval between the Consumer sending heartbeats to the Coordinator may exceed the heartbeatInterval; if set too large, it may exceed sessionTimeout, causing the Coordinator to evict the Consumer.
Lower the heartbeatInterval or increase the sessionTimeout (it is advised that heartbeat.interval.ms should not exceed 1/3 of session.timeout.ms).
Was this page helpful?
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"AutoMQ Documentation","colors":{"primary":"#2449D4","light":"#2449D4","dark":"#2449D4"},"logo":{"light":"https://mintcdn.com/automq/s9vNxeyMGZ1r1DRV/logo/automq-black.svg?fit=max\u0026auto=format\u0026n=s9vNxeyMGZ1r1DRV\u0026q=85\u0026s=bcc93ae74a4143ae2b7602497b7b354b","dark":"https://mintcdn.com/automq/s9vNxeyMGZ1r1DRV/logo/automq-white.svg?fit=max\u0026auto=format\u0026n=s9vNxeyMGZ1r1DRV\u0026q=85\u0026s=209c336f52b4021f2e991e10d07613ae"},"favicon":"https://mintcdn.com/automq/s9vNxeyMGZ1r1DRV/logo/favicon.svg?fit=max\u0026auto=format\u0026n=s9vNxeyMGZ1r1DRV\u0026q=85\u0026s=d736b0934a674250c9dbe95a5f642fb9","appearance":{"default":"light","strict":true},"navbar":{"links":[{"icon":"github","href":"https://github.com/automq/automq","label":"Github"}],"primary":{"type":"button","label":"automq.com","href":"https://www.automq.com"}},"footer":{"socials":{"slack":"https://go.automq.com/slack","telegram":"https://t.me/+VgqhN9wqBGIzYmU1","x":"https://x.com/AutoMQ_Lab","github":"https://github.com/automq/automq","linkedin":"https://linkedin.com/company/automq"}},"icons":{"library":"lucide"},"integrations":{"ga4":{"measurementId":"G-4F3BX9DFG9"}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"styling":{"latex":true},"navigation":{"global":{"anchors":[{"anchor":"Github","icon":"github","href":"https://github.com/automq/automq"},{"anchor":"Slack","icon":"slack","href":"https://go.automq.com/slack"},{"anchor":"Telegram","icon":"Telegram","href":"https://t.me/+VgqhN9wqBGIzYmU1"},{"anchor":"Blog","icon":"newspaper","href":"https://www.automq.com/blog"}]},"languages":[{"language":"en","href":""},{"language":"cn","href":"zh/automq/what-is-automq/overview"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"automq","hasAudioNarration":false,"actualSubdomain":"automq","customDomains":["docs.automq.com"],"gitSource":{"type":"github","owner":"automq","repo":"sitebox","deployBranch":"main","contentDirectory":"docs","isPrivate":true,"mountPath":"","label":"","_id":"6b10bb6d9ffae5051c402d30"},"feedback":{"thumbs":true,"edits":false,"issues":false},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6b128081fcf853516559502d","clientVersion":"0.0.4453","searchFilterCounts":[{"language":"cn","tag":"AutoMQ BYOC","count":127},{"language":"en","tag":"AutoMQ BYOC","count":116},{"language":"en","tag":"AutoMQ Open Source","count":61},{"language":"cn","tag":"AutoMQ Open Source","count":57},{"language":"en","tag":"Kafka Connect","count":48},{"language":"cn","tag":"Kafka Connect","count":48},{"language":"en","tag":"Sink Connectors","count":26},{"language":"cn","tag":"Sink Connectors","count":26},{"language":"en","tag":"Source Connectors","count":19},{"language":"cn","tag":"Source Connectors","count":19},{"language":"cn","tag":"快速开始","count":16},{"language":"en","tag":"Integrations","count":14},{"language":"en","tag":"Getting Started","count":12},{"language":"cn","tag":"生态集成","count":12},{"language":"en","tag":"Architecture","count":11},{"language":"cn","tag":"管理环境","count":11},{"language":"cn","tag":"技术架构","count":11},{"language":"cn","tag":"安装 BYOC 环境","count":9},{"language":"en","tag":"Appendix","count":8},{"language":"en","tag":"Eliminate Inter-Zone Traffics","count":8}]},"assistantConfig":{"deflection":{"enabled":true,"email":"support@automq.com"}},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"auth-vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"starterQuestions":[],"googleFontsInlined":false},"customCss":[{"filePath":"static/style.css","content":"#content-area{word-break:keep-all;white-space:normal;overflow-wrap:normal}header div:nth-child(2) p{display:none}.emphasize-placeholder{background-color:#e0f2ff;border:1px solid #2d64eb;padding:2px 6px;border-radius:4px;font-family:monospace;cursor:pointer;display:inline-flex;align-items:center}.emoji-flip{display:inline-block;transform:scaleX(-1);font-size:0.8em;margin-left:4px}"}]}
{"page":{"pagePath":"automq-cloud/getting-started/client-sdk-guide","slug":"/automq-cloud/getting-started/client-sdk-guide","pageMetadata":{"title":"Client SDK Guide","description":"AutoMQ provides full Apache Kafka protocol compatibility for scalable, cloud-native messaging. This guide covers recommended client SDKs for various languages to ensure optimal performance and stability.","href":"/automq-cloud/getting-started/client-sdk-guide"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"AutoMQ provides full Apache Kafka protocol compatibility for scalable, cloud-native messaging. This guide covers recommended client SDKs for various languages to ensure optimal performance and stability.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{CodeBlock,Heading,Table,Tip}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Tip)_missingMdxReference(`Tip`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`AutoMQ is fully compatible with the Apache Kafka protocol, allowing you to connect and exchange messages using standard Kafka client SDKs. This guide outlines the recommended clients for various programming languages and highlights important considerations for their use with AutoMQ.`}),`\n`,_jsx(Heading,{level:`2`,id:`compatibility-notes`,children:`Compatibility Notes`}),`\n`,_jsx(_components.p,{children:`AutoMQ is compatible with the Apache Kafka protocol, supporting clients from Kafka versions 0.10 to 3.9. This compatibility ensures that any standard Kafka client for these versions can connect to AutoMQ without modification.`}),`\n`,_jsx(Tip,{children:_jsx(_components.p,{children:`We strongly recommend using the latest stable version of your chosen client SDK to leverage recent performance enhancements, features, and critical bug fixes.`})}),`\n`,_jsx(Heading,{level:`2`,id:`recommended-client-sdk-list`,children:`Recommended Client SDK List`}),`\n`,_jsxs(_components.p,{children:[`The Apache Kafka community maintains a list of client SDKs for various programming languages, which you can find in the `,_jsx(_components.a,{href:`https://cwiki.apache.org/confluence/display/KAFKA/Clients`,children:`official documentation`}),`. Based on extensive testing and production use, we recommend the following clients for optimal performance and stability with AutoMQ. To help you get started, we provide code samples for each recommended client in our `,_jsx(_components.a,{href:`https://github.com/AutoMQ/automq-labs`,children:`AutoMQ Labs`}),` repository.`]}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Programming Language`}),_jsx(`br`,{})]}),_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Client SDK`}),_jsx(`br`,{})]}),_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Recommended Version`}),_jsx(`br`,{})]}),_jsxs(_components.th,{children:[`Sample`,_jsx(`br`,{})]})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Java`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://github.com/apache/kafka`,children:`Apache Kafka Java Client`}),_jsx(`br`,{})]}),_jsxs(_components.td,{children:[`>= 3.2.0`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://github.com/AutoMQ/automq-labs/tree/main/opensource-examples/clients/java`,children:`Demo`}),_jsx(`br`,{})]})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`C/C++`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://github.com/edenhill/librdkafka`,children:`librdkafka`}),_jsx(`br`,{})]}),_jsxs(_components.td,{children:[`>= 2.8.0`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://github.com/AutoMQ/automq-labs/tree/main/opensource-examples/clients/cpp`,children:`Demo`}),_jsx(`br`,{})]})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Go`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://github.com/twmb/franz-go`,children:`franz-go`}),_jsx(`br`,{})]}),_jsxs(_components.td,{children:[`>= 1.17.1`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://github.com/AutoMQ/automq-labs/tree/main/opensource-examples/clients/go`,children:`Demo`}),_jsx(`br`,{})]})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Python`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://pypi.org/project/kafka-python/`,children:`kafka-python`}),_jsx(`br`,{})]}),_jsxs(_components.td,{children:[`>= 2.2.3`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://github.com/AutoMQ/automq-labs/tree/main/opensource-examples/clients/python`,children:`Demo`}),_jsx(`br`,{})]})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`NodeJS`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://kafka.js.org/`,children:`KafkaJS`}),_jsx(`br`,{})]}),_jsxs(_components.td,{children:[`>= 2.2.4`,_jsx(`br`,{})]}),_jsxs(_components.td,{children:[_jsx(_components.a,{href:`https://github.com/AutoMQ/automq-labs/tree/main/opensource-examples/clients/javascript`,children:`Demo`}),_jsx(`br`,{})]})]})]})]}),`\n`,_jsx(Tip,{children:_jsx(_components.p,{children:`If the SDK you are using is not among the recommended ones listed above, as long as it is compatible with the Apache Kafka protocol, you can continue to access AutoMQ. We suggest reviewing the known issues list below and adjusting parameters accordingly.`})}),`\n`,_jsx(Heading,{level:`2`,id:`client-parameter-tuning`,children:`Client Parameter Tuning`}),`\n`,_jsx(_components.p,{children:`When using the SDK to send and receive messages, in addition to selecting the recommended SDK version, you need to tune the key parameters of the Producer to achieve optimal performance. Below are the recommended Producer configurations for each SDK and Kafka Output.`}),`\n`,_jsx(Heading,{level:`3`,id:`apache-kafka-java-client->-2-1`,children:`Apache Kafka Java Client > 2.1`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`ini`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`ini`,children:_jsxs(_components.code,{language:`ini`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# https://kafka.apache.org/documentation/#producerconfigs`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Batch size, up to 1MiB of data can be accumulated at a time.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`batch.size`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`=1048576`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Batch linger time. If the batch limit is not reached within this time, sending is triggered anyway. This represents the maximum send delay.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`linger.ms`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`=1000`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`apache-kafka-java-client-\u003c=-2-1`,children:`Apache Kafka Java Client \u003c= 2.1`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`16`,language:`ini`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`ini`,children:_jsxs(_components.code,{language:`ini`,numberOfLines:`16`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# https://kafka.apache.org/21/documentation.html#producerconfigs`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Maximum retry count`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`retries`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`=2147483647`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Initial backoff delay time`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`retry.backoff.ms`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`=100`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Maximum backoff delay time`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`retry.backoff.max.ms`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`=1000`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# RPC timeout for each send request`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`request.timeout.ms`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`=30000`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Total timeout for the entire send call. No further retries after this time; an exception is returned to the caller.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`delivery.timeout.ms`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`=120000`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Batch size, up to 1MiB of data can be accumulated at a time.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`batch.size`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`=1048576`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Batch linger time. If the batch limit is not reached within this time, sending is triggered anyway. This represents the maximum send delay.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`linger.ms`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`=1000`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`franz-go`,children:`franz-go`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`19`,language:`go`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`go`,children:_jsxs(_components.code,{language:`go`,numberOfLines:`19`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`package`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` main`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\t\"`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#CE9178`},children:`time`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\t\"`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#CE9178`},children:`github.com/twmb/franz-go/pkg/kgo`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`func`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` main`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`() {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tclient`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` kgo`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`NewClient`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\t\tkgo`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`SeedBrokers`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"localhost:9092\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`),`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t\t// Equivalent to the linger.ms configuration in the Java client, set to 1 second.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\t\tkgo`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`ProducerLinger`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`1`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`*`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`time`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Second`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`),`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`\t)`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`\tif`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` err`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` !=`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` nil`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`\t\tpanic`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`err`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`\t}`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`\tdefer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`Close`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`()`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`kafka-go`,children:`kafka-go`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`11`,language:`go`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`go`,children:_jsxs(_components.code,{language:`go`,numberOfLines:`11`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// https://pkg.go.dev/github.com/segmentio/kafka-go#Writer`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Configure kafka.Writer fields; values align with Apache Kafka Java producer defaults.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`writer`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u0026`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`kafka`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`Writer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// Maximum number of attempts to deliver a message.`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// Aligned with the Apache Kafka Java Client retries parameter (Integer.MAX_VALUE).`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tMaxAttempts`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`2147483647`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// Maximum number of messages to trigger a flush.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tBatchSize`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`4096`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// Number of acknowledges from partition replicas required before responding.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tRequiredAcks`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`kafka`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`RequireAll`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`sarama`,children:`Sarama`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`27`,language:`go`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`go`,children:_jsxs(_components.code,{language:`go`,numberOfLines:`27`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`package`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:` main`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\t\"`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#CE9178`},children:`time`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\t\"`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#CE9178`},children:`github.com/IBM/sarama`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`func`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` main`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`() {`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// https://pkg.go.dev/github.com/IBM/sarama#Config`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tconfig`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` sarama`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`NewConfig`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`()`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// Byte threshold to trigger a flush.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tconfig`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Producer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Flush`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Bytes`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 1048576`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// Message count threshold to trigger a flush.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tconfig`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Producer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Flush`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Messages`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 4096`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// Maximum flush wait time, equivalent to the Kafka Java producer's linger.ms.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tconfig`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Producer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Flush`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Frequency`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 1`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` *`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` time`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Second`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// Maximum retry count (default 3), equivalent to the Kafka Java producer's retries.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tconfig`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Producer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Retry`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Max`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 2147483647`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// Backoff wait time between retries (default 100ms), equivalent to the Kafka Java producer's retry.backoff.ms.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\tconfig`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Producer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Retry`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Backoff`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 1`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` *`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` time`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Second`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`\t// TODO: use config to create a producer, e.g. sarama.NewSyncProducer(brokers, config)`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\t_`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` config`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`logstash-kafka-output`,children:`Logstash Kafka Output`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`16`,language:`ruby`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`ruby`,children:_jsxs(_components.code,{language:`ruby`,numberOfLines:`16`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# https://www.elastic.co/docs/reference/logstash/plugins/plugins-outputs-kafka`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`output {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` kafka {`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # other connection configs ...`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # Batch size in bytes, up to 1MiB of data can be accumulated at a time.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` batch_size => `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`1048576`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # Batch linger time in ms. If the batch limit is not reached within this time, sending is triggered anyway.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` linger_ms => `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`1000`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # The number of acknowledgments the producer requires the leader to have received.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` acks => `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"all\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # Compression type for all data generated by the producer.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` compression_type => `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"lz4\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # The amount of time to wait before attempting to retry a failed produce request.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` retry_backoff_ms => `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`1000`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`filebeat-kafka-output`,children:`Filebeat Kafka Output`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`yaml`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`yaml`,children:_jsxs(_components.code,{language:`yaml`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# https://www.elastic.co/docs/reference/beats/filebeat/kafka-output`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Retry backoff wait time during leader elections.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`retry.backoff`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`3s`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Wait time before sending bulk Kafka requests.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`bulk_flush_frequency`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`1s`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`fluentd-kafka-output`,children:`Fluentd Kafka Output`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`9`,language:`xml`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`xml`,children:_jsxs(_components.code,{language:`xml`,numberOfLines:`9`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`# https://github.com/fluent/fluent-plugin-kafka`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#808080`},children:`\u003c`}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`match`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` **`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#808080`},children:`>`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` @type kafka2`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` # other connection configs ...`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#808080`},children:` \u003c`}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`buffer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#808080`},children:`>`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` # use default configs`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#808080`},children:` \u003c/`}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`buffer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#808080`},children:`>`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#808080`},children:`\u003c/`}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`match`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#808080`},children:`>`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`fluent-bit-kafka-output`,children:`Fluent Bit Kafka Output`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`10`,language:`yaml`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`yaml`,children:_jsxs(_components.code,{language:`yaml`,numberOfLines:`10`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# https://docs.fluentbit.io/manual/pipeline/outputs/kafka`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`pipeline`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`:`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:` outputs`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`:`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` - `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:`name`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`kafka`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:` match`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'*'`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # other connection configs ...`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # Batch linger time in ms.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:` rdkafka.queue.buffering.max.ms`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`1000`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # Compression type.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#569CD6`},children:` rdkafka.compression.type`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`lz4`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`vector-kafka-sink`,children:`Vector Kafka Sink`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`11`,language:`toml`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`toml`,children:_jsxs(_components.code,{language:`toml`,numberOfLines:`11`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# https://vector.dev/docs/reference/configuration/sinks/kafka/`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`[`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#D4D4D4`},children:`sinks`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#D4D4D4`},children:`my_kafka`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` = `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"kafka\"`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`inputs`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` = [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"my-source-or-transform-id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# other connection configs ...`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Compression type for all data generated by the producer.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`compression`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` = `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"lz4\"`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Batch linger time is controlled via librdkafka options.`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`[`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#D4D4D4`},children:`sinks`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#D4D4D4`},children:`my_kafka`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#D4D4D4`},children:`librdkafka_options`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`queue.buffering.max.ms`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` = `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"1000\"`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`appendix-other-known-issues`,children:`Appendix: Other Known Issues`}),`\n`,_jsx(Heading,{level:`3`,id:`sarama-go-sdk`,children:_jsx(_components.a,{href:`https://github.com/IBM/sarama`,children:`Sarama Go SDK`})}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Known Defects`}),_jsx(`br`,{})]}),_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Defect Information`}),_jsx(`br`,{})]}),_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Resolution Methods`}),_jsx(`br`,{})]})]})}),_jsx(_components.tbody,{children:_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Async Producer has no memory usage limit during send retries`,_jsx(`br`,{})]}),_jsx(_components.td,{children:_jsxs(`ul`,{children:[_jsx(`li`,{children:`Defect Version: V1.43.3`}),_jsxs(`li`,{children:[`Community Issue: `,_jsx(_components.a,{href:`https://github.com/IBM/sarama/issues/1358`,children:`https://github.com/IBM/sarama/issues/1358`})]}),_jsxs(`li`,{children:[`Community PR: `,_jsx(_components.a,{href:`https://github.com/IBM/sarama/pull/3026`,children:`https://github.com/IBM/sarama/pull/3026`})]}),_jsx(`li`,{children:`Phenomenon: When using async_producer to send messages and the corresponding Topic undergoes partition reassignment, the Producer’s memory usage can increase abnormally, potentially leading to OOM.`}),_jsx(`li`,{children:`Cause: When async_producer receives server-side retryable errors (like NOT_LEADER_OR_FOLLOWER due to partition reassignment), it temporarily stores the messages in memory and retries according to the policy. However, this retry cache has no size limit, and if substantial and continuous retries occur, memory usage may unexpectedly increase.`})]})}),_jsx(_components.td,{children:_jsx(`ul`,{children:_jsx(`li`,{children:`Upgrade to version >= V1.44.0`})})})]})})]}),`\n`,_jsx(Heading,{level:`3`,id:`kafka-go-sdk`,children:_jsx(_components.a,{href:`https://github.com/segmentio/kafka-go`,children:`Kafka-Go SDK`})}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Known Defects`}),_jsx(`br`,{})]}),_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Defect Information`}),_jsx(`br`,{})]}),_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Resolution Methods`}),_jsx(`br`,{})]})]})}),_jsx(_components.tbody,{children:_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Consumers Unable to Identify Group Coordinator Changes`,_jsx(`br`,{})]}),_jsx(_components.td,{children:_jsxs(`ul`,{children:[_jsx(`li`,{children:`Defect Version: V0.4.47`}),_jsx(`li`,{children:`Issue: After partition reassignment of the __consumer_offsets topic, some groups experience consumption interruptions, with errors logged.`}),_jsx(`li`,{children:`Cause: When the __consumer_offsets partitions are reassigned, the coordinator for some groups changes. Kafka-go does not correctly handle this situation, as it continues to send requests to the old coordinator following a change, resulting in NOT_COORDINATOR errors.`})]})}),_jsx(_components.td,{children:_jsxs(`ul`,{children:[_jsx(`li`,{children:`Temporarily restart the Consumer to recover.`}),_jsx(`li`,{children:`Switch SDKs, and it is recommended to use the Franz-Go SDK as per the recommended versions in this document.`})]})})]})})]}),`\n`,_jsx(Heading,{level:`3`,id:`kafka-js-sdk`,children:_jsx(_components.a,{href:`https://github.com/tulios/kafkajs`,children:`Kafka JS SDK`})}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Known Defects`}),_jsx(`br`,{})]}),_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Defect Information`}),_jsx(`br`,{})]}),_jsxs(_components.th,{children:[_jsx(_components.strong,{children:`Resolution Methods`}),_jsx(`br`,{})]})]})}),_jsx(_components.tbody,{children:_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Inaccurate Consumer Configuration of `,_jsx(_components.code,{children:`heartbeatInterval`}),_jsx(`br`,{})]}),_jsx(_components.td,{children:_jsxs(`ul`,{children:[_jsx(`li`,{children:`Defect Version: V2.2.4`}),_jsxs(`li`,{children:[`Community Notes: `,_jsx(_components.a,{href:`https://github.com/tulios/kafkajs/issues/130#issuecomment-422024849`,children:`https://github.com/tulios/kafkajs/issues/130#issuecomment-422024849`})]}),_jsxs(`li`,{children:[`Issue: When the Consumer’s configured `,_jsx(_components.code,{children:`heartbeatInterval`}),` is too close to `,_jsx(_components.code,{children:`sessionTimeout`}),`, the Consumer may periodically Leave \u0026 Rejoin the Group (though it generally does not affect consumption), logging errors.`]}),_jsxs(`li`,{children:[`Cause: In kafkajs, the configuration of `,_jsx(_components.code,{children:`heartbeatInterval`}),` only guarantees the “minimum interval between two heartbeats.” This means that in certain scenarios (e.g., the Consumer reaches the end of the topic with no new messages to consume), the interval between the Consumer sending heartbeats to the Coordinator may exceed the `,_jsx(_components.code,{children:`heartbeatInterval`}),`; if set too large, it may exceed `,_jsx(_components.code,{children:`sessionTimeout`}),`, causing the Coordinator to evict the Consumer.`]})]})}),_jsx(_components.td,{children:_jsx(`ul`,{children:_jsxs(`li`,{children:[`Lower the `,_jsx(_components.code,{children:`heartbeatInterval`}),` or increase the `,_jsx(_components.code,{children:`sessionTimeout`}),` (it is advised that heartbeat.interval.ms should not exceed 1/3 of session.timeout.ms).`]})})})]})})]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Client SDK Guide","description":"AutoMQ provides full Apache Kafka protocol compatibility for scalable, cloud-native messaging. This guide covers recommended client SDKs for various languages to ensure optimal performance and stability.","href":"/automq-cloud/getting-started/client-sdk-guide"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Compatibility Notes","slug":"compatibility-notes","depth":2,"children":[]},{"title":"Recommended Client SDK List","slug":"recommended-client-sdk-list","depth":2,"children":[]},{"title":"Client Parameter Tuning","slug":"client-parameter-tuning","depth":2,"children":[{"title":"Apache Kafka Java Client > 2.1","slug":"apache-kafka-java-client->-2-1","depth":3,"children":[]},{"title":"Apache Kafka Java Client \u003c= 2.1","slug":"apache-kafka-java-client-\u003c=-2-1","depth":3,"children":[]},{"title":"franz-go","slug":"franz-go","depth":3,"children":[]},{"title":"kafka-go","slug":"kafka-go","depth":3,"children":[]},{"title":"Sarama","slug":"sarama","depth":3,"children":[]},{"title":"Logstash Kafka Output","slug":"logstash-kafka-output","depth":3,"children":[]},{"title":"Filebeat Kafka Output","slug":"filebeat-kafka-output","depth":3,"children":[]},{"title":"Fluentd Kafka Output","slug":"fluentd-kafka-output","depth":3,"children":[]},{"title":"Fluent Bit Kafka Output","slug":"fluent-bit-kafka-output","depth":3,"children":[]},{"title":"Vector Kafka Sink","slug":"vector-kafka-sink","depth":3,"children":[]}]},{"title":"Appendix: Other Known Issues","slug":"appendix-other-known-issues","depth":2,"children":[{"title":"Sarama Go SDK","slug":"sarama-go-sdk","depth":3,"children":[]},{"title":"Kafka-Go SDK","slug":"kafka-go-sdk","depth":3,"children":[]},{"title":"Kafka JS SDK","slug":"kafka-js-sdk","depth":3,"children":[]}]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/automq/48fec8bab1afa455/content/monitor.js","/_mintlify/custom/automq/c09aa9839083e17a/content/hubspot.js","/_mintlify/custom/automq/786ace9ed17adbd7/content/luckyorange-tracking.js"],"subdomain":"automq","siteName":"AutoMQ Documentation","title":"Client SDK Guide - AutoMQ Documentation","contextualStarterQuestions":[],"navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"en":{"href":"/automq-cloud/getting-started/client-sdk-guide","matchLevel":0},"cn":{"href":"/zh/automq-cloud/getting-started/client-sdk-guide","matchLevel":1}}},"lastModified":"2026-12-04T08:57:51.190Z","originalFileLocation":"automq-cloud/getting-started/client-sdk-guide.mdx","locale":"en"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=\"light\";if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"light\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"AutoMQ provides full Apache Kafka protocol compatibility for scalable, cloud-native messaging. This guide covers recommended client SDKs for various languages to ensure optimal performance and stability.\">\u003cmeta data-mint-head name=\"application-name\" content=\"AutoMQ Documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Client SDK Guide - AutoMQ Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"AutoMQ provides full Apache Kafka protocol compatibility for scalable, cloud-native messaging. This guide covers recommended client SDKs for various languages to ensure optimal performance and stability.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"AutoMQ Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://automq.mintlify.site/_mintlify/api/og/v2?division=Getting+Started\u0026amp;title=Client+SDK+Guide\u0026amp;description=AutoMQ+provides+full+Apache+Kafka+protocol+compatibility+for+scalable%2C+cloud-native+messaging.+This+guide+covers+recommended+client+SDKs+for+various+languages+t\u0026amp;theme=a9c70ef017645a82054ccd60\u0026amp;signature=ebfd1e3d84ce19e876cbf6fb8abac7d7680f4828ae20df26d7931f41f8f6f3d3\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Client SDK Guide - AutoMQ Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"AutoMQ provides full Apache Kafka protocol compatibility for scalable, cloud-native messaging. This guide covers recommended client SDKs for various languages to ensure optimal performance and stability.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://automq.mintlify.site/_mintlify/api/og/v2?division=Getting+Started\u0026amp;title=Client+SDK+Guide\u0026amp;description=AutoMQ+provides+full+Apache+Kafka+protocol+compatibility+for+scalable%2C+cloud-native+messaging.+This+guide+covers+recommended+client+SDKs+for+various+languages+t\u0026amp;theme=a9c70ef017645a82054ccd60\u0026amp;signature=ebfd1e3d84ce19e876cbf6fb8abac7d7680f4828ae20df26d7931f41f8f6f3d3\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/automq/ZRmM16tNeY4WJ6hO/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"AutoMQ Documentation\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#2449D4\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/automq-cloud/getting-started/client-sdk-guide.md\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"en\" href=\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh\" href=\"https://docs.automq.com/zh/automq-cloud/getting-started/client-sdk-guide\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"x-default\" href=\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.automq.com/#organization\",\"name\":\"AutoMQ Documentation\",\"url\":\"https://docs.automq.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/automq/s9vNxeyMGZ1r1DRV/logo/automq-black.svg?fit=max\u0026auto=format\u0026n=s9vNxeyMGZ1r1DRV\u0026q=85\u0026s=bcc93ae74a4143ae2b7602497b7b354b\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.automq.com#website\",\"name\":\"AutoMQ Documentation\",\"url\":\"https://docs.automq.com\",\"publisher\":{\"@id\":\"https://docs.automq.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide#webpage\",\"url\":\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide\",\"name\":\"Client SDK Guide\",\"description\":\"AutoMQ provides full Apache Kafka protocol compatibility for scalable, cloud-native messaging. This guide covers recommended client SDKs for various languages to ensure optimal performance and stability.\",\"dateModified\":\"2026-12-04T08:57:51.190Z\",\"isPartOf\":{\"@id\":\"https://docs.automq.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Getting Started\",\"item\":\"https://docs.automq.com/automq-cloud/getting-started/overview\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Client SDK Guide\",\"item\":\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide#article\",\"headline\":\"Client SDK Guide\",\"name\":\"Client SDK Guide\",\"description\":\"AutoMQ provides full Apache Kafka protocol compatibility for scalable, cloud-native messaging. This guide covers recommended client SDKs for various languages to ensure optimal performance and stability.\",\"url\":\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide\",\"mainEntityOfPage\":{\"@id\":\"https://docs.automq.com/automq-cloud/getting-started/client-sdk-guide#webpage\"},\"dateModified\":\"2026-12-04T08:57:51.190Z\",\"publisher\":{\"@id\":\"https://docs.automq.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.automq.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"AutoMQ Documentation\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"AutoMQ Documentation\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/automq-cloud/getting-started/client-sdk-guide.md","siteName":"AutoMQ Documentation","nav":{"global":{"anchors":[{"anchor":"Github","icon":"github","href":"https://github.com/automq/automq"},{"anchor":"Slack","icon":"slack","href":"https://go.automq.com/slack"},{"anchor":"Telegram","icon":"Telegram","href":"https://t.me/+VgqhN9wqBGIzYmU1"},{"anchor":"Blog","icon":"newspaper","href":"https://www.automq.com/blog"}]},"languages":[{"language":"en","tabs":[{"tab":"Home","icon":"house","pages":[{"title":"Home","href":""}]},{"tab":"AutoMQ Open Source","icon":"github","pages":[{"title":"AutoMQ Open Source","href":"/automq/what-is-automq/overview"}]},{"tab":"AutoMQ BYOC","icon":"cloud","groups":[{"group":"Overview","icon":"readme","pages":[{"title":"What is AutoMQ BYOC?","href":"/automq-cloud/overview/what-is-automq-cloud"},{"title":"Glossary","href":"/automq-cloud/overview/glossary"},{"title":"Restrictions","href":"/automq-cloud/overview/restrictions"}]},{"group":"Getting Started","icon":"play","pages":[{"title":"Overview","href":"/automq-cloud/getting-started/overview"},{"group":"Install BYOC Environment","pages":[{"group":"AWS","pages":[{"title":"Prepare VPC","href":"/automq-cloud/getting-started/install-byoc-environment/aws/prepare-vpc"},{"title":"Install AutoMQ on AWS","href":"/automq-cloud/getting-started/install-byoc-environment/aws/install-automq-on-aws"}]},{"group":"Google Cloud","pages":[{"title":"Install AutoMQ on Google Cloud","href":"/automq-cloud/getting-started/install-byoc-environment/google-cloud/install-automq-on-gcp"}]},{"title":"OCI","href":"/automq-cloud/getting-started/install-byoc-environment/oci-install-automq"},{"group":"Azure","pages":[{"title":"Install AutoMQ on Azure","href":"/automq-cloud/getting-started/install-byoc-environment/install-env-on-azure"}]}]},{"title":"Experience AutoMQ","description":"Create an AutoMQ instance and verify message production and consumption.","href":"/automq-cloud/getting-started/experience-automq"},{"title":"Client SDK Guide","href":"/automq-cloud/getting-started/client-sdk-guide"}]},{"group":"Deploy on Kubernetes","icon":"https://mintlify.s3.us-west-1.amazonaws.com/automq/images/kubernetes-svgrepo-com.svg","pages":[{"title":"Overview","description":"Requirements, supported platforms, and machine types for deploying AutoMQ BYOC on managed Kubernetes.","href":"/automq-cloud/deploy-automq-on-kubernetes/overview"},{"title":"Deploy to AWS EKS","href":"/automq-cloud/deploy-automq-on-kubernetes/deploy-to-aws-eks"},{"title":"Deploy to Azure AKS","href":"/automq-cloud/deploy-automq-on-kubernetes/deploy-to-azure-aks"},{"title":"Deploy to Google Cloud GKE","href":"/automq-cloud/deploy-automq-on-kubernetes/deploy-to-google-cloud-gke"}]},{"group":"Subscriptions and Billings","icon":"receipt","pages":[{"title":"Overview","href":"/automq-cloud/subscriptions-and-billings/overview"},{"group":"BYOC Env Billings","pages":[{"title":"Usage-Based Billing for AWS","href":"/automq-cloud/subscriptions-and-billings/byoc-env-billings/usage-based-billing"},{"title":"Usage-Based Billing for Azure","href":"/automq-cloud/subscriptions-and-billings/byoc-env-billings/bind-azure-marketplace-payment-method"},{"group":"Prepaid Billing for Others","pages":[{"title":"Prepaid Billing Overview","href":"/automq-cloud/subscriptions-and-billings/byoc-env-billings/billing-instructions-for-byoc"},{"title":"Manage Environment License","href":"/automq-cloud/manage-environments/manage-environment-license"}]}]}]},{"group":"Manage Environments","icon":"clipboard-list","pages":[{"title":"Overview","href":"/automq-cloud/manage-environments/overview"},{"title":"Upgrade Environment Version","href":"/automq-cloud/manage-environments/upgrade-environment-version"},{"group":"Manage Environment Ops Authing","pages":[{"title":"Overview","href":"/automq-cloud/manage-environments/manage-environment-ops-authing/overview"},{"title":"Set Ops Authing from AWS","href":"/automq-cloud/manage-environments/manage-environment-ops-authing/set-ops-authing-from-aws"},{"title":"Set Ops Authing from Google Cloud","href":"/automq-cloud/manage-environments/manage-environment-ops-authing/set-ops-authing-from-google-cloud"},{"title":"Set Ops Authing from OCI","href":"/automq-cloud/manage-environments/manage-environment-ops-authing/set-ops-authing-from-oci"},{"title":"Set Ops Authing from Azure","href":"/automq-cloud/manage-environments/manage-environment-ops-authing/set-ops-authing-from-azure"},{"title":"Set Ops Tunnel for Troubleshooting","href":"/automq-cloud/manage-environments/manage-environment-ops-authing/set-ops-tunnel-for-troubleshooting"}]}]},{"group":"Manage Identities and Access","icon":"fingerprint","pages":[{"title":"Overview","href":"/automq-cloud/manage-identities-and-access/overview"},{"title":"Member Accounts","href":"/automq-cloud/manage-identities-and-access/member-accounts"},{"title":"Role-Based Access Control","href":"/automq-cloud/manage-identities-and-access/role-based-access-control"},{"title":"Service Accounts","href":"/automq-cloud/manage-identities-and-access/service-accounts"},{"title":"Identity Providers and SSO Authentication","href":"/automq-cloud/manage-identities-and-access/identity-providers-and-sso-authentication"}]},{"group":"Managing AutoMQ","icon":"boxes","pages":[{"title":"Manage Instances","href":"/automq-cloud/managing-automq/manage-instances"},{"title":"Manage Topics","href":"/automq-cloud/managing-automq/manage-topics"},{"title":"Manage Consumer Groups","href":"/automq-cloud/managing-automq/manage-consumer-groups"}]},{"group":"Migrate to AutoMQ","icon":"arrow-right-left","pages":[{"title":"Overview","href":"/automq-cloud/migrate-to-automq/overview"},{"title":"Prerequisites","href":"/automq-cloud/migrate-to-automq/prerequisites"},{"title":"Executing Migration","href":"/automq-cloud/migrate-to-automq/executing-migration"},{"title":"Kafka Linking best practices","href":"/automq-cloud/migrate-to-automq/kafka-linking-best-practices"}]},{"group":"Manage Security","icon":"globe-lock","pages":[{"title":"Overview","href":"/automq-cloud/manage-security/overview"},{"group":"Authentication","pages":[{"title":"SASL Authentication","href":"/automq-cloud/manage-security/authentication/sasl-authentication"},{"title":"Mutual TLS (mTLS) Authentication","href":"/automq-cloud/manage-security/authentication/mutual-tls-mtls-authentication"}]},{"title":"Data Encryption at Rest","href":"/automq-cloud/manage-security/data-encryption-at-rest"},{"title":"Manage Kafka ACLs","href":"/automq-cloud/manage-security/manage-kafka-acls"}]},{"group":"Kafka Connect","icon":"blocks","pages":[{"title":"Overview","href":"/automq-cloud/kafka-connect/overview"},{"title":"Manage Plugins","href":"/automq-cloud/kafka-connect/manage-plugins"},{"title":"Manage Connectors","href":"/automq-cloud/kafka-connect/manage-connectors"},{"group":"Source Connectors","pages":[{"title":"Azure IoT Hub Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/azure-iot-hub-source-connector"},{"title":"Camunda Zeebe Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/camunda-zeebe-source-connector"},{"title":"Couchbase Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/couchbase-kafka-connect-couchbase-source-connector"},{"title":"Debezium MongoDB CDC Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/debezium-mongodb-source-connector"},{"title":"Debezium MySQL Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/debezium-mysql-source-connector"},{"title":"Debezium PostgreSQL Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/debezium-postgresql-source-connector"},{"title":"Debezium SQL Server Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/debezium-sqlserver-source-connector"},{"title":"Diffusion Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/diffusion-source-connector"},{"title":"Elasticsearch Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/elasticsearch-source-connector"},{"title":"IRC Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/irc-source-connector"},{"title":"MongoDB Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/mongodb-source-connector"},{"title":"Neo4j Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/neo4j-source-connector"},{"title":"Redis Stream Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/redis-source-connector"},{"title":"RSS Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/rss-source-connector"},{"title":"Scylla CDC Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/scylla-cdc-source-connector"},{"title":"Server Sent Events Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/server-sent-events-source-connector"},{"title":"Shell Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/shell-source-connector"},{"title":"Twitter Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/twitter-source-connector"},{"title":"YugabyteDB Source Connector","href":"/automq-cloud/kafka-connect/source-connectors/yugabytedb-source-connector"}]},{"group":"Sink Connectors","pages":[{"title":"Ably Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/ably-kafka-sink-connector"},{"title":"Adobe Experience Platform Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/adobe-experience-platform-sink-connector"},{"title":"Amazon EventBridge Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/amazon-eventbridge-sink-connector"},{"title":"Apache Iceberg Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/apache-iceberg-sink-connector"},{"title":"ArangoDB Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/arangodb-sink-connector"},{"title":"Azure IoT Hub Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/azure-iot-hub-sink-connector"},{"title":"Camunda Zeebe Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/camunda-platform-8-zeebe-sink-connector"},{"title":"ClickHouse Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/clickhouse-sink-connector"},{"title":"Couchbase Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/couchbase-kafka-connect-couchbase-sink-connector"},{"title":"Datadog Logs Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/datadog-logs-sink-connector"},{"title":"Diffusion Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/diffusion-sink-connector"},{"title":"Google BigQuery Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/wepay-kafka-connect-bigquery-sink-connector"},{"title":"Lightstreamer Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/lightstreamer-sink-connector"},{"title":"Milvus Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/milvus-sink-connector"},{"title":"MongoDB Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/mongodb-sink-connector"},{"title":"Neo4j Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/neo4j-sink-connector"},{"title":"New Relic Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/new-relic-sink-connector"},{"title":"Redis Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/redis-sink-connector"},{"title":"ScyllaDB Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/scylladb-sink-connector"},{"title":"Shell Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/shell-sink-connector"},{"title":"SingleStore Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/singlestore-sink-connector"},{"title":"Snowflake Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/snowflake-kafka-sink-connector"},{"title":"Splunk Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/splunk-kafka-sink-connector"},{"title":"Timeplus Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/timeplus-sink-connector"},{"title":"Vectara Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/vectara-sink-connector"},{"title":"Weaviate Sink Connector","href":"/automq-cloud/kafka-connect/sink-connectors/weaviate-kafka-sink-connector"}]}]},{"group":"Monitoring \u0026 Alert","icon":"telescope","pages":[{"title":"Monitoring \u0026 Alert Via Prometheus","href":"/automq-cloud/monitoring-alert/monitoring-alert-via-prometheus"},{"title":"Monitor consumer lag","href":"/automq-cloud/monitoring-alert/monitor-consumer-lag"},{"title":"Integrating Metrics with Datadog","href":"/automq-cloud/monitoring-alert/integrating-metrics-with-datadog"}]},{"group":"Table Topic","icon":"text-search","pages":[{"title":"Overview","href":"/automq-cloud/table-topic/overview"},{"title":"Table Topic Integration with AWS Glue","href":"/automq-cloud/table-topic/table-topic-integration-with-aws-glue"},{"title":"Table Topic Integration with AWS S3 Table","href":"/automq-cloud/table-topic/table-topic-integration-with-aws-s3-table"}]},{"group":"Best Practice","icon":"spotlight","pages":[{"title":"Kafka Client Config Tuning","href":"/automq-cloud/best-practice/kafka-client-config-tuning"}]},{"group":"Eliminate Inter-Zone Traffics","icon":"audio-lines","pages":[{"title":"Overview","href":"/automq-cloud/eliminate-inter-zone-traffics/overview"},{"title":"Broker Configuration","href":"/automq-cloud/eliminate-inter-zone-traffics/broker-configuration"},{"title":"Client Configuration","href":"/automq-cloud/eliminate-inter-zone-traffics/client-configuration"},{"title":"Monitor Cross-AZ Traffic","href":"/automq-cloud/eliminate-inter-zone-traffics/monitor-inter-zone-traffic"}]},{"group":"Release Notes","icon":"rocket","pages":[{"title":"Release Notes","href":"/automq-cloud/release-notes"}]},{"group":"Support","icon":"message-circle-question-mark","pages":[{"title":"Obtaining Services","href":"/automq-cloud/support/obtaining-services"},{"title":"Service Level Agreement","href":"/automq-cloud/support/service-level-agreement"},{"title":"Terms of Service","href":"/automq-cloud/support/terms-of-service"}]},{"group":"Appendix","icon":"book-text","pages":[{"title":"Cloud Resource List","href":"/automq-cloud/appendix/cloud-resource-list"},{"title":"Deploy AutoMQ Software Via Helm Chart","href":"/automq-cloud/appendix/deploy-automq-enterprise-via-helm-chart"},{"title":"Helm Chart Values Documentation","href":"/automq-cloud/appendix/helm-chart-values-readme"},{"title":"Performance Benchmark for AWS","href":"/automq-cloud/appendix/performance-benchmark"},{"title":"Performance Benchmark for Azure","href":"/automq-cloud/appendix/performance-benchmark-for-azure"},{"title":"AWS BYOC Console Upgrade Guide for Version 8.x","href":"/automq-cloud/appendix/byoc-console-upgrade-to-8.x-guide"},{"title":"GCP BYOC Console Upgrade Guide to v8.x","href":"/automq-cloud/appendix/gcp-byoc-console-upgrade-to-8.x-guide"},{"title":"Azure BYOC Console Upgrade Guide to v8.x","href":"/automq-cloud/appendix/azure-byoc-console-upgrade-to-8.x-guide"}]}]}]},{"language":"cn","pages":[{"title":"cn","href":"/zh/automq-cloud/getting-started/client-sdk-guide"}]}]},"basePath":"","title":"Client SDK Guide - AutoMQ Documentation","deploymentId":"dpl_BLZw3QngerHodH9E8mGgC4v752y3","buildId":"dpl_BLZw3QngerHodH9E8mGgC4v752y3","dynamics":[],"chunks":[]}