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

Mention Ordered and @Order support for components in Javadoc #23636

Closed
ttddyy opened this issue Sep 13, 2019 · 3 comments
Closed

Mention Ordered and @Order support for components in Javadoc #23636

ttddyy opened this issue Sep 13, 2019 · 3 comments
Assignees
Labels
status: feedback-provided Feedback has been provided type: documentation A documentation task
Milestone

Comments

@ttddyy
Copy link
Contributor

ttddyy commented Sep 13, 2019

While debugging PostProcessorRegistrationDelegate, I realized BeanFactoryPostProcessor works with Ordered(and PriorityOrdered) interface but not @Order annotation.

It would be great that such information is documented on BeanFactoryPostProcessor javadoc.

In general, for ordering, it would be great to have a mention in javadoc that whether the component works with Ordered interface and/or @Order annotation.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged or decided on label Sep 13, 2019
@sbrannen sbrannen changed the title Mentioning "Ordered" and "@Order" in components javadoc Mention Ordered and @Order support for components in Javadoc Sep 14, 2019
@sbrannen sbrannen added type: documentation A documentation task and removed status: waiting-for-triage An issue we've not yet triaged or decided on labels Sep 14, 2019
@sbrannen sbrannen added this to the 5.2 GA milestone Sep 14, 2019
@sbrannen
Copy link
Member

When you say "components", did you have any other special types in mind other than BeanFactoryPostProcessor implementations?

@sbrannen sbrannen added the status: waiting-for-feedback We need additional information before we can continue label Sep 14, 2019
@ttddyy
Copy link
Contributor Author

ttddyy commented Sep 15, 2019

I was thinking mainly lifecycle related classes, BeanFactoryPostProcessor, BeanPostProcessor, InitializingBean, etc.

Also, it would be nice that @Order and Ordered have list of classes that will be applied ordering.

Thanks,

@spring-projects-issues spring-projects-issues added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Sep 15, 2019
@sbrannen
Copy link
Member

I was thinking mainly lifecycle related classes, BeanFactoryPostProcessor, BeanPostProcessor, InitializingBean, etc.

For BeanFactoryPostProcessor and BeanPostProcessor I agree that it would be helpful to document ordering support for PriorityOrdered and Ordered.

I don't think any ordering is applied to InitializingBean implementations.

Also, it would be nice that @Order and Ordered have list of classes that will be applied ordering.

I fear that list would be too long and difficult to maintain. Support for ordering is normally documented in APIs that users interact with and or implement, not in something like @Order or Ordered.

@jhoeller, what are your thoughts on the matter?

@sbrannen sbrannen self-assigned this Sep 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: feedback-provided Feedback has been provided type: documentation A documentation task
Projects
None yet
Development

No branches or pull requests

3 participants