Переглянути джерело

ZOOKEEPER-3494: remove unnecessary broad netty-all dependency

Currently netty-all is a 4MB dependency.
Using netty-handler (429KB) and netty-transport-native-epoll (115KB) brings it down to about 1/8 in size.

Author: Norbert Kalmar <nkalmar@yahoo.com>

Reviewers: Enrico Olivelli <eolivelli@gmail.com>, Tamás Pénzes, Michael Han <hanm@apache.org>

Closes #1039 from nkalmar/ZK-3494
Norbert Kalmar 5 роки тому
батько
коміт
4de5f012a5
3 змінених файлів з 16 додано та 4 видалено
  1. 5 2
      ivy.xml
  2. 6 1
      pom.xml
  3. 5 1
      zookeeper-server/pom.xml

+ 5 - 2
ivy.xml

@@ -60,8 +60,11 @@
     <dependency org="org.apache.yetus" name="audience-annotations"
                 rev="${audience-annotations.version}"/>
 
-    <dependency org="io.netty" name="netty-all" conf="default" rev="${netty.version}">
-      <artifact name="netty-all" type="jar" conf="default"/>
+    <dependency org="io.netty" name="netty-handler" conf="default" rev="${netty.version}">
+      <artifact name="netty-handler" type="jar" conf="default"/>
+    </dependency>
+    <dependency org="io.netty" name="netty-transport-native-epoll" conf="default" rev="${netty.version}">
+      <artifact name="netty-transport-native-epoll" type="jar" conf="default"/>
     </dependency>
 
     <dependency org="com.googlecode.json-simple" name="json-simple" rev="${json.version}" >

+ 6 - 1
pom.xml

@@ -400,7 +400,12 @@
       </dependency>
       <dependency>
         <groupId>io.netty</groupId>
-        <artifactId>netty-all</artifactId>
+        <artifactId>netty-handler</artifactId>
+        <version>${netty.version}</version>
+      </dependency>
+      <dependency>
+        <groupId>io.netty</groupId>
+        <artifactId>netty-transport-native-epoll</artifactId>
         <version>${netty.version}</version>
       </dependency>
       <dependency>

+ 5 - 1
zookeeper-server/pom.xml

@@ -70,7 +70,11 @@
     </dependency>
     <dependency>
       <groupId>io.netty</groupId>
-      <artifactId>netty-all</artifactId>
+      <artifactId>netty-handler</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>io.netty</groupId>
+      <artifactId>netty-transport-native-epoll</artifactId>
     </dependency>
     <dependency>
       <groupId>org.slf4j</groupId>