Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Plain View
Pig >> mail # user >> Question about properties for Loader


Copy link to this message
-
Question about properties for Loader
I'm trying to write a loader, extending LoadFunc, to read a specific
file format.

My question, how do I pass properties to it (for example the schema of
the file type I'm loading)?  Would it be using the -p parameter from
the cmdline when issuing the query?

The second part of the question is, how would I access the passed in
property/configuration from the code?  So far I'm theorizing it's
something like this:
        Properties p = udfc.getUDFProperties(this.getClass(), new
String[]{ contextSignature });
        Configuration conf = udfc.getJobConf();
Then get it from p or conf?

Thanks a lot for any pointers.

-Jeff
+
Prashant Kommireddi 2013-02-25, 00:02
+
Jeff Yuan 2013-02-25, 01:07
+
Dmitriy Ryaboy 2013-02-25, 03:24
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB