cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aadamc...@apache.org
Subject [5/9] cayenne git commit: CAY-2118 cdbimport: drop support for the old style of table filtering
Date Fri, 30 Sep 2016 14:23:51 GMT
CAY-2118 cdbimport: drop support for the old style of table filtering

* ant task...


Project: http://git-wip-us.apache.org/repos/asf/cayenne/repo
Commit: http://git-wip-us.apache.org/repos/asf/cayenne/commit/2ba43b06
Tree: http://git-wip-us.apache.org/repos/asf/cayenne/tree/2ba43b06
Diff: http://git-wip-us.apache.org/repos/asf/cayenne/diff/2ba43b06

Branch: refs/heads/master
Commit: 2ba43b064ed3fd0e6d7b058014bbd474ec5ca53a
Parents: a98f0a0
Author: Andrus Adamchik <andrus@objectstyle.com>
Authored: Fri Sep 30 13:51:20 2016 +0300
Committer: Andrus Adamchik <andrus@objectstyle.com>
Committed: Fri Sep 30 14:54:38 2016 +0300

----------------------------------------------------------------------
 .../cayenne/dbimport/ReverseEngineering.java    | 15 ++--
 .../apache/cayenne/tools/DbImporterTask.java    | 73 ++++++++++++++----
 .../tools/dbimport/DbImportConfiguration.java   | 13 ----
 .../cayenne/tools/build-catalog-and-schema.xml  | 16 ++--
 .../org/apache/cayenne/tools/build-catalog.xml  | 17 ++---
 .../org/apache/cayenne/tools/build-flat.xml     | 18 ++---
 .../org/apache/cayenne/tools/build-mapping.xml  | 12 +--
 .../org/apache/cayenne/tools/build-schema.xml   | 80 ++++++++++----------
 .../tools/build-skip-primary-key-loading.xml    |  7 +-
 .../tools/build-skip-relationships-loading.xml  |  6 +-
 .../apache/cayenne/tools/build-table-types.xml  |  6 +-
 .../tools/dbimport/build-include-table.xml      |  3 +-
 12 files changed, 148 insertions(+), 118 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-server/src/main/java/org/apache/cayenne/dbimport/ReverseEngineering.java
----------------------------------------------------------------------
diff --git a/cayenne-server/src/main/java/org/apache/cayenne/dbimport/ReverseEngineering.java
b/cayenne-server/src/main/java/org/apache/cayenne/dbimport/ReverseEngineering.java
index 06528bf..2d74d85 100644
--- a/cayenne-server/src/main/java/org/apache/cayenne/dbimport/ReverseEngineering.java
+++ b/cayenne-server/src/main/java/org/apache/cayenne/dbimport/ReverseEngineering.java
@@ -23,12 +23,15 @@ import org.apache.cayenne.configuration.ConfigurationNode;
 import org.apache.cayenne.configuration.ConfigurationNodeVisitor;
 import org.apache.cayenne.resource.Resource;
 import org.apache.cayenne.util.XMLEncoder;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
 
-import javax.xml.bind.annotation.*;
-import java.io.*;
-import java.util.*;
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlTransient;
+import java.io.Serializable;
+import java.util.Collection;
+import java.util.LinkedList;
 
 /**
  * @since 4.0.
@@ -37,8 +40,6 @@ import java.util.*;
 @XmlAccessorType(XmlAccessType.FIELD)
 public class ReverseEngineering extends FilterContainer implements ConfigurationNode, Serializable
{
 
-    private static final Log LOG = LogFactory.getLog(ReverseEngineering.class);
-
     @XmlTransient
     protected Resource configurationSource;
     @XmlTransient

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/main/java/org/apache/cayenne/tools/DbImporterTask.java
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/main/java/org/apache/cayenne/tools/DbImporterTask.java b/cayenne-tools/src/main/java/org/apache/cayenne/tools/DbImporterTask.java
index ea95110..5954b9f 100644
--- a/cayenne-tools/src/main/java/org/apache/cayenne/tools/DbImporterTask.java
+++ b/cayenne-tools/src/main/java/org/apache/cayenne/tools/DbImporterTask.java
@@ -25,8 +25,16 @@ import org.apache.cayenne.configuration.server.DataSourceFactory;
 import org.apache.cayenne.configuration.server.DbAdapterFactory;
 import org.apache.cayenne.conn.DataSourceInfo;
 import org.apache.cayenne.dba.DbAdapter;
+import org.apache.cayenne.dbimport.Catalog;
 import org.apache.cayenne.dbimport.DefaultReverseEngineeringLoader;
+import org.apache.cayenne.dbimport.ExcludeColumn;
+import org.apache.cayenne.dbimport.ExcludeProcedure;
+import org.apache.cayenne.dbimport.ExcludeTable;
+import org.apache.cayenne.dbimport.IncludeColumn;
+import org.apache.cayenne.dbimport.IncludeProcedure;
+import org.apache.cayenne.dbimport.IncludeTable;
 import org.apache.cayenne.dbimport.ReverseEngineering;
+import org.apache.cayenne.dbimport.Schema;
 import org.apache.cayenne.dbsync.CayenneDbSyncModule;
 import org.apache.cayenne.dbsync.reverse.FiltersConfigBuilder;
 import org.apache.cayenne.di.DIBootstrap;
@@ -53,19 +61,65 @@ import java.net.URL;
 public class DbImporterTask extends Task {
 
     private final DbImportConfiguration config;
-    private final ReverseEngineering reverseEngineering = new ReverseEngineering();
-
+    private ReverseEngineering reverseEngineering;
     private boolean isReverseEngineeringDefined;
 
     public DbImporterTask() {
-        config = new DbImportConfiguration();
-        config.setOverwrite(true);
-        config.setUsePrimitives(true);
-        config.setNamingStrategy(DefaultNameGenerator.class.getName());
+        this.config = new DbImportConfiguration();
+        this.config.setUsePrimitives(true);
+        this.config.setNamingStrategy(DefaultNameGenerator.class.getName());
+
+        // reverse engineering config is flattened into task...
+        this.reverseEngineering = new ReverseEngineering();
+    }
+
+    public void addIncludeColumn(IncludeColumn includeColumn) {
+        reverseEngineering.addIncludeColumn(includeColumn);
+    }
+
+    public void addExcludeColumn(ExcludeColumn excludeColumn) {
+        reverseEngineering.addExcludeColumn(excludeColumn);
+    }
+
+    public void addIncludeTable(IncludeTable includeTable) {
+        reverseEngineering.addIncludeTable(includeTable);
+    }
+
+    public void addExcludeTable(ExcludeTable excludeTable) {
+        reverseEngineering.addExcludeTable(excludeTable);
+    }
+
+    public void addIncludeProcedure(IncludeProcedure includeProcedure) {
+        reverseEngineering.addIncludeProcedure(includeProcedure);
+    }
+
+    public void addExcludeProcedure(ExcludeProcedure excludeProcedure) {
+        reverseEngineering.addExcludeProcedure(excludeProcedure);
+    }
+
+    public void addSkipRelationshipsLoading(boolean skipRelationshipsLoading) {
+        reverseEngineering.setSkipRelationshipsLoading(skipRelationshipsLoading);
+    }
+
+    public void addSkipPrimaryKeyLoading(boolean skipPrimaryKeyLoading) {
+        reverseEngineering.setSkipPrimaryKeyLoading(skipPrimaryKeyLoading);
+    }
+
+    public void addTableType(String type) {
+        reverseEngineering.addTableType(type);
+    }
+
+    public void addConfiguredSchema(Schema schema) {
+        reverseEngineering.addSchema(schema);
+    }
+
+    public void addCatalog(Catalog catalog) {
+        reverseEngineering.addCatalog(catalog);
     }
 
     @Override
     public void execute() {
+
         File dataMapFile = config.getDataMapFile();
         config.setFiltersConfig(new FiltersConfigBuilder(reverseEngineering).build());
 
@@ -196,13 +250,6 @@ public class DbImporterTask extends Task {
     /**
      * @since 4.0
      */
-    public void setOverwrite(boolean overwrite) {
-        config.setOverwrite(overwrite);
-    }
-
-    /**
-     * @since 4.0
-     */
     public void setDefaultPackage(String defaultPackage) {
         config.setDefaultPackage(defaultPackage);
     }

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/main/java/org/apache/cayenne/tools/dbimport/DbImportConfiguration.java
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/main/java/org/apache/cayenne/tools/dbimport/DbImportConfiguration.java
b/cayenne-tools/src/main/java/org/apache/cayenne/tools/dbimport/DbImportConfiguration.java
index ea0f6c7..2e2bd21 100644
--- a/cayenne-tools/src/main/java/org/apache/cayenne/tools/dbimport/DbImportConfiguration.java
+++ b/cayenne-tools/src/main/java/org/apache/cayenne/tools/dbimport/DbImportConfiguration.java
@@ -70,11 +70,6 @@ public class DbImportConfiguration {
      * A default package for ObjEntity Java classes.
      */
     private String defaultPackage;
-    /**
-     * Indicates that the old mapping should be completely removed and replaced
-     * with the new data based on reverse engineering.
-     */
-    private boolean overwrite;
     private String meaningfulPkTables;
     /**
      * Java class implementing org.apache.cayenne.dba.DbAdapter. This attribute
@@ -109,14 +104,6 @@ public class DbImportConfiguration {
         this.defaultPackage = defaultPackage;
     }
 
-    public boolean isOverwrite() {
-        return overwrite;
-    }
-
-    public void setOverwrite(boolean overwrite) {
-        this.overwrite = overwrite;
-    }
-
     public String getNamingStrategy() {
         return dbLoaderConfiguration.getNamingStrategy();
     }

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog-and-schema.xml
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog-and-schema.xml
b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog-and-schema.xml
index 64ee1bc..ee44b9c 100644
--- a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog-and-schema.xml
+++ b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog-and-schema.xml
@@ -20,7 +20,7 @@
 <project name="MyProject" default="dist" basedir=".">
 
     <taskdef name="cdbimport" classname="org.apache.cayenne.tools.DbImporterTask" taskname="cdbimport"
-             classpath="${basedir}"  />
+             classpath="${basedir}"/>
 
     <target name="dist">
         <cdbimport map="${context.dir}/WEB-INF/DefaultMap.map.xml"
@@ -38,37 +38,37 @@
                     </includeTable>
 
                     <includeTable pattern="includeTable-03">
-                        <includeColumn pattern="includeColumn-01" />
-                        <excludeColumn pattern="excludeColumn-01" />
+                        <includeColumn pattern="includeColumn-01"/>
+                        <excludeColumn pattern="excludeColumn-01"/>
                     </includeTable>
 
                     <excludeTable>excludeTable-01</excludeTable>
                     <excludeTable>
                         <pattern>excludeTable-02</pattern>
                     </excludeTable>
-                    <excludeTable pattern="excludeTable-03" />
+                    <excludeTable pattern="excludeTable-03"/>
 
                     <includeColumn>includeColumn-01</includeColumn>
                     <includeColumn>
                         <pattern>includeColumn-02</pattern>
                     </includeColumn>
-                    <includeColumn pattern="includeColumn-03" />
+                    <includeColumn pattern="includeColumn-03"/>
                     <excludeColumn>excludeColumn-01</excludeColumn>
                     <excludeColumn>
                         <pattern>excludeColumn-02</pattern>
                     </excludeColumn>
-                    <excludeColumn pattern="excludeColumn-03" />
+                    <excludeColumn pattern="excludeColumn-03"/>
 
                     <includeProcedure>includeProcedure-01</includeProcedure>
                     <includeProcedure>
                         <pattern>includeProcedure-02</pattern>
                     </includeProcedure>
-                    <includeProcedure pattern="includeProcedure-03" />
+                    <includeProcedure pattern="includeProcedure-03"/>
                     <excludeProcedure>excludeProcedure-01</excludeProcedure>
                     <excludeProcedure>
                         <pattern>excludeProcedure-02</pattern>
                     </excludeProcedure>
-                    <excludeProcedure pattern="excludeProcedure-03" />
+                    <excludeProcedure pattern="excludeProcedure-03"/>
                 </schema>
             </catalog>
         </cdbimport>

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog.xml
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog.xml b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog.xml
index 32d7c7a..fa1781b 100644
--- a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog.xml
+++ b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-catalog.xml
@@ -20,7 +20,7 @@
 <project name="MyProject" default="dist" basedir=".">
 
     <taskdef name="cdbimport" classname="org.apache.cayenne.tools.DbImporterTask" taskname="cdbimport"
-             classpath="${basedir}"  />
+             classpath="${basedir}"/>
 
     <target name="dist">
         <cdbimport map="${context.dir}/WEB-INF/DefaultMap.map.xml"
@@ -43,39 +43,38 @@
                 </includeTable>
 
                 <includeTable pattern="includeTable-03">
-                    <includeColumn pattern="includeColumn-01" />
-                    <excludeColumn pattern="excludeColumn-01" />
+                    <includeColumn pattern="includeColumn-01"/>
+                    <excludeColumn pattern="excludeColumn-01"/>
                 </includeTable>
 
                 <excludeTable>excludeTable-01</excludeTable>
                 <excludeTable>
                     <pattern>excludeTable-02</pattern>
                 </excludeTable>
-                <excludeTable pattern="excludeTable-03" />
+                <excludeTable pattern="excludeTable-03"/>
 
                 <includeColumn>includeColumn-01</includeColumn>
                 <includeColumn>
                     <pattern>includeColumn-02</pattern>
                 </includeColumn>
-                <includeColumn pattern="includeColumn-03" />
+                <includeColumn pattern="includeColumn-03"/>
                 <excludeColumn>excludeColumn-01</excludeColumn>
                 <excludeColumn>
                     <pattern>excludeColumn-02</pattern>
                 </excludeColumn>
-                <excludeColumn pattern="excludeColumn-03" />
+                <excludeColumn pattern="excludeColumn-03"/>
 
                 <includeProcedure>includeProcedure-01</includeProcedure>
                 <includeProcedure>
                     <pattern>includeProcedure-02</pattern>
                 </includeProcedure>
-                <includeProcedure pattern="includeProcedure-03" />
+                <includeProcedure pattern="includeProcedure-03"/>
                 <excludeProcedure>excludeProcedure-01</excludeProcedure>
                 <excludeProcedure>
                     <pattern>excludeProcedure-02</pattern>
                 </excludeProcedure>
-                <excludeProcedure pattern="excludeProcedure-03" />
+                <excludeProcedure pattern="excludeProcedure-03"/>
             </catalog>
-
         </cdbimport>
     </target>
 

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-flat.xml
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-flat.xml b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-flat.xml
index 29f9e72..286bcf3 100644
--- a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-flat.xml
+++ b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-flat.xml
@@ -20,7 +20,7 @@
 <project name="MyProject" default="dist" basedir=".">
 
     <taskdef name="cdbimport" classname="org.apache.cayenne.tools.DbImporterTask" taskname="cdbimport"
-             classpath="${basedir}"  />
+             classpath="${basedir}"/>
 
     <target name="dist">
         <cdbimport map="${context.dir}/WEB-INF/DefaultMap.map.xml"
@@ -28,7 +28,6 @@
                    driver="org.hsqldb.jdbcDriver"
                    url="jdbc:hsqldb:hsql://localhost/bookmarker"
                    username="sa">
-
             <includeTable>includeTable-01</includeTable>
 
             <includeTable>
@@ -36,38 +35,37 @@
             </includeTable>
 
             <includeTable pattern="includeTable-03">
-                <includeColumn pattern="includeColumn-01" />
-                <excludeColumn pattern="excludeColumn-01" />
+                <includeColumn pattern="includeColumn-01"/>
+                <excludeColumn pattern="excludeColumn-01"/>
             </includeTable>
 
             <excludeTable>excludeTable-01</excludeTable>
             <excludeTable>
                 <pattern>excludeTable-02</pattern>
             </excludeTable>
-            <excludeTable pattern="excludeTable-03" />
+            <excludeTable pattern="excludeTable-03"/>
 
             <includeColumn>includeColumn-01</includeColumn>
             <includeColumn>
                 <pattern>includeColumn-02</pattern>
             </includeColumn>
-            <includeColumn pattern="includeColumn-03" />
+            <includeColumn pattern="includeColumn-03"/>
             <excludeColumn>excludeColumn-01</excludeColumn>
             <excludeColumn>
                 <pattern>excludeColumn-02</pattern>
             </excludeColumn>
-            <excludeColumn pattern="excludeColumn-03" />
+            <excludeColumn pattern="excludeColumn-03"/>
 
             <includeProcedure>includeProcedure-01</includeProcedure>
             <includeProcedure>
                 <pattern>includeProcedure-02</pattern>
             </includeProcedure>
-            <includeProcedure pattern="includeProcedure-03" />
+            <includeProcedure pattern="includeProcedure-03"/>
             <excludeProcedure>excludeProcedure-01</excludeProcedure>
             <excludeProcedure>
                 <pattern>excludeProcedure-02</pattern>
             </excludeProcedure>
-            <excludeProcedure pattern="excludeProcedure-03" />
-
+            <excludeProcedure pattern="excludeProcedure-03"/>
         </cdbimport>
     </target>
 

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-mapping.xml
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-mapping.xml b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-mapping.xml
index 90d6116..b6ab93e 100644
--- a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-mapping.xml
+++ b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-mapping.xml
@@ -20,7 +20,7 @@
 <project name="MyProject" default="dist" basedir=".">
 
     <taskdef name="cdbimport" classname="org.apache.cayenne.tools.DbImporterTask" taskname="cdbimport"
-             classpath="${basedir}"  />
+             classpath="${basedir}"/>
 
     <target name="dist">
         <cdbimport map="${context.dir}/WEB-INF/DefaultMap.map.xml"
@@ -30,11 +30,11 @@
                    username="sa">
 
             <typeMapper mapperClassName="class" usePrimitives="false">
-                <type java="my.personal.type" jdbc="varchar" />
-                <type java="java-01" jdbc="jdbc-01" />
-                <type java="java-02" jdbc="jdbc-02" length="21" notNull="true" />
-                <type java="java-03" jdbc="jdbc-03" precision="5" scale="2" />
-                <type java="java-03" jdbc="jdbc-03" precision="7" notNull="true" />
+                <type java="my.personal.type" jdbc="varchar"/>
+                <type java="java-01" jdbc="jdbc-01"/>
+                <type java="java-02" jdbc="jdbc-02" length="21" notNull="true"/>
+                <type java="java-03" jdbc="jdbc-03" precision="5" scale="2"/>
+                <type java="java-03" jdbc="jdbc-03" precision="7" notNull="true"/>
             </typeMapper>
 
         </cdbimport>

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-schema.xml
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-schema.xml b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-schema.xml
index 2d7bb6b..911af23 100644
--- a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-schema.xml
+++ b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-schema.xml
@@ -20,7 +20,7 @@
 <project name="MyProject" default="dist" basedir=".">
 
     <taskdef name="cdbimport" classname="org.apache.cayenne.tools.DbImporterTask" taskname="cdbimport"
-             classpath="${basedir}"  />
+             classpath="${basedir}"/>
 
     <target name="dist">
         <cdbimport map="${context.dir}/WEB-INF/DefaultMap.map.xml"
@@ -29,52 +29,52 @@
                    url="jdbc:hsqldb:hsql://localhost/bookmarker"
                    username="sa">
 
-            <schema>schema-name-01</schema>
+                <schema>schema-name-01</schema>
 
-            <schema>
-                <name>schema-name-02</name>
-            </schema>
+                <schema>
+                    <name>schema-name-02</name>
+                </schema>
 
-            <schema name="schema-name-03">
-                <includeTable>includeTable-01</includeTable>
+                <schema name="schema-name-03">
+                    <includeTable>includeTable-01</includeTable>
 
-                <includeTable>
-                    <pattern>includeTable-02</pattern>
-                </includeTable>
+                    <includeTable>
+                        <pattern>includeTable-02</pattern>
+                    </includeTable>
 
-                <includeTable pattern="includeTable-03">
-                    <includeColumn pattern="includeColumn-01" />
-                    <excludeColumn pattern="excludeColumn-01" />
-                </includeTable>
+                    <includeTable pattern="includeTable-03">
+                        <includeColumn pattern="includeColumn-01"/>
+                        <excludeColumn pattern="excludeColumn-01"/>
+                    </includeTable>
 
-                <excludeTable>excludeTable-01</excludeTable>
-                <excludeTable>
-                    <pattern>excludeTable-02</pattern>
-                </excludeTable>
-                <excludeTable pattern="excludeTable-03" />
+                    <excludeTable>excludeTable-01</excludeTable>
+                    <excludeTable>
+                        <pattern>excludeTable-02</pattern>
+                    </excludeTable>
+                    <excludeTable pattern="excludeTable-03"/>
 
-                <includeColumn>includeColumn-01</includeColumn>
-                <includeColumn>
-                    <pattern>includeColumn-02</pattern>
-                </includeColumn>
-                <includeColumn pattern="includeColumn-03" />
-                <excludeColumn>excludeColumn-01</excludeColumn>
-                <excludeColumn>
-                    <pattern>excludeColumn-02</pattern>
-                </excludeColumn>
-                <excludeColumn pattern="excludeColumn-03" />
+                    <includeColumn>includeColumn-01</includeColumn>
+                    <includeColumn>
+                        <pattern>includeColumn-02</pattern>
+                    </includeColumn>
+                    <includeColumn pattern="includeColumn-03"/>
+                    <excludeColumn>excludeColumn-01</excludeColumn>
+                    <excludeColumn>
+                        <pattern>excludeColumn-02</pattern>
+                    </excludeColumn>
+                    <excludeColumn pattern="excludeColumn-03"/>
 
-                <includeProcedure>includeProcedure-01</includeProcedure>
-                <includeProcedure>
-                    <pattern>includeProcedure-02</pattern>
-                </includeProcedure>
-                <includeProcedure pattern="includeProcedure-03" />
-                <excludeProcedure>excludeProcedure-01</excludeProcedure>
-                <excludeProcedure>
-                    <pattern>excludeProcedure-02</pattern>
-                </excludeProcedure>
-                <excludeProcedure pattern="excludeProcedure-03" />
-            </schema>
+                    <includeProcedure>includeProcedure-01</includeProcedure>
+                    <includeProcedure>
+                        <pattern>includeProcedure-02</pattern>
+                    </includeProcedure>
+                    <includeProcedure pattern="includeProcedure-03"/>
+                    <excludeProcedure>excludeProcedure-01</excludeProcedure>
+                    <excludeProcedure>
+                        <pattern>excludeProcedure-02</pattern>
+                    </excludeProcedure>
+                    <excludeProcedure pattern="excludeProcedure-03"/>
+                </schema>
 
         </cdbimport>
     </target>

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-primary-key-loading.xml
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-primary-key-loading.xml
b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-primary-key-loading.xml
index e438166..bd12051 100644
--- a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-primary-key-loading.xml
+++ b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-primary-key-loading.xml
@@ -20,16 +20,15 @@
 <project name="MyProject" default="dist" basedir=".">
 
     <taskdef name="cdbimport" classname="org.apache.cayenne.tools.DbImporterTask" taskname="cdbimport"
-             classpath="${basedir}"  />
+             classpath="${basedir}"/>
 
     <target name="dist">
         <cdbimport map="${context.dir}/WEB-INF/DefaultMap.map.xml"
                    adapter="org.apache.cayenne.dba.hsqldb.HSQLDBAdapter"
                    driver="org.hsqldb.jdbcDriver"
                    url="jdbc:hsqldb:hsql://localhost/bookmarker"
-                   username="sa"
-                   skipPrimaryKeyLoading="true">
-
+                   username="sa">
+            <skipPrimaryKeyLoading>true</skipPrimaryKeyLoading>
         </cdbimport>
     </target>
 

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-relationships-loading.xml
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-relationships-loading.xml
b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-relationships-loading.xml
index 1eb40a8..8a3ee50 100644
--- a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-relationships-loading.xml
+++ b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-skip-relationships-loading.xml
@@ -20,16 +20,16 @@
 <project name="MyProject" default="dist" basedir=".">
 
     <taskdef name="cdbimport" classname="org.apache.cayenne.tools.DbImporterTask" taskname="cdbimport"
-             classpath="${basedir}"  />
+             classpath="${basedir}"/>
 
     <target name="dist">
         <cdbimport map="${context.dir}/WEB-INF/DefaultMap.map.xml"
                    adapter="org.apache.cayenne.dba.hsqldb.HSQLDBAdapter"
                    driver="org.hsqldb.jdbcDriver"
                    url="jdbc:hsqldb:hsql://localhost/bookmarker"
-                   username="sa"
-                   skipRelationshipsLoading="true">
+                   username="sa">
 
+            <skipRelationshipsLoading>true</skipRelationshipsLoading>
         </cdbimport>
     </target>
 

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-table-types.xml
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-table-types.xml
b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-table-types.xml
index 6985520..25bf032 100644
--- a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-table-types.xml
+++ b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/build-table-types.xml
@@ -20,7 +20,7 @@
 <project name="MyProject" default="dist" basedir=".">
 
     <taskdef name="cdbimport" classname="org.apache.cayenne.tools.DbImporterTask" taskname="cdbimport"
-             classpath="${basedir}"  />
+             classpath="${basedir}"/>
 
     <target name="dist">
         <cdbimport map="${context.dir}/WEB-INF/DefaultMap.map.xml"
@@ -31,8 +31,8 @@
 
             <tableType>type1</tableType>
 
-            <tableType name="type2" />
-            <tableType name="type3" />
+            <tableType name="type2"/>
+            <tableType name="type3"/>
         </cdbimport>
     </target>
 

http://git-wip-us.apache.org/repos/asf/cayenne/blob/2ba43b06/cayenne-tools/src/test/resources/org/apache/cayenne/tools/dbimport/build-include-table.xml
----------------------------------------------------------------------
diff --git a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/dbimport/build-include-table.xml
b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/dbimport/build-include-table.xml
index 897869d..a100fcd 100644
--- a/cayenne-tools/src/test/resources/org/apache/cayenne/tools/dbimport/build-include-table.xml
+++ b/cayenne-tools/src/test/resources/org/apache/cayenne/tools/dbimport/build-include-table.xml
@@ -20,13 +20,12 @@
 <project name="MyProject" default="dist" basedir="../">
 
     <taskdef name="cdbimport" classname="org.apache.cayenne.tools.DbImporterTask" taskname="cdbimport"
-             classpath="${basedir}"  />
+             classpath="${basedir}"/>
 
     <target name="dist">
         <cdbimport map="dbimport/build-include-table.map.xml"
                    driver="org.apache.derby.jdbc.EmbeddedDriver"
                    url="jdbc:derby:memory:DbImporterMojoTest;create=true">
-
             <includeTable>Parent</includeTable>
         </cdbimport>
     </target>


Mime
View raw message