Spring Beans validation error Schema inside application context

after setting up a new Spring-based application, I ran into a problem with a link to the schema (http://www.springframework.org/schema/beans/spring-beans- 3.0.xsd) in the application context.

appContext.xml

<?xml version="1.0" encoding="UTF-8"?> <beans:beans 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"> .... </beans:beans> 

Error

 Referenced file contains errors (http://www.springframework.org/schema/beans/spring-beans-3.0.xsd). 

Even if I reduce the configuration to the minimum version (without defining a bean), I get this error. Does anyone know what's wrong here? Thanks in advance!

Btw: I am using STS 2.7.1

+6
source share
4 answers

You may have had an error that is no longer there, but the error message is displayed in the cache. Perhaps this error appeared due to the fact that 2.5 xsd and 3.0 xsd were installed in your applicationContext.xml application. You should be able to get information about this error by right-clicking on it (especially not detailed details ...).

Try to clear the error message and retry checking with this minimal file.

+17
source

In MyEclipseBlue go to Settings> My Eclipse-> Internet Tools-> Cache and delete files

+5
source

In Eclipse / STS, go to "Settings" → "General" → "Network Connections" and delete the offensive files.

+2
source

Copy everything inside the tag. Then delete everything except the first line and save the file. Paste what you copied and save again (make sure you have an Internet connection to be safe). Save the file again

0
source

Source: https://habr.com/ru/post/896383/


All Articles