Github user srowen commented on a diff in the pull request:
https://github.com/apache/spark/pull/8451#discussion_r37954938
--- Diff:
mllib/src/test/java/org/apache/spark/mllib/feature/JavaWord2VecSuite.java ---
@@ -50,9 +50,9 @@ public void tearDown() {
@SuppressWarnings("unchecked")
public void word2Vec() {
// The tests are to check Java compatibility.
- String sentence = Strings.repeat("a b ", 100) + Strings.repeat("a c ",
10);
- List<String> words = Lists.newArrayList(sentence.split(" "));
- List<List<String>> localDoc = Lists.newArrayList(words, words);
+ String sentence = StringUtils.repeat("a b ", 100) +
StringUtils.repeat("a c ", 10);
--- End diff --
There are a few issues here. This is using Commons Lang 2.x and would be
better to use 3.x (`commons.lang3.*`). However, Spark doesn't generally depend
on either of them; a few modules do but not MLlib. This happens to work because
of transitive dependencies. Since we definitely do depend on Guava, and that
won't go anywhere soon, and this is an internal use anyway, I think I might
leave out this change.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]