JdbcSessionAutoConfiguration may not match when using the auto-configured DataSource#48552
JdbcSessionAutoConfiguration may not match when using the auto-configured DataSource#48552candrews wants to merge 1 commit intospring-projects:mainfrom
Conversation
JdbcSessionAutoConfiguration is conditional on the DataSource bean which won't exist until after DataSourceAutoConfiguration; therefore, JdbcSessionAutoConfiguration must autoconfigure after DataSourceAutoConfiguration. Signed-off-by: Craig Andrews <candrews@integralblue.com>
|
Thanks, @candrews. Can you please share some more information about the application in which this is failing? Boot smoke test for Spring Session JDBC isn't affected, I believe because, in the absence of any other ordering, the auto-configuration class order will be alphabetical. I'd like to understand what's changing that ordering in your situation in case there's another problem lurking somewhere. |
|
The application is large and complex with a number of Is there something I could run to provide more information you need? |
|
Thanks, @candrews. I don't think we need anything more. The alphabetical ordering is a last resort so as soon as you have other before/after ordering, as you do, it could change. |
JdbcSessionAutoConfiguration is conditional on the DataSource bean which won't exist until after DataSourceAutoConfiguration; therefore, JdbcSessionAutoConfiguration must auto-configure after DataSourceAutoConfiguration. Signed-off-by: Craig Andrews <candrews@integralblue.com> See gh-48552
|
Thanks again, @candrews. This'll be in tomorrow's 4.0.1 release. |
JdbcSessionAutoConfigurationis conditional on theDataSourcebean which won't exist until afterDataSourceAutoConfiguration; therefore,JdbcSessionAutoConfigurationmust auto-configure afterDataSourceAutoConfiguration.This change fixes the
JdbcSessionAutoConfigurationfailing to auto-configure due there being noDataSourcebean despiteDataSourceAutoConfigurationcreating aDataSourcebean.From the autoconfiguration report: