Use the "versionless" XSDs, please.

From: https://stackoverflow.com/questions/20894695/spring-configuration-xml-schema-with-or-without-version/20900801#20900801

It is recommended to use the "versionless" XSDs, because they're mapped to the current version of the framework you're using in your application.

Applications and tools should never try to fetch those XSDs from the web, since those schemas are included in the JARs. If they do, it usually means your app is trying to use a XSD that is more recent than the framework version you're using, or that your IDE/tool is not properly configured.

Anyway the Spring team should drop the versioned schemas for Spring 5.0, see SPR-13499.

another post:

Consider using versionless xsd's. This will make the tooling pick up the version of the xsd matching the version of the spring jar you are using(look at the spring.schemas file in your jar). In case of any incompatibility when you upgrade your spring libraries(which should really be rare) you should be able to catch it during build.

猜你喜欢

转载自blog.csdn.net/wwwpcstarcomcn/article/details/82181285