GitHub user gatorsmile opened a pull request:

    https://github.com/apache/spark/pull/16372

    [SPARK-18949] [SQL] [BACKPORT-2.1] Add recoverPartitions API to Catalog

    ### What changes were proposed in this pull request?
    
    This PR is to backport https://github.com/apache/spark/pull/16356 to Spark 
2.1.1 branch.
    
    ----
    
    Currently, we only have a SQL interface for recovering all the partitions 
in the directory of a table and update the catalog. `MSCK REPAIR TABLE` or 
`ALTER TABLE table RECOVER PARTITIONS`. (Actually, very hard for me to remember 
`MSCK` and have no clue what it means)
    
    After the new "Scalable Partition Handling", the table repair becomes much 
more important for making visible the data in the created data source 
partitioned table.
    
    Thus, this PR is to add it into the Catalog interface. After this PR, users 
can repair the table by
    ```Scala
    spark.catalog.recoverPartitions("testTable")
    ```
    
    ### How was this patch tested?
    Modified the existing test cases.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/gatorsmile/spark repairTable2.1.1

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/16372.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #16372
    
----
commit 3ae670bc59284867ce5fefe052f55e909eb572fa
Author: gatorsmile <[email protected]>
Date:   2016-12-21T08:23:36Z

    fix.

----


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

Reply via email to