You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@avro.apache.org by ie...@apache.org on 2019/11/04 16:49:56 UTC

[avro] branch master updated: AVRO-2600: Swap to new properties in Velocity Engine

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

iemejia pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/avro.git


The following commit(s) were added to refs/heads/master by this push:
     new 044572a  AVRO-2600: Swap to new properties in Velocity Engine
044572a is described below

commit 044572a8550a87cd04c5ce31bd9f737a0e8cd3c3
Author: sigand <si...@knowit.no>
AuthorDate: Fri Oct 18 14:02:43 2019 +0200

    AVRO-2600: Swap to new properties in Velocity Engine
    
    Following the migration guide at the Velocity documentation
    https://velocity.apache.org/engine/devel/configuration-property-changes-in-2.1.html
---
 .../org/apache/avro/compiler/specific/SpecificCompiler.java  | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/lang/java/compiler/src/main/java/org/apache/avro/compiler/specific/SpecificCompiler.java b/lang/java/compiler/src/main/java/org/apache/avro/compiler/specific/SpecificCompiler.java
index 14d5a3e..6b2de12 100644
--- a/lang/java/compiler/src/main/java/org/apache/avro/compiler/specific/SpecificCompiler.java
+++ b/lang/java/compiler/src/main/java/org/apache/avro/compiler/specific/SpecificCompiler.java
@@ -337,17 +337,17 @@ public class SpecificCompiler {
 
     // These properties tell Velocity to use its own classpath-based
     // loader, then drop down to check the root and the current folder
-    velocityEngine.addProperty("resource.loader", "class, file");
-    velocityEngine.addProperty("class.resource.loader.class",
+    velocityEngine.addProperty("resource.loaders", "class, file");
+    velocityEngine.addProperty("resource.loader.class.class",
         "org.apache.velocity.runtime.resource.loader.ClasspathResourceLoader");
-    velocityEngine.addProperty("file.resource.loader.class",
+    velocityEngine.addProperty("resource.loader.file.class",
         "org.apache.velocity.runtime.resource.loader.FileResourceLoader");
-    velocityEngine.addProperty("file.resource.loader.path", "/, .");
-    velocityEngine.setProperty("runtime.references.strict", true);
+    velocityEngine.addProperty("resource.loader.file.path", "/, .");
+    velocityEngine.setProperty("runtime.strict_mode.enable", true);
 
     // Set whitespace gobbling to Backward Compatible (BC)
     // https://velocity.apache.org/engine/2.0/developer-guide.html#space-gobbling
-    velocityEngine.setProperty("space.gobbling", "bc");
+    velocityEngine.setProperty("parser.space_gobbling", "bc");
   }
 
   private void initializeSpecificData() {