Skip to content

Deprecate StandardMetadata constructors #22906

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

Closed
philwebb opened this issue May 6, 2019 · 0 comments
Closed

Deprecate StandardMetadata constructors #22906

philwebb opened this issue May 6, 2019 · 0 comments
Assignees
Labels
in: core Issues in core modules (aop, beans, core, context, expression) type: task A general task

Comments

@philwebb
Copy link
Member

philwebb commented May 6, 2019

Currently the StandardMetadata class has public constructors that are making it hard to evolve. Specifically we'd like to remove the nestedAnnotationsAsMap parameter, and make the default effectively nestedAnnotationsAsMap=true.

It's doubtful that anyone is using this class directly, but to be safe we could deprecate the constructors and use a factory method instead.

@philwebb philwebb added the type: task A general task label May 6, 2019
@philwebb philwebb self-assigned this May 6, 2019
@philwebb philwebb added the in: core Issues in core modules (aop, beans, core, context, expression) label May 6, 2019
philwebb added a commit to philwebb/spring-framework that referenced this issue May 6, 2019
Deprecate the public `StandardMetadata` constructors to make it clearer
that these classes should not be instantiated directly. A new
`AnnotationMetadata.introspect` factory method has been added which
can now be used to obtain instances.

This change will allow use to make the constructors package private
and drop the `nestedAnnotationsAsMap` parameter in a future release.

Closes spring-projectsgh-22906
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core Issues in core modules (aop, beans, core, context, expression) type: task A general task
Projects
None yet
Development

No branches or pull requests

1 participant