You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@avro.apache.org by rs...@apache.org on 2022/02/07 19:09:58 UTC

[avro] branch master updated: AVRO-3371 - add empty string as 3rd velocity root in SpecificCompiler to be able to load resources by absolute path on windows (#1521)

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

rskraba 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 9ab5ae3  AVRO-3371 - add empty string as 3rd velocity root in SpecificCompiler to be able to load resources by absolute path on windows (#1521)
9ab5ae3 is described below

commit 9ab5ae3cd60b8c38c330e9483140d1a6f8d254cc
Author: Radai Rosenblatt <ra...@gmail.com>
AuthorDate: Mon Feb 7 11:05:43 2022 -0800

    AVRO-3371 - add empty string as 3rd velocity root in SpecificCompiler to be able to load resources by absolute path on windows (#1521)
---
 .../main/java/org/apache/avro/compiler/specific/SpecificCompiler.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

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 7e6a9c7..6f46845 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
@@ -381,7 +381,7 @@ public class SpecificCompiler {
         "org.apache.velocity.runtime.resource.loader.ClasspathResourceLoader");
     velocityEngine.addProperty("resource.loader.file.class",
         "org.apache.velocity.runtime.resource.loader.FileResourceLoader");
-    velocityEngine.addProperty("resource.loader.file.path", "/, .");
+    velocityEngine.addProperty("resource.loader.file.path", "/, ., ");
     velocityEngine.setProperty("runtime.strict_mode.enable", true);
 
     // Set whitespace gobbling to Backward Compatible (BC)