yihua commented on code in PR #7224:
URL: https://github.com/apache/hudi/pull/7224#discussion_r1028708802


##########
packaging/hudi-cli-bundle/pom.xml:
##########
@@ -0,0 +1,635 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd";>
+    <parent>
+        <artifactId>hudi</artifactId>
+        <groupId>org.apache.hudi</groupId>
+        <version>0.13.0-SNAPSHOT</version>
+        <relativePath>../../pom.xml</relativePath>
+    </parent>
+    <modelVersion>4.0.0</modelVersion>
+    <artifactId>hudi-cli-bundle</artifactId>
+    <packaging>jar</packaging>
+
+    <properties>
+        <checkstyle.skip>true</checkstyle.skip>
+        <main.basedir>${project.parent.basedir}</main.basedir>
+        <skipTests>true</skipTests>
+        <javax.servlet.version>3.1.0</javax.servlet.version>
+    </properties>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.rat</groupId>
+                <artifactId>apache-rat-plugin</artifactId>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-shade-plugin</artifactId>
+                <version>${maven-shade-plugin.version}</version>
+                <executions>
+                    <execution>
+                        <phase>package</phase>
+                        <goals>
+                            <goal>shade</goal>
+                        </goals>
+                        <configuration>
+                            
<createSourcesJar>${shadeSources}</createSourcesJar>
+                            
<dependencyReducedPomLocation>${project.build.directory}/dependency-reduced-pom.xml
+                            </dependencyReducedPomLocation>
+                            <transformers>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.ApacheLicenseResourceTransformer"
 />
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.ApacheNoticeResourceTransformer">
+                                    <addHeader>true</addHeader>
+                                </transformer>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.IncludeResourceTransformer">
+                                    <resource>META-INF/LICENSE</resource>
+                                    
<file>target/classes/META-INF/LICENSE</file>
+                                </transformer>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
+                                    
<resource>META-INF/services/org.apache.spark.sql.sources.DataSourceRegister</resource>
+                                </transformer>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
+                                    
<resource>META-INF/spring.handlers</resource>
+                                </transformer>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
+                                    
<resource>META-INF/spring.schemas</resource>
+                                </transformer>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
+                                    
<resource>META-INF/spring.factories</resource>
+                                </transformer>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer"/>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
+                                    
<mainClass>org.apache.hudi.cli.Main</mainClass>
+                                </transformer>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
+                                    
<resource>META-INF/spring/org.springframework.boot.actuate.autoconfigure.web.ManagementContextConfiguration.imports</resource>
+                                </transformer>
+                                <transformer 
implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
+                                    
<resource>META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports</resource>
+                                </transformer>
+                            </transformers>
+                            <artifactSet>
+                                <includes combine.children="append">
+                                    
<include>org.apache.hudi:hudi-common</include>
+                                    <include>org.apache.hudi:hudi-cli</include>
+                                    
<include>org.apache.hudi:hudi-client-common</include>
+                                    
<include>org.apache.hudi:hudi-spark-client</include>
+                                    
<include>org.apache.hudi:hudi-spark-common_${scala.binary.version}</include>
+                                    
<include>org.apache.hudi:hudi-spark_${scala.binary.version}</include>

Review Comment:
   As synced offline, the following modules which vary across Spark and Scala 
versions should be excluded if possible, when we consider the use case of 
hudi-cli-bundle + hudi-spark-bundle (use corresponding one like 
hudi-spark3.2-bundle based on the Spark runtime):
   ```
   <include>org.apache.hudi:hudi-spark-common_${scala.binary.version}</include>
   <include>org.apache.hudi:hudi-spark_${scala.binary.version}</include>
   
<include>org.apache.hudi:${hudi.spark.module}_${scala.binary.version}</include>
   <include>org.apache.hudi:${hudi.spark.common.modules.1}</include>
   <include>org.apache.hudi:${hudi.spark.common.modules.2}</include>
   <include>org.apache.hudi:hudi-spark-client</include>
   <include>org.apache.hudi:hudi-utilities_${scala.binary.version}</include>
   <include>com.twitter:bijection-avro_${scala.binary.version}</include>
   <include>com.twitter:bijection-core_${scala.binary.version}</include>
   ```
   The goal is to make sure this is no need to release Spark and Scala 
version-dependent hudi-cli-bundle, if possible.
   
   Let's also check if the versions of any dependencies other than these 
entries can vary between Spark2 and Spark3 profile, and these should be removed 
as well (assuming Spark bundle packages them).



##########
hudi-cli/src/main/resources/log4j2.properties:
##########
@@ -25,7 +25,7 @@ appender.console.layout.type = PatternLayout
 appender.console.layout.pattern = %-4r [%t] %-5p %c %x - %m%n
 
 # Root logger level
-rootLogger.level = warn
+rootLogger.level = info

Review Comment:
   Should this be kept as `warn`, since we already have explicit rules below to 
print `info`-level logs for `org.apache.hudi.common`, `org.apache.hudi.cli`, 
and `org.apache.spark`?



-- 
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