Reamer commented on code in PR #4797:
URL: https://github.com/apache/zeppelin/pull/4797#discussion_r1756917133


##########
zeppelin-interpreter/pom.xml:
##########
@@ -241,6 +241,42 @@
           <dateFormat>yyyy-MM-dd HH:mm:ss</dateFormat>
         </configuration>
       </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>exec-maven-plugin</artifactId>
+        <version>3.0.0</version>
+        <executions>
+          <execution>
+            <!-- This execution runs during the compile phase to generate Java 
files from Thrift files -->
+            <id>generate-thrift-sources</id>
+            <phase>generate-sources</phase>
+            <goals>
+              <goal>exec</goal>
+            </goals>
+            <configuration>
+              <executable>bash</executable>
+              <arguments>
+                <argument>${basedir}/src/main/thrift/genthrift.sh</argument>
+              </arguments>
+            </configuration>
+          </execution>
+          <execution>
+            <!-- This execution can be triggered manually to install Thrift by 
running the following command: -->
+            <!-- mvn exec:exec@install-thrift -->
+            <id>install-thrift</id>
+            <goals>
+              <goal>exec</goal>
+            </goals>
+            <configuration>
+              <executable>bash</executable>
+              <arguments>
+                <argument>${basedir}/src/main/thrift/genthrift.sh</argument>
+                <argument>install</argument>

Review Comment:
   genthrift.sh does not support arguments, so the execution can be removed.



##########
zeppelin-interpreter/pom.xml:
##########
@@ -241,6 +241,42 @@
           <dateFormat>yyyy-MM-dd HH:mm:ss</dateFormat>
         </configuration>
       </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>exec-maven-plugin</artifactId>
+        <version>3.0.0</version>
+        <executions>
+          <execution>
+            <!-- This execution runs during the compile phase to generate Java 
files from Thrift files -->

Review Comment:
   Thrift is not installed in the CI pipeline, so these steps can only be 
executed using profiles similar to hbase-thrift.



##########
zeppelin-interpreter/src/main/thrift/genthrift.sh:
##########
@@ -17,176 +17,25 @@
 # * limitations under the License.
 # */
 
+# Determine the base directory dynamically (directory where the script is 
located)
+THRIFT_EXEC="$(dirname "$(realpath "$0")")"

Review Comment:
   I understand your approach. However, the path is not the Thrift.exe, but the 
Zeppelin Thrift folder. Please change the variable name, it has just confused 
me a lot.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to