ThymeLeaf is always initializing on every request.

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

ThymeLeaf is always initializing on every request.

shukdebp
ThymeLeaf is always initializing on every request even if it is being cached using Spring like below,

<bean id="templateResolver" class="org.thymeleaf.templateresolver.ServletContextTemplateResolver" scope="singleton">
        <property name="cacheable" value="false" />
        <property name="prefix" value="/WEB-INF/templates/" />
        <property name="templateMode" value="HTML5" />
        <property name="characterEncoding" value="UTF-8" />
    </bean>
    <bean class="org.thymeleaf.spring3.SpringTemplateEngine">
        <property name="templateResolver" ref="templateResolver" />
    </bean>

See below text is always displaying in console on onvoking of every request,
[ThymeLeafApp] [/ThymeLeaf] [SimpleFileServlet]: Initialization successful.
[8/28/12 16:07:27:546 IST] 00000039 ServletWrappe I   SRVE0242I: [ThymeLeafApp] [/ThymeLeaf] [SimpleFileServlet]: Initialization successful.
[8/28/12 16:07:27:546 IST] 00000038 ServletWrappe I   SRVE0242I: [ThymeLeafApp] [/ThymeLeaf] [SimpleFileServlet]: Initialization successful.
[8/28/12 16:07:27:578 IST] 00000035 ServletWrappe I   SRVE0242I: [ThymeLeafApp] [/ThymeLeaf] [SimpleFileServlet]: Initialization successful.
[8/28/12 16:07:27:578 IST] 0000003e ServletWrappe I   SRVE0242I: [ThymeLeafApp] [/ThymeLeaf] [SimpleFileServlet]: Initialization successful.

Also I am using thymeleaf-2.0.8.jar, thymeleaf-spring3-2.0.8.jar jars in the Application.

Can anyone explain the reason or if there is any issue with configuration of ThymeLeaf?
Reply | Threaded
Open this post in threaded view
|

Re: ThymeLeaf is always initializing on every request.

danielfernandez
Administrator

Hi,

I'm afraid there is no "ThymeleafApp" or "SimpleFileServlet" class in Thymeleaf, nor there is any "Initialization successful" log message... so what you are probably looking at is a log message from your own application.

Regards,
Daniel.