We are facing one issue about EhCache and Spring, when we point XSD file in ehcache.xml to http://ehcache.org/ehcache.xsd, everything is ok, our application can startup cor
In my case just downloading the file from http://ehcache.org/ehcache.xsd into src/main/resources
solves the problem
cd src/main/resources
wget http://ehcache.org/ehcache.xsd
usually I set xsi:noNamespaceSchemaLocation="http://ehcache.org/ehcache.xsd"
, But this can't work in a offline environment.
Download ehcache.xsd, put it to the same folder where is your config xml file. modify the xml head like below, notice the classpath prefix:
<ehcache
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="classpath:ehcache.xsd">
This will work in the development and production environment.
My Workaround is add this xsd file to absolute path, such as: c:/ehcache.xsd and point to this location in ehcache.xml. Hope this will help someone who facing the same issue.
Still looking forward to find out other solution.
Thanks.