Sunday 15 May 2011

java - Resource Not Found after Spring 4.1.2 Update when deploy with JRebel 6.0.0 -



java - Resource Not Found after Spring 4.1.2 Update when deploy with JRebel 6.0.0 -

spring 4.1.2 (4.0.8 , 3.2.12) contains security bugfix spr-12354 prevents resourcehttprequesthandler (the thing behind <mvc:resources>) load files outside the resource folder.

on other hand: jrebel (i utilize default configuration). , seams jrebel magic load resources not wtp folder straight form "source" folder.

so after upgrading spring 3.2.11 3.2.12 (and other similar application 4.0.7 4.0.8) springs resourcehttprequesthandler not longer deliver resource files "maintained" jrebel. instead delivers 404. reason spring compare absolute file path of configured resource folder absolute file path of file going delivered. if resourcehttprequesthandler perceived file outside of configured resource folder, assume url used select file malicious. hence resourcehttprequesthandler , response 404 resource not found.

i expect jrebel can been configured not "maintain" js, png , css files, don't know how. , question: how configure jrebel spring mvc application (v 4.0.8) still deliver resources resourcehttprequesthandler?

(i expect every jrebel user facing problem after upgrading spring 4.1.2, 4.0.8 or 3.2.12).

(don't me wrong, not question how manipulate spring not check files outside of configures resource folder. have had @ source code , observed behaviour behaviour intended authors of bug fix. - question configuring jrebel)

thank problem description!

looks spring alter introduced incompatibility jrebel. jrebel team , create sure fixed!

as workaround can utilize <exclude> tag in rebel.xml <web> element tell jrebel not touch these specific files. here more info of how configure http://manuals.zeroturnaround.com/jrebel/standalone/config.html#exclude

other easier workaround removing <web> element altogether.

java spring spring-mvc jrebel

No comments:

Post a Comment