inline FluentIterable.of to be compatible with guava <18#67
Conversation
|
Can we shade guava? |
|
I'd rather not, would prefer to rewrite this to remove the Guava dep rather than shade just for this one liner. |
|
cool - just something to be wary of for all of our libraries that interact with spark/hadoop. guava versions always cause issues (hence spark shaded theirs). |
|
We use so little of the Guava library that forcing it to whatever version you need is probably fine in the current mode. If we force shading of the Guava Optional class then that sort of ruins how this gets used, so I'm pretty hesitant to do that. From: Patrick Woody <notifications@github.commailto:notifications@github.com> cool - just something to be wary of for all of our libraries that interact with spark/hadoop. guava versions always cause issues (hence spark shaded theirs). — |
|
any objections to merging this for a 0.7.1 release? |
| if (cls.equals(Optional.class)) { | ||
| FluentIterable<Class<?>> paramAnnotations = | ||
| FluentIterable.of(annotations[i]).transform(EXTRACT_CLASS); | ||
| FluentIterable.from(Lists.newArrayList(annotations[i])).transform(EXTRACT_CLASS); |
There was a problem hiding this comment.
ImmutableList.of(). whatever. do it next time
There was a problem hiding this comment.
went with inlining exactly what was in guava
public static FluentIterable of(E[] elements) {
return from(Lists.newArrayList(elements));
}
|
+1 |
|
can you rebase please, @Xenorith ? |
c668275 to
1c0d906
Compare
inline FluentIterable.of to be compatible with guava <18
No description provided.