[
https://issues.apache.org/jira/browse/PIG-259?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12839887#action_12839887
]
Alan Gates commented on PIG-259:
--------------------------------
Thanks for the explanation, now I understand what you're doing. I'd like to
make one more suggestion. Could we do this in a separate interface that store
functions could choose to implement? One of our goals with PIG-966 was to make
the easy case of store functions easy, and put less commonly used features in
separate interfaces. This way implementing a new store function is less of a
burden. So could we add an interface like:
{code}
interface OverwritingLoadFunc {
/**
* whether the implementation support overwrite
*
* @return
*/
public boolean isOverWrite();
/**
* cleanup the old output if you want to overwrite
*
* @param store, the store information you would like to delete
* @param context, used for deletion operation
* @throws IOException
*/
public void cleanupOutput(POStore store, PigContext context) throws
IOException;
}
{code}
Also, I'm guessing your cleanupOutput method will need a Job and a store
location (like the recently added cleanupOnFailure call, see PIG-1265).
> allow store to overwrite existing directroy
> -------------------------------------------
>
> Key: PIG-259
> URL: https://issues.apache.org/jira/browse/PIG-259
> Project: Pig
> Issue Type: Sub-task
> Affects Versions: 0.8.0
> Reporter: Olga Natkovich
> Assignee: Jeff Zhang
> Fix For: 0.8.0
>
> Attachments: Pig_259.patch, Pig_259_2.patch, Pig_259_3.patch,
> Pig_259_4.patch
>
>
> we have users who are asking for a flag to overwrite existing directory
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.