I am using Spring Batch Admin as a web frontend for my Spring Batch project together with Spring Boot.
Batch Admin provides some templates using Freemarker to set up the layout. I have added some more templates which are stored in src/main/webapp/web/layouts/html and the ressources are included in the packaging process into the .jar file.
When I start the app, my own layouts are not found ("layouts/html/myOwn.ftl not found" is the error message).
I can solve this by adding a FreeMarkerConfigurer like this:
<bean id="freemarkerConfig" class="org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer">
<property name="templateLoaderPath"><value>classpath:/WEB-INF/</value></property>
</bean>
However, when I do this, my own templates are found but the standard templates are gone (like layouts/html/home.ftl).
Is there a way to provide two paths or two template loaders such that the default template loader of Spring Batch Admin is not overwritten but used as a fallback?
Or is there any other solution like having the ressources in a specific place?
templateLoaderPaths(note the "s" at the end), where you can specify multiple locations (example: stackoverflow.com/questions/36330590/…). I don't know where Spring Batch Admin loads the templates from though. - ddekany