<div dir="ltr"><span style="font-family:arial,sans-serif;font-size:13px">Agree, until Java 8 arrives to masses, Guava is very useful.</span><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">

----</div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">Shading is certainly an option.</div><div style="font-family:arial,sans-serif;font-size:13px">

<br></div><div style="font-family:arial,sans-serif;font-size:13px">----</div><div style="font-family:arial,sans-serif;font-size:13px">I was wondering how much of Guava code we could strip by limiting to just the classes we use directly/transitively.</div>

<div style="font-family:arial,sans-serif;font-size:13px">With a minimal compilation (minimizeJar [1]) results are not convincing:</div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">

1437 classes (original guava) -&gt; 919 (minimized guava - limited to only what we use / use transitively)</div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">

Here is a configuration: <a href="https://gist.github.com/lfryc/b86d64c2a20843db0ec2" target="_blank">https://gist.github.com/lfryc/b86d64c2a20843db0ec2</a></div><div style="font-family:arial,sans-serif;font-size:13px"><br>

</div><div style="font-family:arial,sans-serif;font-size:13px">But no one says we do even need to use it minimizeJar. ;-)</div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">

<br></div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">

[1] <a href="http://maven.apache.org/plugins/maven-shade-plugin/shade-mojo.html#minimizeJar" target="_blank">http://maven.apache.org/plugins/maven-shade-plugin/shade-mojo.html#minimizeJar</a></div></div><div class="gmail_extra">

<br><br><div class="gmail_quote">On Wed, Feb 12, 2014 at 9:55 PM, Brian Leathem <span dir="ltr">&lt;<a href="mailto:bleathem@gmail.com" target="_blank">bleathem@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div class="">On Wed 12 Feb 2014 12:39:46 PM PST, Lukáš Fryč wrote:<br>
&gt;<br>
&gt; It would be nice to remove one more dependency.<br>
<br>
</div>+1.  I don&#39;t like the idea of dropping it altogether though.  Many of<br>
the abstractions it introduces are quite useful and lead to cleaner code.<br>
<div class=""><br>
&gt; On Tue, Feb 11, 2014 at 7:07 PM, Cody Lerum<br>
</div>&gt; &lt;<a href="mailto:richfaces-dev@lists.jboss.org">richfaces-dev@lists.jboss.org</a> &lt;mailto:<a href="mailto:richfaces-dev@lists.jboss.org">richfaces-dev@lists.jboss.org</a>&gt;&gt;<br>
<div class="">&gt; wrote:<br>
&gt;<br>
&gt; Maybe RF shouldn&#39;t depend on Guava or at a minimum shouldn&#39;t<br>
&gt; depend on anything annotated @Beta as Closables was<br>
&gt; (<a href="http://docs.guava-libraries.googlecode.com/git-history/v13.0.1/javadoc/index.html" target="_blank">http://docs.guava-libraries.googlecode.com/git-history/v13.0.1/javadoc/index.html</a>)<br>
<br>
</div>+1 for sticking to the stable API.<br>
<br>
We could re-explore the idea of shading guava into the richfaces jar<br>
under a different package name.  The downside here is it would be easy<br>
to forget about upgrading the library, however this would no longer<br>
effect user applications nor interact with leaky containers.<br>
<span class="HOEnZb"><font color="#888888"><br>
Brian<br>
</font></span></blockquote></div><br></div>