Skip to content

Messages: Make it possible to produce messages w/o a transaction #793

@shizheng163

Description

@shizheng163

Issue submitter TODO list

  • I've searched for an already existing issues here
  • I'm running a supported version of the application which is listed here and the feature is not present there

Is your proposal related to a problem?

No response

Describe the feature you're interested in

Issue Title: How to Disable Transactional Producer in Kafka-UI When Broker Transactions Are Disabled?


Description:

Hello,

I am experiencing an issue with Kafka-UI when trying to send messages to a Kafka broker that has transactions disabled (transactions.enable=false). I'd like to report this problem and ask for guidance on how to configure Kafka-UI to send messages without initiating transactions on the client side.

Environment:

  • Kafka-UI Version: ghcr.io/kafbat/kafka-ui:latest

Problem Description:

  • Local Kafka Broker:

    • Messages can be sent successfully using Kafka-UI.
    • The broker's transactions.enable parameter is set to true (transactions are enabled).
  • Remote Kafka Broker:

    • Using the same Kafka-UI configuration, I cannot send messages to the remote broker.
    • The broker's transactions.enable parameter is set to false (transactions are disabled).

Analysis:

It appears that Kafka-UI uses a transactional producer when sending messages. If the broker does not support transactions, attempts to send messages fail because the client tries to start a transaction that the broker cannot handle.

I prefer not to change the server (broker) configuration to enable transactions, especially in production environments, where modifying broker settings might have unintended consequences.

Question:

  • How can I configure Kafka-UI to disable the transactional producer behavior on the client side when sending messages?
  • Is there a way to send messages using Kafka-UI without initiating transactions, so that messages can be sent to brokers with transactions disabled?

Attempts Made:

  • I have explored Kafka-UI's configuration options but haven't found a clear way to disable transactional behavior for the producer.
  • I understand that Kafka producers can be configured to not use transactions by not setting a transactional.id and by ensuring that enable.idempotence is set appropriately.
  • However, I am unsure how to apply these configurations within Kafka-UI.

Request for Assistance:

  • Could you please provide guidance on how to adjust Kafka-UI's client configuration to disable transactions when sending messages?
  • If this functionality is not currently available, would it be possible to add an option in Kafka-UI to configure the producer's transactional behavior?

Additional Information:

  • When I set transactions.enable=true on the remote broker, Kafka-UI can successfully send messages.
  • Given that both local and remote brokers behave differently due to this setting, adjusting the client behavior seems like a preferable solution.
  • I have a scenario where I need to interact with brokers that have transactions disabled, and modifying their configuration is not feasible.

Thank You:

Thank you for your time and for providing Kafka-UI as a valuable tool for the community. I appreciate your assistance and look forward to your guidance on resolving this issue.


Note: If any logs or error messages would be helpful, please let me know, and I'll provide them accordingly.

Describe alternatives you've considered

No response

Version you're running

ghcr.io/kafbat/kafka-ui:latest

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions