Remove spring.spel.ignore and spring.xml.ignore flags

This commit also removes ResourcePropertiesPersister which
was introduced in 5.3 specifically for spring.xml.ignore
flag and which is expected to be used only internally by
Spring Framework. DefaultPropertiesPersister should be used
instead.

Closes gh-29277
This commit is contained in:
Sébastien Deleuze
2022-10-10 09:13:38 +02:00
parent bca35dc0a2
commit 42c3ac64ff
19 changed files with 85 additions and 300 deletions

View File

@@ -28,7 +28,6 @@ import org.apache.commons.logging.LogFactory;
import org.springframework.beans.BeansException;
import org.springframework.beans.factory.support.DefaultListableBeanFactory;
import org.springframework.beans.factory.xml.XmlBeanDefinitionReader;
import org.springframework.core.SpringProperties;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;
import org.springframework.lang.Nullable;
@@ -67,13 +66,6 @@ public class SQLErrorCodesFactory {
private static final Log logger = LogFactory.getLog(SQLErrorCodesFactory.class);
/**
* Boolean flag controlled by a {@code spring.xml.ignore} system property that instructs Spring to
* ignore XML, i.e. to not initialize the XML-related infrastructure.
* <p>The default is "false".
*/
private static final boolean shouldIgnoreXml = SpringProperties.getFlag("spring.xml.ignore");
/**
* Keep track of a single instance so we can return it to classes that request it.
*/
@@ -109,9 +101,6 @@ public class SQLErrorCodesFactory {
* @see #loadResource(String)
*/
protected SQLErrorCodesFactory() {
if (shouldIgnoreXml) {
throw new UnsupportedOperationException("XML support disabled");
}
Map<String, SQLErrorCodes> errorCodes;