I have a small web app using Spring Boot 1.40 and I am having some issues with webjars-locator. When run on my machine using the embedded Tomcat, the webjars-locator works as expected, and I can access eg. jQuery with the following HTML:
<script src="/webjars/jquery/jquery.min.js" type="text/javascript"></script>
However, when the app is packaged as a .war file and deployed to JBoss 6.4.5, that same HTML no longer works. Trying to directly access the .js file in the browser with that URL results in a 404. However I can use
<script src="/webjars/jquery/1.11.3/jquery.min.js" type="text/javascript"></script>
and the file will be found and everything is fine. I am seeing a possibly related log entry when running the app on JBoss:
2016-08-20 02:01:01.154 WARN o.s.w.s.r.ResourceHttpRequestHandler - Locations list is empty. No resources will be served unless a custom ResourceResolver is configured as an alternative to PathResourceResolver.
I'm guessing there's something I need to specifically configure when running in JBoss that "just works" in the embedded Tomcat; if someone could point me in the right direction that would be great.
Having to specify the version of the webjar is not a deal breaker for this particular app, but could be a huge pain in a larger app if we needed to upgrade jQuery or something else.