1: Spring's spring-context-support
error java.lang.NoClassDefFoundError: org/apache/velocity/runtime/log/CommonsLogLogChute
Wait for Spring to upgrade to support Velocity 2.0.x or change the source code of Spring by yourself
The entire initialization log process of velocity:
-
- new RuntimeInstance(), attribute Log log = new Log(), by default create a HoldingLogChute() as LogChute, (the LogChute temporarily records logs to the memory object)
- RuntimeInstance.init() to initialize the velocity system
- Call initializeProperties() sequentially, read the default configuration of velocity.properties, and merge custom properties.
- Call initializeLog() sequentially, call LogManager.updateLog(), and initialize Log
- LogManager.createLogChute() will first read the runtime.log.logsystem configuration to see if there is a custom LogChute instance object, and if so, use it directly and return
- If there is no corresponding LogChute instance object configuration, continue to read runtime.log.logsystem.class to see if there seems to be a logsystem configuration, which is the implementation class of a pair of LogChute and LogSystem in the previous class diagram.
- In order, load the LogChute implementation classes one by one. If the class is loaded successfully, initialize and return
- LogManager, for createLogChute, outputs the content recorded by HoldingLogChute at the beginning of the system to the new LogChute, and finally completes the initialization of the log
2: Change Velocity.properties
runtime.conversion.handler = none space.gobbling = bc