You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@synapse.apache.org by ru...@apache.org on 2010/05/15 15:14:49 UTC

svn commit: r944636 - in /synapse/trunk/java/modules/migrator: ./ pom.xml src/ src/main/ src/main/resources/ src/main/resources/synapse-configuration-migrator.xslt

Author: ruwan
Date: Sat May 15 13:14:49 2010
New Revision: 944636

URL: http://svn.apache.org/viewvc?rev=944636&view=rev
Log:
migration XSLT (for the moment it is an identity transformation, which will be modified over the time with the changes to the configuration)

Added:
    synapse/trunk/java/modules/migrator/
    synapse/trunk/java/modules/migrator/pom.xml
    synapse/trunk/java/modules/migrator/src/
    synapse/trunk/java/modules/migrator/src/main/
    synapse/trunk/java/modules/migrator/src/main/resources/
    synapse/trunk/java/modules/migrator/src/main/resources/synapse-configuration-migrator.xslt

Added: synapse/trunk/java/modules/migrator/pom.xml
URL: http://svn.apache.org/viewvc/synapse/trunk/java/modules/migrator/pom.xml?rev=944636&view=auto
==============================================================================
--- synapse/trunk/java/modules/migrator/pom.xml (added)
+++ synapse/trunk/java/modules/migrator/pom.xml Sat May 15 13:14:49 2010
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~  Licensed to the Apache Software Foundation (ASF) under one
+  ~  or more contributor license agreements.  See the NOTICE file
+  ~  distributed with this work for additional information
+  ~  regarding copyright ownership.  The ASF licenses this file
+  ~  to you under the Apache License, Version 2.0 (the
+  ~  "License"); you may not use this file except in compliance
+  ~  with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~  Unless required by applicable law or agreed to in writing,
+  ~  software distributed under the License is distributed on an
+  ~   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~  KIND, either express or implied.  See the License for the
+  ~  specific language governing permissions and limitations
+  ~  under the License.
+  -->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <groupId>org.apache.synapse</groupId>
+        <artifactId>Apache-Synapse</artifactId>
+        <version>2.0.0-SNAPSHOT</version>
+        <relativePath>../../pom.xml</relativePath>
+    </parent>
+
+    <groupId>org.apache.synapse</groupId>
+    <artifactId>synapse-config-migrator</artifactId>
+    <packaging>bundle</packaging>
+    <name>Apache Synapse - Configuration Migrator</name>
+    <description>
+        Apache Synapse - Configuration migrator to migrate the 1.x configuration into a 2.x
+        compatible version
+    </description>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <version>1.4.0</version>
+                <extensions>true</extensions>
+                <configuration>
+                    <instructions>
+                        <Export-Package>
+                            org.apache.synapse.migrator.*,
+                        </Export-Package>
+                        <Import-Package>
+                            !javax.xml.namespace,
+                            javax.xml.namespace; version=0.0.0,
+                            *;resolution:=optional,
+                        </Import-Package>
+                        <DynamicImport-Package>*</DynamicImport-Package>
+                    </instructions>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.apache.synapse</groupId>
+            <artifactId>synapse-core</artifactId>
+        </dependency>
+    </dependencies>
+
+</project>

Added: synapse/trunk/java/modules/migrator/src/main/resources/synapse-configuration-migrator.xslt
URL: http://svn.apache.org/viewvc/synapse/trunk/java/modules/migrator/src/main/resources/synapse-configuration-migrator.xslt?rev=944636&view=auto
==============================================================================
--- synapse/trunk/java/modules/migrator/src/main/resources/synapse-configuration-migrator.xslt (added)
+++ synapse/trunk/java/modules/migrator/src/main/resources/synapse-configuration-migrator.xslt Sat May 15 13:14:49 2010
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+  ~  Licensed to the Apache Software Foundation (ASF) under one
+  ~  or more contributor license agreements.  See the NOTICE file
+  ~  distributed with this work for additional information
+  ~  regarding copyright ownership.  The ASF licenses this file
+  ~  to you under the Apache License, Version 2.0 (the
+  ~  "License"); you may not use this file except in compliance
+  ~  with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~  Unless required by applicable law or agreed to in writing,
+  ~  software distributed under the License is distributed on an
+  ~   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~  KIND, either express or implied.  See the License for the
+  ~  specific language governing permissions and limitations
+  ~  under the License.
+  -->
+
+<!--
+This is the synapse migration xslt which will migrate the configuration from the 1.x version to the 2.x compatible version 
+-->
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+
+  <xsl:template match="/ | @* | node() | text() | processing-instruction()">
+         <xsl:copy>
+               <xsl:apply-templates select="@* | node()" />
+         </xsl:copy>
+   </xsl:template>
+
+   <xsl:template match="comment()" xml:space="preserve">
+       <xsl:copy>
+               <xsl:apply-templates select="@* | node()" />
+         </xsl:copy>
+   </xsl:template>
+
+</xsl:stylesheet>