activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbono...@apache.org
Subject [activemq] branch activemq-5.15.x updated: [AMQ-6899] Use generic spring schema name (working with any Spring version) in RuntimeConfigurationPlugin
Date Wed, 02 Dec 2020 16:28:34 GMT
This is an automated email from the ASF dual-hosted git repository.

jbonofre pushed a commit to branch activemq-5.15.x
in repository https://gitbox.apache.org/repos/asf/activemq.git


The following commit(s) were added to refs/heads/activemq-5.15.x by this push:
     new 247836a  [AMQ-6899] Use generic spring schema name (working with any Spring version)
in RuntimeConfigurationPlugin
247836a is described below

commit 247836a4f70af5d4b8f770cf81a77647775000b3
Author: jbonofre <jbonofre@apache.org>
AuthorDate: Wed Dec 2 11:25:23 2020 +0100

    [AMQ-6899] Use generic spring schema name (working with any Spring version) in RuntimeConfigurationPlugin
    
    (cherry picked from commit c83f7e9aa8fa23b6ce86b5ee48969836d8b3e5d0)
---
 .../java/org/apache/activemq/plugin/RuntimeConfigurationBroker.java | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/activemq-runtime-config/src/main/java/org/apache/activemq/plugin/RuntimeConfigurationBroker.java
b/activemq-runtime-config/src/main/java/org/apache/activemq/plugin/RuntimeConfigurationBroker.java
index 7a06c87..b2a78ec 100644
--- a/activemq-runtime-config/src/main/java/org/apache/activemq/plugin/RuntimeConfigurationBroker.java
+++ b/activemq-runtime-config/src/main/java/org/apache/activemq/plugin/RuntimeConfigurationBroker.java
@@ -230,7 +230,11 @@ public class RuntimeConfigurationBroker extends AbstractRuntimeConfigurationBrok
 
             ArrayList<StreamSource> schemas = new ArrayList<StreamSource>();
             schemas.add(new StreamSource(getClass().getResource("/activemq.xsd").toExternalForm()));
-            schemas.add(new StreamSource(getClass().getResource("/org/springframework/beans/factory/xml/spring-beans-3.0.xsd").toExternalForm()));
+            if (getClass().getResource("/org/springframework/beans/factory/xml/spring-beans-3.0.xsd")
!= null) {
+                schemas.add(new StreamSource(getClass().getResource("/org/springframework/beans/factory/xml/spring-beans-3.0.xsd").toExternalForm()));
+            } else {
+                schemas.add(new StreamSource(getClass().getResource("/org/springframework/beans/factory/xml/spring-beans.xsd").toExternalForm()));
+            }
             schema = schemaFactory.newSchema(schemas.toArray(new Source[]{}));
         }
         return schema;


Mime
View raw message