• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

spring config xml error

 
Brian Mulholland
Ranch Hand
Posts: 65
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My app works at runtime, but eclipse continues to tell me I'm doing it wrong. The error appears on the <beans> node.

Referenced file contains errors (http://www.springframework.org/schema/beans/spring-beans-3.0.xsd). For more information, right click on the message and select "Show Details..."

When I click Show Details it says:

The reference to entity "uri" must end with the ";" delimiter.

On line 1 of http://www.springframework.org/schema/beans/spring-beans-3.0.xsd. Obviously that file is not under my control. my beans node looks like this:



Ideas?
 
Brian Mulholland
Ranch Hand
Posts: 65
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Uhhh...okay, so I hit enter to format the node slightly differently (all attributes on a new line), rebuilt and the error cleared. I had cleaned and rebuilt before this to no avail. But this time, bam, problem gone?
 
Brian Mulholland
Ranch Hand
Posts: 65
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ignore that. It's back.
 
Mark Spritzler
ranger
Sheriff
Posts: 17276
6
IntelliJ IDE Mac Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Eclipse is known for giving false negatives.

So if it works at runtime, then it works regardless of what Eclipse tells you.

If you have the Spring plugins, then when you are editing the xml file, at the bottom just below the file are tabs. There is one for namespaces. You can always go into that tab, it will give you checkboxes for Spring namespaces and you can uncheck the ones you have already, then recheck them and the Spring plugin will format the header part of your config file. That sometimes removes the Eclipse false errors.

I find that sometimes it just doesn't like the carriage returns in the schemaLocation prop.

Mark
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic