Merge branch '5.1.x'
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2002-2018 the original author or authors.
|
* Copyright 2002-2019 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
@@ -372,8 +372,9 @@ public class PathMatchingResourcePatternResolver implements ResourcePatternResol
|
|||||||
try {
|
try {
|
||||||
for (URL url : ((URLClassLoader) classLoader).getURLs()) {
|
for (URL url : ((URLClassLoader) classLoader).getURLs()) {
|
||||||
try {
|
try {
|
||||||
UrlResource jarResource = new UrlResource(
|
UrlResource jarResource = (ResourceUtils.URL_PROTOCOL_JAR.equals(url.getProtocol()) ?
|
||||||
ResourceUtils.JAR_URL_PREFIX + url + ResourceUtils.JAR_URL_SEPARATOR);
|
new UrlResource(url) :
|
||||||
|
new UrlResource(ResourceUtils.JAR_URL_PREFIX + url + ResourceUtils.JAR_URL_SEPARATOR));
|
||||||
if (jarResource.exists()) {
|
if (jarResource.exists()) {
|
||||||
result.add(jarResource);
|
result.add(jarResource);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2002-2018 the original author or authors.
|
* Copyright 2002-2019 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
@@ -418,6 +418,9 @@ public abstract class JdbcUtils {
|
|||||||
if (source != null && source.startsWith("DB2")) {
|
if (source != null && source.startsWith("DB2")) {
|
||||||
name = "DB2";
|
name = "DB2";
|
||||||
}
|
}
|
||||||
|
else if ("MariaDB".equals(source)) {
|
||||||
|
name = "MySQL";
|
||||||
|
}
|
||||||
else if ("Sybase SQL Server".equals(source) ||
|
else if ("Sybase SQL Server".equals(source) ||
|
||||||
"Adaptive Server Enterprise".equals(source) ||
|
"Adaptive Server Enterprise".equals(source) ||
|
||||||
"ASE".equals(source) ||
|
"ASE".equals(source) ||
|
||||||
|
|||||||
@@ -186,6 +186,12 @@
|
|||||||
</bean>
|
</bean>
|
||||||
|
|
||||||
<bean id="MySQL" class="org.springframework.jdbc.support.SQLErrorCodes">
|
<bean id="MySQL" class="org.springframework.jdbc.support.SQLErrorCodes">
|
||||||
|
<property name="databaseProductNames">
|
||||||
|
<list>
|
||||||
|
<value>MySQL</value>
|
||||||
|
<value>MariaDB</value>
|
||||||
|
</list>
|
||||||
|
</property>
|
||||||
<property name="badSqlGrammarCodes">
|
<property name="badSqlGrammarCodes">
|
||||||
<value>1054,1064,1146</value>
|
<value>1054,1064,1146</value>
|
||||||
</property>
|
</property>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2002-2018 the original author or authors.
|
* Copyright 2002-2019 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
@@ -115,6 +115,7 @@ public final class SpringBeanContainer implements BeanContainer {
|
|||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
public <B> ContainedBean<B> getBean(
|
public <B> ContainedBean<B> getBean(
|
||||||
String name, Class<B> beanType, LifecycleOptions lifecycleOptions, BeanInstanceProducer fallbackProducer) {
|
String name, Class<B> beanType, LifecycleOptions lifecycleOptions, BeanInstanceProducer fallbackProducer) {
|
||||||
|
|
||||||
SpringContainedBean<?> bean;
|
SpringContainedBean<?> bean;
|
||||||
if (lifecycleOptions.canUseCachedReferences()) {
|
if (lifecycleOptions.canUseCachedReferences()) {
|
||||||
bean = this.beanCache.get(name);
|
bean = this.beanCache.get(name);
|
||||||
|
|||||||
Reference in New Issue
Block a user