-
Notifications
You must be signed in to change notification settings - Fork 41.2k
Use ObjectProvider<T> with ordered list access instead of ObjectProvider<List<T>> #14467
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
Comments
I've got an attempt at this in this branch. Unfortunately,
|
Let's try to sort this out tomorrow morning if we can. This is important enough for 5.1 GA still. |
The problem's occurring because the ordering information isn't available. It isn't available as the order source provider doesn't have the right information. In
In Despite figuring this much out, I'm not yet able to reproduce it in a standalone test. In my attempt at doing so, the map returned from |
Ah, Class references... We put those in for beans which aren't initialized yet at the time of retrieval, resolving them on the fly as their instances are being accessed... But of course that doesn't work once the order is being derived with those as keys. I'll reopen SPR-17272 accordingly. |
This is sorted out on master now. Please give it a try! |
@sdeleuze has identified some cases with Spring Fu where a failure occurs due to a |
As far as I see, a Java 8 |
Indeed. I wasn't intending a |
Definitely hold on to the |
As discussed in SPR-17272 (which is now fixed on Spring Framework
master
),ObjectProvider
now provides ordered list access, supersedingObjectProvider<List>
.In addition to follow best practices, updating Boot auto-configuration classes to use
ObjectProvider<T>
parameters with ordered list access instead ofObjectProvider<List<T>>
would make it usable withBeanFactory.getBeanProvider()
, required with functional bean registration like in Kofu configuration or @dsyer work in spring-boot-micro-apps.The text was updated successfully, but these errors were encountered: