Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
2 tasks done
shizheng163 opened this issue Jan 21, 2025 · 2 comments
Open
2 tasks done
Labels
scope/backend Related to backend changes status/triage/completed Automatic triage completed type/bug Something isn't working

Comments

@shizheng163
Copy link

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

@shizheng163 shizheng163 added status/triage Issues pending maintainers triage type/feature A brand new feature labels Jan 21, 2025
@kapybro kapybro bot added status/triage/manual Manual triage in progress status/triage/completed Automatic triage completed and removed status/triage Issues pending maintainers triage labels Jan 21, 2025
Copy link

Hi shizheng163! 👋

Welcome, and thank you for opening your first issue in the repo!

Please wait for triaging by our maintainers.

As development is carried out in our spare time, you can support us by sponsoring our activities or even funding the development of specific issues.
Sponsorship link

If you plan to raise a PR for this issue, please take a look at our contributing guide.

@Haarolean
Copy link
Member

Hi, thanks for reporting this!

Perhaps, a solution to expose the producer properties (like #527 for consumers) would help.

@Haarolean Haarolean moved this to Review Required in Housekeeping Jan 21, 2025
@Haarolean Haarolean added scope/backend Related to backend changes type/bug Something isn't working and removed type/feature A brand new feature status/triage/manual Manual triage in progress labels Jan 21, 2025
@Haarolean Haarolean changed the title How to Disable Transactional Producer in Kafka-UI When Broker Transactions Are Disabled? Messages: Make it possible to produce messages w/o a transaction Jan 21, 2025
@Haarolean Haarolean moved this from Review Required to Active in Housekeeping Jan 22, 2025
@Haarolean Haarolean removed this from Housekeeping Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope/backend Related to backend changes status/triage/completed Automatic triage completed type/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants