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

    https://github.com/apache/spark/pull/1163#discussion_r14059227
  
    --- Diff: 
sql/core/src/main/scala/org/apache/spark/sql/parquet/ParquetRelation.scala ---
    @@ -44,10 +49,21 @@ import 
org.apache.spark.sql.catalyst.plans.logical.{LogicalPlan, LeafNode}
      * @param path The path to the Parquet file.
      */
     private[sql] case class ParquetRelation(
    -    val path: String,
    -    @transient val conf: Option[Configuration] = None) extends LeafNode 
with MultiInstanceRelation {
    +    path: String,
    +    @transient conf: Option[Configuration] = None)
    +  extends LeafNode
    +  with MultiInstanceRelation
    +  with SizeEstimatableRelation[SQLContext] {
    +
       self: Product =>
     
    +  def estimatedSize(context: SQLContext): Long = {
    --- End diff --
    
    Here we could probably estimate the size more accurately if we also had 
some semantic information, like which columns we wanted, as I believe Parquet 
stores stats for each column. Perhaps worthy of a TODO, this seems perfectly 
reasonable for now.


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to