[
https://issues.apache.org/jira/browse/S2GRAPH-237?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16601942#comment-16601942
]
Hwansung Yu commented on S2GRAPH-237:
-------------------------------------
[~steamshon]
I have send PR (https://github.com/apache/incubator-s2graph/pull/184).
Could you review? I checked the example works fine.
Thank you.
> Refactor unused variable on AnnoyIndexBuildSink class
> -----------------------------------------------------
>
> Key: S2GRAPH-237
> URL: https://issues.apache.org/jira/browse/S2GRAPH-237
> Project: S2Graph
> Issue Type: Bug
> Reporter: Hwansung Yu
> Assignee: Hwansung Yu
> Priority: Minor
>
> {code:java}
> val df = repartition(preprocess(inputDF),
> inputDF.sparkSession.sparkContext.defaultParallelism)
> if (inputDF.isStreaming) throw new IllegalStateException("AnnoyIndexBuildSink
> can not be run as streaming.")
> else {
> ALSModelProcess.buildAnnoyIndex(conf, inputDF)
> }
> {code}
> In "write" method of AnnoyIndexBuildSink class, variable "df" is never used.
> So, repartition does not working .
> I think that second parameter of buildAnnoyIndex shoule be "df", not
> "inputDF".
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)