You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pig.apache.org by Sajid Raza <wi...@gmail.com> on 2013/08/16 23:22:22 UTC

Modify PigStorage to load schema from alternate location?

Would it be reasonable if I modified PigStorage to read a schema from a
user specified location? The default would be the same as it is today.

Having this feature would certainly help when I need to read a dataset that
I don't own and whose schema is kept in a separate location.

Re: Modify PigStorage to load schema from alternate location?

Posted by Prashant Kommireddi <pr...@gmail.com>.
Also, as Cheolsoo suggested on the other email - you have the option to
extend PigStorage and override storeSchema/getSchema


On Fri, Aug 16, 2013 at 2:44 PM, Prashant Kommireddi <pr...@gmail.com>wrote:

> Hi Sajid,
>
> I don't see any objections to that. This would probably have to be a
> config driven behavior. I remember having added a constructor to
> JsonMetadata that lets you specify different schema/header file names.
>
> Are you looking to change how the schema file is looked-up currently?
>
> Thanks,
> Prashant
>
>
> On Fri, Aug 16, 2013 at 2:22 PM, Sajid Raza <wi...@gmail.com> wrote:
>
>> Would it be reasonable if I modified PigStorage to read a schema from a
>> user specified location? The default would be the same as it is today.
>>
>> Having this feature would certainly help when I need to read a dataset
>> that
>> I don't own and whose schema is kept in a separate location.
>>
>
>

Re: Modify PigStorage to load schema from alternate location?

Posted by Prashant Kommireddi <pr...@gmail.com>.
Hi Sajid,

I don't see any objections to that. This would probably have to be a config
driven behavior. I remember having added a constructor to JsonMetadata that
lets you specify different schema/header file names.

Are you looking to change how the schema file is looked-up currently?

Thanks,
Prashant


On Fri, Aug 16, 2013 at 2:22 PM, Sajid Raza <wi...@gmail.com> wrote:

> Would it be reasonable if I modified PigStorage to read a schema from a
> user specified location? The default would be the same as it is today.
>
> Having this feature would certainly help when I need to read a dataset that
> I don't own and whose schema is kept in a separate location.
>