This is an automated email from the ASF dual-hosted git repository.

gk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/turbine-archetypes.git


The following commit(s) were added to refs/heads/master by this push:
     new c3527b6  - Update to Torque 5.0, Turbine 5.1-SNAPSHOT, update om and 
schema. - Add ide integrationtest maven goals, renamed README to md format
c3527b6 is described below

commit c3527b6908976d3d906a81431c12f7a077d48a23
Author: Georg Kallidis <[email protected]>
AuthorDate: Fri Oct 23 15:41:20 2020 +0200

    - Update to Torque 5.0, Turbine 5.1-SNAPSHOT, update om and schema. - Add 
ide integrationtest maven goals, renamed README to md format
---
 .project                                           | 27 ++++-----
 pom.xml                                            | 10 ++--
 .../docs/{README.txt => README.md}                 | 66 ++++++++++++++--------
 src/main/resources/archetype-resources/pom.xml     | 18 +++---
 .../src/main/java/om/TurbineRolePermission.java    |  2 +-
 .../src/main/torque-schema/application-schema.xml  |  6 +-
 .../src/main/torque-schema/id-table-schema.xml     |  6 +-
 .../main/torque-schema/torque-security-schema.xml  | 38 +++++++++----
 .../webapp/WEB-INF/conf/componentConfiguration.xml |  2 +-
 src/test/resources/projects/first/goal.txt         |  2 +-
 10 files changed, 103 insertions(+), 74 deletions(-)

diff --git a/.project b/.project
index 6271c1c..3342dbf 100644
--- a/.project
+++ b/.project
@@ -1,17 +1,14 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <projectDescription>
-       <name>turbine-archetypes</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.m2e.core.maven2Builder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.m2e.core.maven2Nature</nature>
-       </natures>
-</projectDescription>
+  <name>turbine-webapp-5.0</name>
+  <comment>This archetype sets up a web application project based on Apache 
Turbine 5.0. NO_M2ECLIPSE_SUPPORT: Project files created with the 
maven-eclipse-plugin are not supported in M2Eclipse.</comment>
+  <projects/>
+  <buildSpec>
+    <buildCommand>
+      <name>org.eclipse.m2e.core.maven2Builder</name>
+    </buildCommand>    
+  </buildSpec>
+  <natures>
+    <nature>org.eclipse.m2e.core.maven2Nature</nature>
+  </natures>
+</projectDescription>
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index 7e7d88e..19ed401 100644
--- a/pom.xml
+++ b/pom.xml
@@ -26,12 +26,12 @@
     <version>20</version><!-- like turbine parent -->
   </parent>
   <groupId>org.apache.turbine</groupId>
-  <artifactId>turbine-webapp-5.0</artifactId>
+  <artifactId>turbine-webapp-5.1</artifactId>
   <version>2.0.0-SNAPSHOT</version>
   <packaging>maven-archetype</packaging>
 
-  <name>Archetype - Turbine 5.0 WebApp</name>
-  <description>This archetype sets up a web application project based on 
Apache Turbine 5.0</description>
+  <name>Archetype - Turbine 5.1 WebApp</name>
+  <description>This archetype sets up a web application project based on 
Apache Turbine 5.1</description>
   <url>https://turbine.apache.org</url>
 
   <inceptionYear>2011</inceptionYear>
@@ -48,7 +48,7 @@
       <extension>
         <groupId>org.apache.maven.archetype</groupId>
         <artifactId>archetype-packaging</artifactId>
-        <version>3.0.1</version>
+        <version>3.2.0</version>
       </extension>
     </extensions>
 
@@ -56,7 +56,7 @@
       <plugins>
         <plugin>
           <artifactId>maven-archetype-plugin</artifactId>
-          <version>3.0.1</version>
+          <version>3.2.0</version>
            <!-- skip tests in generated archetype's pom, here the 
integration-test would be skipped -->
           <!--configuration>
             <skip>true</skip>
diff --git a/src/main/resources/archetype-resources/docs/README.txt 
b/src/main/resources/archetype-resources/docs/README.md
similarity index 84%
rename from src/main/resources/archetype-resources/docs/README.txt
rename to src/main/resources/archetype-resources/docs/README.md
index 9a527c2..7d9fc0b 100644
--- a/src/main/resources/archetype-resources/docs/README.txt
+++ b/src/main/resources/archetype-resources/docs/README.md
@@ -16,17 +16,17 @@ KIND, either express or implied. See the License for the
 specific language governing permissions and limitations
 under the License.
 *#
+ 
 
-Notice
+# Quick Guide to using the new Turbine 5.1 maven archetype for skeleton 
application generation
 
-About this archetype 
 
-Turbine Version: Turbine 5.0. 
 
-# Quick Guide to using the new Turbine 5.0 maven archetype 
-for skeleton application generation
+## About this archetype 
 
-## Local database Setup
+Turbine Version: Turbine 5.1.
+
+### Local database Setup
 
 First, you should have a local database installed and configured prior to 
 beginning the application setup below.
@@ -39,16 +39,17 @@ mysql> \q
 
 or other tools. The database should have been started and the database user 
granted enough rights.
 
-## Maven archetype 
+### Maven archetype 
 
 Next, you can invoke the Maven archetype for turbine-webapp-5.0 from 
 the command line as shown below - please update values starting 
 with 'groupId' as appropriate.
 
+```sh
 mvn archetype:generate \
   -DarchetypeGroupId=org.apache.turbine \
-  -DarchetypeArtifactId=turbine-webapp-5.0 \
-  -DarchetypeVersion=1.0.3-SNAPSHOT \
+  -DarchetypeArtifactId=turbine-webapp-5.1 \
+  -DarchetypeVersion=2.0.0-SNAPSHOT \
   -DgroupId=com.mycompany.webapp \
   -DartifactId=myhelloworld \
   -Dversion=1.0 \
@@ -60,14 +61,17 @@ mvn archetype:generate \
   -Dturbine_database_timezone=UTC \
   -Dturbine_database_url=jdbc:mysql://localhost:3306/ \
   -Dgoals=generate-sources,integration-test
+```
 
-### Digression
+### Development
 
 You may use 
 
+```sh
 mvn archetype:generate -DarchetypeCatalog=local
+```
 
-to avoid declaring the Darchetype* variables.
+to avoid declaring the *archetype* variables.
 
 This requires you provide a local catalog in $HOME\.m2\archetype-catalog.xml. 
Find further information here: 
https://maven.apache.org/archetype/archetype-models/archetype-catalog/archetype-catalog.html.
 
@@ -75,8 +79,8 @@ This requires you provide a local catalog in 
$HOME\.m2\archetype-catalog.xml. Fi
 <archetype-catalog ...>
  <archetype>
       <groupId>org.apache.turbine</groupId>
-      <artifactId>turbine-webapp-5.0</artifactId>
-      <version>1.0.3-SNAPSHOT</version>
+      <artifactId>turbine-webapp-5.1</artifactId>
+      <version>2.0.0-SNAPSHOT</version>
       <description>This archetype sets up a web application project based on 
Apache Turbine 5.0</description>
     </archetype>
   </archetypes>
@@ -105,28 +109,36 @@ the configuration.
 
 Next, change into the newly generated project folder, in our case
 
+```sh
 cd myhelloworld
+```
+
+Skip next two steps, if the build was successfull.
+
+```sh
+mvn generate-sources
+```
+This will generate the OM layer and SQL code for creating the corresponding 
database tables.
 
-Skip next two steps, if the build was successfull
-mvn generate-sources  ## This will generate the OM layer and SQL 
-          ## code for creating the corresponding
-          ## database tables
 
-mvn integration-test      ## This executes the SQL code to create 
-          ## the application schema defined 
-          ## in src/main/torque-schema
+```sh
+mvn integration-test
+```
+This executes the SQL code to create the application schema defined  in 
src/main/torque-schema.
 
 You should now check the database tables and if some data is missing
 insert the sample data file in sample-mysql-data (Torque 4.0 has disabled the 
datasql task).
 
+```sh
 mvn clean install 
+```
 
-If you get an error like "The driver has not received any packets" probably 
the database is not up and running or the port may be another one.
+If you get an error like *"The driver has not received any packets"* probably 
the database is not up and running or the port may be another one.
 
 Last step on the command line is run the server by invoking 
 mvn jetty:run         
 
-## Now you can launch your new Turbine application by default 
http://localhost:8081/app (check port in pom.xml, if needed).
+- Now you can launch your new Turbine application by default 
[http://localhost:8081/app] (check port in pom.xml, if needed).
 
 ### Logs 
 
@@ -134,7 +146,7 @@ Find the Logs in src/main/webapp/logs and
 
 ### Application
 
-Open a web browser to http://localhost:8081/app
+Open a web browser to [http://localhost:8081/app]
 
 Login should work with user admin/password or user/password.
 
@@ -159,17 +171,21 @@ If running from integration test, check/update
 The security test is by default skipped as it requires a running mysql. It 
tests many of the Fulcrum Torque Turbine security aspects, 
 activate it by calling
 
+```sh
 mvn test -DskipTests=false
+```
 
 CAVEAT: If initialization fails, double check your database credentials! If 
invalid the error might be somewhat hidden behind a
  Torque exception!
 
-## Eclipse
+## IDE Integration, Eclipse
 
 To enable application development in Eclipse, run the following command 
 and then import the project into Eclipse.
 
+```sh
 mvn eclipse:eclipse
+```
 
 Once imported, update your project to be managed by Maven 
 -> Right click on the project name
@@ -184,7 +200,9 @@ your eclipse environment.
 
 You even could debug the app by setting the environment variable to something 
like this
 
+```
 set MAVEN_OPTS=-Xdebug 
-Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n
+```
 
 before running the jetty server.
 
diff --git a/src/main/resources/archetype-resources/pom.xml 
b/src/main/resources/archetype-resources/pom.xml
index 0bbd5e6..5c831ea 100644
--- a/src/main/resources/archetype-resources/pom.xml
+++ b/src/main/resources/archetype-resources/pom.xml
@@ -369,8 +369,8 @@ under the License.
         <groupId>com.fasterxml.jackson.datatype</groupId>
         <artifactId>jackson-datatype-json-org</artifactId>
         <!-- version>$dollar{jackson.version}</version-->
-        <!--  2.7.x has Java 7 baseline, but not compiled with Java 6 support 
(version 51 error:), cft. 
https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.7 Changes: 
compatibility: ..  should still be possible to use Jackson 2.7 on Java 6, but 
not compile, build. With Jackson 2.8, Java 7 languages features will be allowed 
-->
-        <version>2.6.6</version>
+        <!--  https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.11.3 
-->
+        <version>2.11.3</version>
       </dependency>
       <!-- if activating useJsonPath include jayway dependency  -->
       <!-- dependency>
@@ -388,7 +388,7 @@ under the License.
       <dependency>
         <groupId>junit</groupId>
         <artifactId>junit</artifactId>
-        <version>4.12</version>
+        <version>4.13</version>
         <scope>test</scope>
       </dependency>
       <dependency>
@@ -403,15 +403,15 @@ under the License.
         <maven.compile.source>1.8</maven.compile.source>
         <maven.compile.target>1.8</maven.compile.target>
         <project.build.sourceEncoding>utf-8</project.build.sourceEncoding>
-        <log4j2.version>2.12.0</log4j2.version>
-        <mysql.version>8.0.17</mysql.version>
-        <torque.version>4.0</torque.version>
+        <log4j2.version>2.13.3</log4j2.version>
+        <mysql.version>8.0.21</mysql.version>
+        <torque.version>5.0</torque.version>
         <fulcrum.json>2.0.0</fulcrum.json>
-        <fulcrum.intake>2.0.0</fulcrum.intake>
-        <fulcrum.security>1.1.3</fulcrum.security>
+        <fulcrum.intake>2.0.1-SNAPSHOT</fulcrum.intake>
+        <fulcrum.security>2.0.0-SNAPSHOT</fulcrum.security>
         <fulcrum.yaafi>1.0.8</fulcrum.yaafi>
         <fulcrum.testcontainer>1.0.8</fulcrum.testcontainer>
-        <turbine.core>5.0</turbine.core>
+        <turbine.core>5.1-SNAPSHOT</turbine.core>
         <skipTests>true</skipTests>
     </properties>
     
diff --git 
a/src/main/resources/archetype-resources/src/main/java/om/TurbineRolePermission.java
 
b/src/main/resources/archetype-resources/src/main/java/om/TurbineRolePermission.java
index a26f32e..ab222ad 100644
--- 
a/src/main/resources/archetype-resources/src/main/java/om/TurbineRolePermission.java
+++ 
b/src/main/resources/archetype-resources/src/main/java/om/TurbineRolePermission.java
@@ -12,7 +12,7 @@ package ${package}.om;
  */
 
 public  class TurbineRolePermission
-    extends ${package}.om.BaseTurbineRolePermission
+    extends ${package}.om.BaseTurbineRolePermission implements 
org.apache.fulcrum.security.torque.peer.TurbineRolePermissionPeerMapper
 {
     /**
         * 
diff --git 
a/src/main/resources/archetype-resources/src/main/torque-schema/application-schema.xml
 
b/src/main/resources/archetype-resources/src/main/torque-schema/application-schema.xml
index 95f9c04..e990fc2 100644
--- 
a/src/main/resources/archetype-resources/src/main/torque-schema/application-schema.xml
+++ 
b/src/main/resources/archetype-resources/src/main/torque-schema/application-schema.xml
@@ -26,10 +26,10 @@
 <!--                                                                           
     -->
 <!-- 
============================================================================== 
-->
 
-<database xmlns="http://db.apache.org/torque/4.0/templates/database";
+<database xmlns="http://db.apache.org/torque/5.0/templates/database";
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
-  xsi:schemaLocation="http://db.apache.org/torque/4.0/templates/database
-        http://db.apache.org/torque/4.0/templates/database-strict.xsd";
+  xsi:schemaLocation="http://db.apache.org/torque/5.0/templates/database
+        https://db.apache.org/torque/xsd/database-5-0-strict.xsd";
   name="${turbine_database_name}"
   defaultIdMethod="native">
 
diff --git 
a/src/main/resources/archetype-resources/src/main/torque-schema/id-table-schema.xml
 
b/src/main/resources/archetype-resources/src/main/torque-schema/id-table-schema.xml
index 3bfe67c..26f37ad 100644
--- 
a/src/main/resources/archetype-resources/src/main/torque-schema/id-table-schema.xml
+++ 
b/src/main/resources/archetype-resources/src/main/torque-schema/id-table-schema.xml
@@ -26,10 +26,10 @@
 <!--                                                                           
-->
 <!-- ========================================================================= 
-->
 
-<database xmlns="http://db.apache.org/torque/4.0/templates/database";
+<database xmlns="http://db.apache.org/torque/5.0/templates/database";
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
-  xsi:schemaLocation="http://db.apache.org/torque/4.0/templates/database
-        http://db.apache.org/torque/4.0/templates/database-strict.xsd";
+  xsi:schemaLocation="http://db.apache.org/torque/5.0/templates/database
+        https://db.apache.org/torque/xsd/database-5-0-strict.xsd";
   name="${turbine_database_name}"
   defaultIdMethod="native">
 
diff --git 
a/src/main/resources/archetype-resources/src/main/torque-schema/torque-security-schema.xml
 
b/src/main/resources/archetype-resources/src/main/torque-schema/torque-security-schema.xml
index 76c31da..41d6802 100644
--- 
a/src/main/resources/archetype-resources/src/main/torque-schema/torque-security-schema.xml
+++ 
b/src/main/resources/archetype-resources/src/main/torque-schema/torque-security-schema.xml
@@ -24,22 +24,25 @@
 <!--  Turbine Torque based Security Service Schema                            
-->
 <!--                                                                          
-->
 <!--  Schema documentation                                                    
-->
-<!--  
http://db.apache.org/torque/torque-4.0/documentation/orm-reference/database-4-0-strict.xsd
 -->
-<!--  
http://db.apache.org/torque/torque-4.0/documentation/orm-reference/database-4-0.xsd
 -->
+<!--  
http://db.apache.org/torque/torque-5.0/documentation/orm-reference/database-5-0-strict.xsd
 -->
+<!--  
http://db.apache.org/torque/torque-5.0/documentation/orm-reference/database-5-0.xsd
 -->
 <!--                                                                          
-->
 <!-- $Id: turbine-security-schema.xml 615328 2008-01-25 20:25:05Z tv $ -->
 <!--                                                                          
-->
 <!-- ======================================================================== 
-->
 
-<database xmlns="http://db.apache.org/torque/4.0/templates/database";
+<database xmlns="http://db.apache.org/torque/5.0/templates/database";
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
-  xsi:schemaLocation="http://db.apache.org/torque/4.0/templates/database
-        http://db.apache.org/torque/4.0/templates/database-strict.xsd";
+  xsi:schemaLocation="http://db.apache.org/torque/5.0/templates/database
+        https://db.apache.org/torque/xsd/database-5-0-strict.xsd";
   name="${turbine_database_name}"
   defaultIdMethod="none">
 
 
-  <table name="TURBINE_PERMISSION" idMethod="native" 
baseClass="org.apache.fulcrum.security.torque.turbine.DefaultAbstractTurbinePermission"
 interface="org.apache.fulcrum.security.model.turbine.entity.TurbinePermission">
+  <table name="TURBINE_PERMISSION" idMethod="native" 
+  
baseClass="org.apache.fulcrum.security.torque.turbine.DefaultAbstractTurbinePermission"
 
+  
interface="org.apache.fulcrum.security.model.turbine.entity.TurbinePermission"
+  peerInterface="org.apache.fulcrum.security.torque.peer.TorqueTurbinePeer">
     <column name="PERMISSION_ID" required="true" primaryKey="true" 
type="INTEGER" javaType="object" javaName="EntityId" autoIncrement="true"/>
     <column name="PERMISSION_NAME" required="true" size="64" type="VARCHAR" 
javaName="EntityName"/>
 
@@ -49,7 +52,10 @@
 
   </table>
 
-  <table name="TURBINE_ROLE" idMethod="native" 
baseClass="org.apache.fulcrum.security.torque.turbine.DefaultAbstractTurbineRole"
 interface="org.apache.fulcrum.security.model.turbine.entity.TurbineRole">
+  <table name="TURBINE_ROLE" idMethod="native" 
+  
baseClass="org.apache.fulcrum.security.torque.turbine.DefaultAbstractTurbineRole"
 
+  interface="org.apache.fulcrum.security.model.turbine.entity.TurbineRole"
+  peerInterface="org.apache.fulcrum.security.torque.peer.TorqueTurbinePeer">
     <column name="ROLE_ID" required="true" primaryKey="true" type="INTEGER" 
javaType="object" javaName="EntityId" autoIncrement="true"/>
     <column name="ROLE_NAME" required="true" size="64" type="VARCHAR" 
javaName="EntityName"/>
 
@@ -59,7 +65,10 @@
 
   </table>
 
-  <table name="TURBINE_GROUP" idMethod="native" 
baseClass="org.apache.fulcrum.security.torque.turbine.DefaultAbstractTurbineGroup"
 interface="org.apache.fulcrum.security.model.turbine.entity.TurbineGroup">
+  <table name="TURBINE_GROUP" idMethod="native" 
+  
baseClass="org.apache.fulcrum.security.torque.turbine.DefaultAbstractTurbineGroup"
 
+  interface="org.apache.fulcrum.security.model.turbine.entity.TurbineGroup"
+  peerInterface="org.apache.fulcrum.security.torque.peer.TorqueTurbinePeer">
     <column name="GROUP_ID" required="true" primaryKey="true" type="INTEGER" 
javaType="object" javaName="EntityId" autoIncrement="true"/>
     <column name="GROUP_NAME" required="true" type="VARCHAR" size="64" 
javaName="EntityName"/>
 
@@ -69,7 +78,8 @@
 
   </table>
 
-  <table name="TURBINE_ROLE_PERMISSION">
+  <table name="TURBINE_ROLE_PERMISSION" 
+   
interface="org.apache.fulcrum.security.torque.peer.TurbineRolePermissionPeerMapper">
     <column name="ROLE_ID" required="true" primaryKey="true" type="INTEGER"/>
     <column name="PERMISSION_ID" required="true" primaryKey="true" 
type="INTEGER"/>
 
@@ -84,8 +94,10 @@
   </table>
 
   <!-- org.apache.fulcrum.security.torque.TorqueAbstractSecurityEntity -->
-  <table name="TURBINE_USER" idMethod="native" 
baseClass="org.apache.fulcrum.security.torque.turbine.DefaultAbstractTurbineUser"
-  interface="org.apache.fulcrum.security.model.turbine.entity.TurbineUser">
+  <table name="TURBINE_USER" idMethod="native" 
+  
baseClass="org.apache.fulcrum.security.torque.turbine.DefaultAbstractTurbineUser"
+  interface="org.apache.fulcrum.security.model.turbine.entity.TurbineUser"
+   peerInterface="org.apache.fulcrum.security.torque.peer.TorqueTurbinePeer">
     <column name="USER_ID" required="true" primaryKey="true" type="INTEGER" 
javaType="object" javaName="EntityId" autoIncrement="true"/>
     <column name="LOGIN_NAME" required="true" size="64" type="VARCHAR" 
javaName="EntityName"/>
     <column name="PASSWORD_VALUE" required="true" size="16" type="VARCHAR" 
javaName="Password"/>
@@ -104,7 +116,9 @@
 
   </table>
 
-  <table name="TURBINE_USER_GROUP_ROLE" 
interface="org.apache.fulcrum.security.torque.peer.TurbineUserGroupRoleModelPeerMapper">
+  <table name="TURBINE_USER_GROUP_ROLE" 
+  
interface="org.apache.fulcrum.security.torque.peer.TurbineUserGroupRoleModelPeerMapper"
+  
peerInterface="org.apache.fulcrum.security.torque.peer.TorqueTurbineUserGroupRolePeer">
     <column name="USER_ID" required="true" primaryKey="true" type="INTEGER"/>
     <column name="GROUP_ID" required="true" primaryKey="true" type="INTEGER"/>
     <column name="ROLE_ID" required="true" primaryKey="true" type="INTEGER"/>
diff --git 
a/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/conf/componentConfiguration.xml
 
b/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/conf/componentConfiguration.xml
index 438eb5a..06d1032 100644
--- 
a/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/conf/componentConfiguration.xml
+++ 
b/src/main/resources/archetype-resources/src/main/webapp/WEB-INF/conf/componentConfiguration.xml
@@ -124,7 +124,7 @@
     
     <!-- 
      Custom Turbine ORM Torque classes could not yet be used: 
-     - requires Torque 4.1 or if using Torque 4.0 reqires manually adding the 
interfaces in T-classes
+     - requires Torque > 4 or if using Torque 4.0 reqires manually adding the 
interfaces in T-classes
      - requires attribute baseClass in fulcrum-turbine-schema.xml table 
elements set to appropriate org.apache.fulcrum.security.model.turbine.entity 
interfaces
      - requires attribute peerClass in fulcrum-turbine-schema.xml table 
elements set to org.apache.fulcrum.security.torque.peer.TorqueTurbinePeer 
      -->
diff --git a/src/test/resources/projects/first/goal.txt 
b/src/test/resources/projects/first/goal.txt
index 597acc7..b472a75 100644
--- a/src/test/resources/projects/first/goal.txt
+++ b/src/test/resources/projects/first/goal.txt
@@ -1 +1 @@
-package
\ No newline at end of file
+eclipse:eclipse idea:idea package
\ No newline at end of file

Reply via email to