You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-dev@db.apache.org by tf...@apache.org on 2011/07/19 18:05:12 UTC

svn commit: r1148423 - in /db/torque/torque4/trunk/torque-generator: pom.xml src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java

Author: tfischer
Date: Tue Jul 19 16:05:11 2011
New Revision: 1148423

URL: http://svn.apache.org/viewvc?rev=1148423&view=rev
Log:
upgrade to newest velocity version

Modified:
    db/torque/torque4/trunk/torque-generator/pom.xml
    db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java

Modified: db/torque/torque4/trunk/torque-generator/pom.xml
URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-generator/pom.xml?rev=1148423&r1=1148422&r2=1148423&view=diff
==============================================================================
--- db/torque/torque4/trunk/torque-generator/pom.xml (original)
+++ db/torque/torque4/trunk/torque-generator/pom.xml Tue Jul 19 16:05:11 2011
@@ -36,9 +36,9 @@
 
   <dependencies>
     <dependency>
-      <groupId>velocity</groupId>
+      <groupId>org.apache.velocity</groupId>
       <artifactId>velocity</artifactId>
-      <version>1.4</version>
+      <version>1.7</version>
     </dependency>
     <dependency>
       <groupId>commons-logging</groupId>

Modified: db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java
URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java?rev=1148423&r1=1148422&r2=1148423&view=diff
==============================================================================
--- db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java (original)
+++ db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java Tue Jul 19 16:05:11 2011
@@ -21,6 +21,7 @@ package org.apache.torque.generator.temp
 
 import java.io.StringWriter;
 import java.io.Writer;
+import java.util.Properties;
 import java.util.Set;
 
 import org.apache.commons.logging.Log;
@@ -41,6 +42,8 @@ import org.apache.torque.generator.varia
 import org.apache.velocity.VelocityContext;
 import org.apache.velocity.app.Velocity;
 import org.apache.velocity.context.Context;
+import org.apache.velocity.runtime.RuntimeConstants;
+import org.apache.velocity.runtime.log.Log4JLogChute;
 import org.apache.velocity.util.StringUtils;
 
 /**
@@ -210,7 +213,14 @@ public class VelocityOutlet extends Temp
         {
             try
             {
-                Velocity.init();
+                Properties properties = new Properties();
+                properties.put(
+                        RuntimeConstants.RUNTIME_LOG_LOGSYSTEM_CLASS,
+                        Log4JLogChute.class.getName());
+                properties.put(
+                        RuntimeConstants.RUNTIME_LOG,
+                        "");
+                Velocity.init(properties);
             }
             catch (Exception e)
             {



---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org


RE: svn commit: r1148423 - in /db/torque/torque4/trunk/torque-generator: pom.xml src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java

Posted by Thomas Fox <Th...@seitenbau.net>.
> Just curious... where are we still using Velocity?  I seem to
> remember it's still in some of non code generating targets.  Not
> important, just seeing this update made me wonder.

All templates are still velocity templates. So to render them, we still
need velocity. We just do not use texen any more.

    Thomas


---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org


RE: svn commit: r1148423 - in /db/torque/torque4/trunk/torque-generator: pom.xml src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java

Posted by Greg Monroe <Gr...@dukece.com>.
Just curious... where are we still using Velocity?  I seem to remember it's still in some of non code generating targets.  Not important, just seeing this update made me wonder.

-----Original Message-----
From: tfischer@apache.org [mailto:tfischer@apache.org] 
Sent: Tuesday, July 19, 2011 12:05 PM
To: torque-commits@db.apache.org
Subject: svn commit: r1148423 - in /db/torque/torque4/trunk/torque-generator: pom.xml src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java

Author: tfischer
Date: Tue Jul 19 16:05:11 2011
New Revision: 1148423

URL: http://svn.apache.org/viewvc?rev=1148423&view=rev
Log:
upgrade to newest velocity version

Modified:
    db/torque/torque4/trunk/torque-generator/pom.xml
    db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java

Modified: db/torque/torque4/trunk/torque-generator/pom.xml
URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-generator/pom.xml?rev=1148423&r1=1148422&r2=1148423&view=diff
==============================================================================
--- db/torque/torque4/trunk/torque-generator/pom.xml (original)
+++ db/torque/torque4/trunk/torque-generator/pom.xml Tue Jul 19 16:05:11 2011
@@ -36,9 +36,9 @@
 
   <dependencies>
     <dependency>
-      <groupId>velocity</groupId>
+      <groupId>org.apache.velocity</groupId>
       <artifactId>velocity</artifactId>
-      <version>1.4</version>
+      <version>1.7</version>
     </dependency>
     <dependency>
       <groupId>commons-logging</groupId>

Modified: db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java
URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java?rev=1148423&r1=1148422&r2=1148423&view=diff
==============================================================================
--- db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java (original)
+++ db/torque/torque4/trunk/torque-generator/src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java Tue Jul 19 16:05:11 2011
@@ -21,6 +21,7 @@ package org.apache.torque.generator.temp
 
 import java.io.StringWriter;
 import java.io.Writer;
+import java.util.Properties;
 import java.util.Set;
 
 import org.apache.commons.logging.Log;
@@ -41,6 +42,8 @@ import org.apache.torque.generator.varia
 import org.apache.velocity.VelocityContext;
 import org.apache.velocity.app.Velocity;
 import org.apache.velocity.context.Context;
+import org.apache.velocity.runtime.RuntimeConstants;
+import org.apache.velocity.runtime.log.Log4JLogChute;
 import org.apache.velocity.util.StringUtils;
 
 /**
@@ -210,7 +213,14 @@ public class VelocityOutlet extends Temp
         {
             try
             {
-                Velocity.init();
+                Properties properties = new Properties();
+                properties.put(
+                        RuntimeConstants.RUNTIME_LOG_LOGSYSTEM_CLASS,
+                        Log4JLogChute.class.getName());
+                properties.put(
+                        RuntimeConstants.RUNTIME_LOG,
+                        "");
+                Velocity.init(properties);
             }
             catch (Exception e)
             {



---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org


DukeCE Privacy Statement:
Please be advised that this e-mail and any files transmitted with
it are confidential communication or may otherwise be privileged or
confidential and are intended solely for the individual or entity
to whom they are addressed. If you are not the intended recipient
you may not rely on the contents of this email or any attachments,
and we ask that you please not read, copy or retransmit this
communication, but reply to the sender and destroy the email, its
contents, and all copies thereof immediately. Any unauthorized
dissemination, distribution or copying of this communication is
strictly prohibited.

Antwort: svn commit: r1148423 - in /db/torque/torque4/trunk/torque-generator: pom.xml src/main/java/org/apache/torque/generator/template/velocity/VelocityOutlet.java

Posted by Thomas Fox <Th...@seitenbau.net>.
sorry, should have been two commits. Thw pom commit is really the upgrade
to velocity whereas the VelocityOutlet commit is for not creating the
velocity.log file on running the generator any more, but using log4j as the
rest of the generator.

> Author: tfischer
> Date: Tue Jul 19 16:05:11 2011
> New Revision: 1148423
>
> URL: http://svn.apache.org/viewvc?rev=1148423&view=rev
> Log:
> upgrade to newest velocity version
>
> Modified:
>     db/torque/torque4/trunk/torque-generator/pom.xml
>     db/torque/torque4/trunk/torque-generator/src/main/java/org/
> apache/torque/generator/template/velocity/VelocityOutlet.java
>
> Modified: db/torque/torque4/trunk/torque-generator/pom.xml
> URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-
> generator/pom.xml?rev=1148423&r1=1148422&r2=1148423&view=diff
>
==============================================================================

> --- db/torque/torque4/trunk/torque-generator/pom.xml (original)
> +++ db/torque/torque4/trunk/torque-generator/pom.xml Tue Jul 19 16:05:11
2011
> @@ -36,9 +36,9 @@
>
>    <dependencies>
>      <dependency>
> -      <groupId>velocity</groupId>
> +      <groupId>org.apache.velocity</groupId>
>        <artifactId>velocity</artifactId>
> -      <version>1.4</version>
> +      <version>1.7</version>
>      </dependency>
>      <dependency>
>        <groupId>commons-logging</groupId>
>
> Modified: db/torque/torque4/trunk/torque-generator/src/main/java/
> org/apache/torque/generator/template/velocity/VelocityOutlet.java
> URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-
> generator/src/main/java/org/apache/torque/generator/template/
> velocity/VelocityOutlet.java?rev=1148423&r1=1148422&r2=1148423&view=diff
>
==============================================================================

> --- db/torque/torque4/trunk/torque-generator/src/main/java/org/
> apache/torque/generator/template/velocity/VelocityOutlet.java (original)
> +++ db/torque/torque4/trunk/torque-generator/src/main/java/org/
> apache/torque/generator/template/velocity/VelocityOutlet.java Tue
> Jul 19 16:05:11 2011
> @@ -21,6 +21,7 @@ package org.apache.torque.generator.temp
>
>  import java.io.StringWriter;
>  import java.io.Writer;
> +import java.util.Properties;
>  import java.util.Set;
>
>  import org.apache.commons.logging.Log;
> @@ -41,6 +42,8 @@ import org.apache.torque.generator.varia
>  import org.apache.velocity.VelocityContext;
>  import org.apache.velocity.app.Velocity;
>  import org.apache.velocity.context.Context;
> +import org.apache.velocity.runtime.RuntimeConstants;
> +import org.apache.velocity.runtime.log.Log4JLogChute;
>  import org.apache.velocity.util.StringUtils;
>
>  /**
> @@ -210,7 +213,14 @@ public class VelocityOutlet extends Temp
>          {
>              try
>              {
> -                Velocity.init();
> +                Properties properties = new Properties();
> +                properties.put(
> +                        RuntimeConstants.RUNTIME_LOG_LOGSYSTEM_CLASS,
> +                        Log4JLogChute.class.getName());
> +                properties.put(
> +                        RuntimeConstants.RUNTIME_LOG,
> +                        "");
> +                Velocity.init(properties);
>              }
>              catch (Exception e)
>              {
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
> For additional commands, e-mail: torque-dev-help@db.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org