You mention proguard, so I assume you're building for Android? If you're running proguard, you shouldn't be seeing anything like a 2.3MB size from the guava dependency. You can see the proguard configuration for our Android interop test app here: https://github.com/grpc/grpc-java/blob/master/android-interop-testing/app/proguard-rules.pro .
With this configuration, our entire interop app APK after proguard is only 1.4MB, and the com.google.common.* dependencies from Guava are only 65.7KB. Eric On Fri, Mar 2, 2018 at 12:46 PM, 'Carl Mastrangelo' via grpc.io < grpc-io@googlegroups.com> wrote: > We (gRPC) avoid depending on anything in common.collect from guava, so in > theory you should be able to trim your deps down. I don't know about open > census's API. > > On Thursday, March 1, 2018 at 9:48:59 PM UTC-8, dknku...@gmail.com wrote: >> >> Hi Devs, >> >> Currently I am working on implementing gRPC support for my product. Since >> grpc-core has a transitive dependency to guava library. I need to include >> guava library alone with grpc libraries in my distribution. Since guava >> library size is around 2.3MB, I am trying to create miniature version of >> guava library using ProGuard[1]. >> >> After going through the gRPC-java code, identified following >> classes/packages are used in gRPC-core library and dependent opencensus-api, >> >> com.google.common.base.** >> >> com.google.common.util.concurrent.** >> >> com.google.common.collect.Maps >> >> com.google.common.collect.ImmutableMultiset >> >> com.google.common.collect.ImmutableList >> >> com.google.common.collect.HashMultiset >> >> com.google.common.collect.Lists >> >> com.google.common.collect.Multiset >> >> com.google.common.io.** >> >> >> I am able to create miniature version which is only 850kB size and it >> worked fine for the basic gRPC operation. I would like to know whether it >> is ok to create miniature guava version to work with gRPC or is there other >> recommended way. It would be great, if you can give me list of guava >> classes/packages(minimum version of Guava we require) used in gRPC. >> >> 1. https://github.com/google/guava/wiki/UsingProGuardWithGuava >> >> Appreciate your response. >> >> Thanks >> Danesh >> > -- > You received this message because you are subscribed to the Google Groups " > grpc.io" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to grpc-io+unsubscr...@googlegroups.com. > To post to this group, send email to grpc-io@googlegroups.com. > Visit this group at https://groups.google.com/group/grpc-io. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/grpc-io/34d19f2a-0a0a-4bec-8bd6-b8f177554e30%40googlegroups.com > <https://groups.google.com/d/msgid/grpc-io/34d19f2a-0a0a-4bec-8bd6-b8f177554e30%40googlegroups.com?utm_medium=email&utm_source=footer> > . > > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "grpc.io" group. To unsubscribe from this group and stop receiving emails from it, send an email to grpc-io+unsubscr...@googlegroups.com. To post to this group, send email to grpc-io@googlegroups.com. Visit this group at https://groups.google.com/group/grpc-io. To view this discussion on the web visit https://groups.google.com/d/msgid/grpc-io/CALUXJ7gP58kKHx-JmH9mXJpzQQZuvrfQbfF4ONHzH%2B0A-7-9PA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.