Organizational Research By

Surprising Reserch Topic

spring serving static content with mvcresources invalid xsd

spring serving static content with mvcresources invalid xsd  using -'spring,spring-mvc'

As recommended by I wish to use <mvc:resources> for serving my spring static content.

I have tried the following XML, but the .xsd file doesn't contain a declaration for <mvc:resources> and I cannot find an alternative .xsd. I can ignore the eclipse error, but the server won't start because of a SAXParseException.

Where have I gone wrong?

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns=""

    <mvc:resources mapping="/css/**" location="/css/"/>



asked Sep 14, 2015 by YolandaVTMrt
0 votes

Related Hot Questions

2 Answers

0 votes

Attributes in were added in Spring 3.0.4.

EDIT That is: you just add Spring 3.0.4 to your dependencies and everything works fine (except error marks in Eclipse plugin). At runtime config files are parsed by Spring itself, therefore Spring's built-in XSD file is used.

answered Sep 14, 2015 by Ian54Lznuitq
0 votes

Not better than axtavt's response, but a little clue on how to suppress Eclipse error. Go into the Project properties and then Spring‚ÜíBeans Support‚ÜíLoad NamespaceHandlers and XSDs from project's classpath [experimental]: Eclipse Spring Project Properties Screenshot

answered Sep 14, 2015 by Rod35O