-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Spring 6.0.1 and newer requires/prefers compilation with "-parameters" #4258
Copy link
Copy link
Closed
Milestone
Description
When starting an application with Spring 6.0.2, Spring Batch 5.0.0 and Spring Boot 3.0.0, Spring logs 86 warning messages that look like this:
12:58:39.789 [main] WARN o.s.c.LocalVariableTableParameterNameDiscoverer - Using deprecated '-debug' fallback for parameter name resolution. Compile the affected code with '-parameters' instead or avoid its introspection: org.springframework.batch.integration.launch.JobLaunchingMessageHandler
12:58:40.083 [main] WARN o.s.c.LocalVariableTableParameterNameDiscoverer - Using deprecated '-debug' fallback for parameter name resolution. Compile the affected code with '-parameters' instead or avoid its introspection: org.springframework.batch.core.configuration.support.GenericApplicationContextFactory
12:58:40.386 [main] WARN o.s.c.LocalVariableTableParameterNameDiscoverer - Using deprecated '-debug' fallback for parameter name resolution. Compile the affected code with '-parameters' instead or avoid its introspection: org.springframework.batch.core.configuration.annotation.JobBuilderFactory
12:58:40.426 [main] WARN o.s.c.LocalVariableTableParameterNameDiscoverer - Using deprecated '-debug' fallback for parameter name resolution. Compile the affected code with '-parameters' instead or avoid its introspection: org.springframework.batch.core.configuration.annotation.StepBuilderFactory
12:58:43.080 [main] WARN o.s.c.LocalVariableTableParameterNameDiscoverer - Using deprecated '-debug' fallback for parameter name resolution. Compile the affected code with '-parameters' instead or avoid its introspection: org.springframework.batch.core.job.flow.support.state.StepState
12:58:43.087 [main] WARN o.s.c.LocalVariableTableParameterNameDiscoverer - Using deprecated '-debug' fallback for parameter name resolution. Compile the affected code with '-parameters' instead or avoid its introspection: org.springframework.batch.core.job.flow.support.StateTransition
12:58:43.096 [main] WARN o.s.c.LocalVariableTableParameterNameDiscoverer - Using deprecated '-debug' fallback for parameter name resolution. Compile the affected code with '-parameters' instead or avoid its introspection: org.springframework.batch.core.job.flow.support.state.EndState
12:58:43.105 [main] WARN o.s.c.LocalVariableTableParameterNameDiscoverer - Using deprecated '-debug' fallback for parameter name resolution. Compile the affected code with '-parameters' instead or avoid its introspection: org.springframework.batch.core.configuration.xml.JobParserJobFactoryBean
12:58:43.773 [main] WARN o.s.c.LocalVariableTableParameterNameDiscoverer - Using deprecated '-debug' fallback for parameter name resolution. Compile the affected code with '-parameters' instead or avoid its introspection: org.springframework.batch.core.job.flow.support.state.DecisionState
LocalVariableTableParameterNameDiscoverer is marked as deprecated for removal. This means that it might be removed in Spring 6.1.
I got several similar warning messages related to my own code as well, these went away when adding the -parameters flag in my maven-compiler-plugin configuration. Only the messages related to Spring Batch remain.
To resolve this, could you add the -parameters flag to your build for a later release?
Reactions are currently unavailable