0

I have experienced some strange behaviour running a Tomcat server within Eclipse (this has happened to me twice now).

I have a maven web app in eclipse running in the tomcat server, the server configuration is normal and I have not checked the server option: "Serve Modules Without Publishing" - although i prefer to have this checked, I am on Windows 7 and usually on a new project in eclipse if i check this option then the server doesnt start.

Now the project I am working on has been working fine for some time, running perfectly etc, and this morning I changed some (hibernate)domain classes and went to restart the server and got this error: Spring 3.0 - Unable to locate Spring NamespaceHandler for XML schema namespace [http://www.springframework.org/schema/security]

Now as the server had been running, and all I had changed were some minor hibernate classes, I knew I hadnt broken anything (tried various things like refreshing/mvn clean/package/etc).

Having experienced some strange behaviour before on another project, I tried changing the "Serve Moduels without Publishing" to be checked and restarted, and worked fine!

Can anyone explain what it is that is suddenly flipping that switch and making me need to have to have it ticked to load?


UPDATE: As requested, below is the declaration at the top of the app context config:

<beans:beans xmlns="http://www.springframework.org/schema/security"
    xmlns:beans="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.springframework.org/schema/beans 
                        http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
                        http://www.springframework.org/schema/security 
                        http://www.springframework.org/schema/security/spring-security-3.0.xsd">
Community
  • 1
  • 1
rhinds
  • 9,976
  • 13
  • 68
  • 111
  • I think the problem in you Spring context file. Can you paste the the first tag (the one with schema names) here? – AlexV May 13 '12 at 11:50
  • I have added the details to the original post, however, as I mentioned, there has been no change to this or any of teh classpath/maven dependencies in between it originally working, stopping working and then starting again - So I don not believe this is related, My suspicons are that it is more of a Eclipse/Tomcat question – rhinds May 13 '12 at 19:52
  • do you have a spring-security-config dependency in your pom.xml? – AlexV May 14 '12 at 09:38
  • @AlexV Yes. The jars/xsd/etc are all available in the classpath. Like i said, all i changed was the tomcat config and it started working (suggesting that all the dependencies etc are there perfectly fine) - which is why I am pretty confident saying its actually a tomcat/eclipse question – rhinds May 14 '12 at 14:47

0 Answers0