LuciferYang commented on code in PR #39866:
URL: https://github.com/apache/spark/pull/39866#discussion_r1098833915


##########
connector/connect/client/jvm/pom.xml:
##########
@@ -112,40 +124,57 @@
           <shadedArtifactAttached>false</shadedArtifactAttached>
           <artifactSet>
             <includes>
+              <include>com.google.android:*</include>
+              <include>com.google.api.grpc:*</include>
+              <include>com.google.code.findbugs:*</include>
+              <include>com.google.code.gson:*</include>
+              <include>com.google.errorprone:*</include>
               <include>com.google.guava:*</include>
-              <include>io.grpc:*</include>
+              <include>com.google.j2objc:*</include>
               <include>com.google.protobuf:*</include>
+              <include>io.grpc:*</include>
+              <include>io.netty:*</include>
+              <include>io.perfmark:*</include>
+              <include>org.codehaus.mojo:*</include>
+              <include>org.checkerframework:*</include>
               
<include>org.apache.spark:spark-connect-common_${scala.binary.version}</include>
             </includes>
           </artifactSet>
           <relocations>
             <relocation>
               <pattern>io.grpc</pattern>
-              
<shadedPattern>${spark.shade.packageName}.connect.client.grpc</shadedPattern>
+              
<shadedPattern>${spark.shade.packageName}.connect.client.io.grpc</shadedPattern>
               <includes>
                 <include>io.grpc.**</include>
               </includes>
             </relocation>
             <relocation>
-              <pattern>com.google.protobuf</pattern>
-              
<shadedPattern>${spark.shade.packageName}.connect.protobuf</shadedPattern>
-              <includes>
-                <include>com.google.protobuf.**</include>
-              </includes>
+              <pattern>com.google</pattern>
+              
<shadedPattern>${spark.shade.packageName}.connect.client.com.google</shadedPattern>
             </relocation>
             <relocation>
-              <pattern>com.google.common</pattern>
-              
<shadedPattern>${spark.shade.packageName}.connect.client.guava</shadedPattern>
-              <includes>
-                <include>com.google.common.**</include>
-              </includes>
+              <pattern>io.netty</pattern>

Review Comment:
   if we shade and relocation netty, the content in 
`META-INF/native-image/io.netty` should also relocated, just as in 
`grpc-netty-shaded`.
   
   Now, the content of 
`META-INF/native-image/io.netty/netty-codec-http2/native-image.properties` is
   
   ```
   Args = --initialize-at-build-time=io.netty \
          
--initialize-at-run-time=io.netty.handler.codec.http2.Http2CodecUtil,io.netty.handler.codec.http2.Http2ClientUpgradeCodec,io.netty.handler.codec.http2.Http2ConnectionHandler,io.netty.handler.codec.http2.DefaultHttp2FrameWriter
   ```
   
   but I think it should like 
   
   ```
   Args = --initialize-at-build-time=org.sparkproject.connect.client.io.netty \
          
--initialize-at-run-time=org.sparkproject.connect.client.io.netty.handler.codec.http2.Http2CodecUtil,org.sparkproject.connect.client.io.netty.handler.codec.http2.Http2ClientUpgradeCodec,org.sparkproject.connect.client.io.netty.handler.codec.http2.Http2ConnectionHandler,org.sparkproject.connect.client.io.netty.handler.codec.http2.DefaultHttp2FrameWriter
       
   ```
   Other Transformer may need to be added
   
   
   



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to