Reply
Highlighted
PNS
Explorer
Posts: 38
Registered: ‎05-20-2014

Propagating the morphline file path

Hi...

 

Is there an easy or recommended way of retrieving the path of the file from which a morphline has been compiled

(whenever it is compiled from a file)?

 

One can use the MorphlineContext class to save key-value pairs, including the file path, but the context is not accessible from

the Command object (although it is from the Pipe object).

 

Any other approach?

Cloudera Employee
Posts: 146
Registered: ‎08-21-2013

Re: Propagating the morphline file path

Try AbstractCommand.getContext()

Announcements
The Kite SDK is a collection of docs, sample code, APIs, and tools to make Hadoop application development faster. Learn more at http://kitesdk.org.