A platform for high-performance distributed tool and library development written in C++. It can be deployed in two different cluster modes: standalone or distributed. API for v0.5.0, released on June 13, 2018.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
pdb::HashPartitionSink< KeyType, ValueType > Class Template Reference

#include <HashPartitionSink.h>

+ Inheritance diagram for pdb::HashPartitionSink< KeyType, ValueType >:
+ Collaboration diagram for pdb::HashPartitionSink< KeyType, ValueType >:

Public Member Functions

 HashPartitionSink (int numPartitions, int numNodes, TupleSpec &inputSchema, TupleSpec &attsToOperateOn)
 
Handle< ObjectcreateNewOutputContainer () override
 
void writeOut (TupleSetPtr input, Handle< Object > &writeToMe) override
 
 ~HashPartitionSink ()
 
- Public Member Functions inherited from pdb::ComputeSink
virtual ~ComputeSink ()
 

Private Attributes

int whichAttToHash
 
int whichAttToStore
 
int numPartitions
 
int numNodes
 

Detailed Description

template<class KeyType, class ValueType>
class pdb::HashPartitionSink< KeyType, ValueType >

Definition at line 34 of file HashPartitionSink.h.

Constructor & Destructor Documentation

template<class KeyType , class ValueType >
pdb::HashPartitionSink< KeyType, ValueType >::HashPartitionSink ( int  numPartitions,
int  numNodes,
TupleSpec inputSchema,
TupleSpec attsToOperateOn 
)
inline

constructor.

Parameters
numPartitionsnumber of partitions in the cluster
inputSchemathe schema of input tuple set
attToOperateOnthe column that we want to partition and keep

Definition at line 45 of file HashPartitionSink.h.

+ Here is the call graph for this function:

template<class KeyType , class ValueType >
pdb::HashPartitionSink< KeyType, ValueType >::~HashPartitionSink ( )
inline

Definition at line 126 of file HashPartitionSink.h.

Member Function Documentation

template<class KeyType , class ValueType >
Handle<Object> pdb::HashPartitionSink< KeyType, ValueType >::createNewOutputContainer ( )
inlineoverridevirtual

create container for output

Returns
: a new container for partitioned output

Implements pdb::ComputeSink.

Definition at line 67 of file HashPartitionSink.h.

template<class KeyType , class ValueType >
void pdb::HashPartitionSink< KeyType, ValueType >::writeOut ( TupleSetPtr  input,
Handle< Object > &  writeToMe 
)
inlineoverridevirtual

partition the input tuple set, and store the partitioned result to the output container

Parameters
inputthe input tuple set
writeToMethe output container

Implements pdb::ComputeSink.

Definition at line 87 of file HashPartitionSink.h.

+ Here is the call graph for this function:

Member Data Documentation

template<class KeyType , class ValueType >
int pdb::HashPartitionSink< KeyType, ValueType >::numNodes
private

Definition at line 140 of file HashPartitionSink.h.

template<class KeyType , class ValueType >
int pdb::HashPartitionSink< KeyType, ValueType >::numPartitions
private

Definition at line 137 of file HashPartitionSink.h.

template<class KeyType , class ValueType >
int pdb::HashPartitionSink< KeyType, ValueType >::whichAttToHash
private

Definition at line 131 of file HashPartitionSink.h.

template<class KeyType , class ValueType >
int pdb::HashPartitionSink< KeyType, ValueType >::whichAttToStore
private

Definition at line 134 of file HashPartitionSink.h.


The documentation for this class was generated from the following file: