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

Programmatic Endpoint Registration setId #2895

Closed
mmesar opened this issue Nov 12, 2024 · 1 comment
Closed

Programmatic Endpoint Registration setId #2895

mmesar opened this issue Nov 12, 2024 · 1 comment

Comments

@mmesar
Copy link

mmesar commented Nov 12, 2024

I believe that documentation
https://docs.spring.io/spring-amqp/reference/amqp/receiving-messages/async-annotation-driven/registration.html

is missing setId method call on SimpleRabbitListenerEndpoint object to work.

@artembilan
Copy link
Member

Sure!
Feel free to provide that documentation improvement: https://github.com/spring-projects/spring-amqp/blob/main/CONTRIBUTING.adoc.

Although the logic is like this:

public void registerEndpoint(RabbitListenerEndpoint endpoint,
			@Nullable RabbitListenerContainerFactory<?> factory) {
		Assert.notNull(endpoint, "Endpoint must be set");
		Assert.hasText(endpoint.getId(), "Endpoint id must be set");

So, if something is missed, it will be reported back to the caller.
There are might be much more nuances which we don't mention in the docs, but they make it obvious when you run your application.
We definitely cannot cover all the possible use-cases in the reference doc.

@artembilan artembilan modified the milestones: 3.2.0, Backlog Nov 18, 2024
@artembilan artembilan modified the milestones: Backlog, 3.2.1 Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants