Github user advancedxy commented on a diff in the pull request:

    https://github.com/apache/spark/pull/462#discussion_r11808574
  
    --- Diff: core/src/main/scala/org/apache/spark/api/java/JavaPairRDD.scala 
---
    @@ -119,7 +119,13 @@ class JavaPairRDD[K, V](val rdd: RDD[(K, V)])
       /**
        * Return a sampled subset of this RDD.
        */
    -  def sample(withReplacement: Boolean, fraction: Double, seed: Int): 
JavaPairRDD[K, V] =
    +  def sample(withReplacement: Boolean, fraction: Double): JavaPairRDD[K, 
V] =
    +    sample(withReplacement, fraction, System.nanoTime)
    +    
    +  /**
    +   * Return a sampled subset of this RDD.
    +   */
    +  def sample(withReplacement: Boolean, fraction: Double, seed: Long): 
JavaPairRDD[K, V] =
    --- End diff --
    
    Yes. It is more standard to use Long. But we just need to rewrite some code.
    We should ask about @mateiz or @pwendell for advice. Maybe they chosen Int 
for some reason we don't know.


---
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.
---

Reply via email to