cascading.tap.hadoop
Class DistCacheTap

java.lang.Object
  extended by cascading.tap.Tap<Config,Input,Output>
      extended by cascading.tap.DecoratorTap<Void,JobConf,RecordReader,OutputCollector>
          extended by cascading.tap.hadoop.DistCacheTap
All Implemented Interfaces:
FlowElement, Traceable, Serializable

public class DistCacheTap
extends DecoratorTap<Void,JobConf,RecordReader,OutputCollector>

Class DistCacheTap is a Tap decorator for Hfs and can be used to move a file to the DistributedCache on read when accessed cluster side.

This is useful for HashJoins.

The distributed cache is only used when the Tap is used as a source. If the DistCacheTap is used as a sink, it will delegate to the provided parent instance and not use the DistributedCache.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class cascading.tap.DecoratorTap
metaInfo, original
 
Constructor Summary
DistCacheTap(Hfs parent)
          Constructs a new DistCacheTap instance with the given Hfs.
 
Method Summary
 TupleEntryIterator openForRead(FlowProcess<JobConf> flowProcess, RecordReader input)
           
 void sourceConfInit(FlowProcess<JobConf> process, JobConf conf)
           
 
Methods inherited from class cascading.tap.DecoratorTap
commitResource, createResource, createResource, deleteResource, deleteResource, flowConfInit, getConfigDef, getFullIdentifier, getFullIdentifier, getIdentifier, getMetaInfo, getModifiedTime, getModifiedTime, getOriginal, getScheme, getSinkFields, getSinkMode, getSourceFields, getStepConfigDef, getTrace, hasConfigDef, hasStepConfigDef, isEquivalentTo, isKeep, isReplace, isSink, isSource, isTemporary, isUpdate, openForRead, openForWrite, openForWrite, outgoingScopeFor, presentSinkFields, presentSourceFields, resolveIncomingOperationArgumentFields, resolveIncomingOperationPassThroughFields, resourceExists, resourceExists, retrieveSinkFields, retrieveSourceFields, rollbackResource, setMetaInfo, setOriginal, sinkConfInit, toString
 
Methods inherited from class cascading.tap.Tap
equals, hashCode, id, setScheme, taps
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DistCacheTap

public DistCacheTap(Hfs parent)
Constructs a new DistCacheTap instance with the given Hfs.

Parameters:
parent - an Hfs or GlobHfs instance representing a small file.
Method Detail

sourceConfInit

public void sourceConfInit(FlowProcess<JobConf> process,
                           JobConf conf)
Overrides:
sourceConfInit in class DecoratorTap<Void,JobConf,RecordReader,OutputCollector>

openForRead

public TupleEntryIterator openForRead(FlowProcess<JobConf> flowProcess,
                                      RecordReader input)
                               throws IOException
Overrides:
openForRead in class DecoratorTap<Void,JobConf,RecordReader,OutputCollector>
Throws:
IOException


Copyright © 2007-2014 Concurrent, Inc. All Rights Reserved.