Package org.pentaho.di.trans
Class SlaveStepCopyPartitionDistribution
- java.lang.Object
-
- org.pentaho.di.trans.SlaveStepCopyPartitionDistribution
-
public class SlaveStepCopyPartitionDistribution extends Object
This class keeps track of which step copy in which transformation is responsible for handling a certain partition nr. This distribution is created BEFORE the slave transformations are sent to the slave servers. As such, it will be easy to link a step copy on a certain slave server uniquely to a certain partition. That is to say, it will be done the same way accross the complete cluster.- Author:
- matt
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
SlaveStepCopyPartitionDistribution.SlaveStepCopy
-
Constructor Summary
Constructors Constructor Description SlaveStepCopyPartitionDistribution()
SlaveStepCopyPartitionDistribution(Node node)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
addPartition(String slaveServerName, String partitionSchemaName, int stepCopyNr)
Add a partition number to the distribution if it doesn't already exist.void
addPartition(String slaveServerName, String partitionSchemaName, int stepCopyNr, int partitionNr)
Add a partition number to the distribution for re-use at runtime.boolean
equals(Object o)
Map<SlaveStepCopyPartitionDistribution.SlaveStepCopy,Integer>
getDistribution()
List<PartitionSchema>
getOriginalPartitionSchemas()
int
getPartition(String slaveServerName, String partitionSchemaName, int stepCopyNr)
String
getXML()
int
hashCode()
void
setOriginalPartitionSchemas(List<PartitionSchema> originalPartitionSchemas)
-
-
-
Field Detail
-
XML_TAG
public static final String XML_TAG
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
SlaveStepCopyPartitionDistribution
public SlaveStepCopyPartitionDistribution()
-
SlaveStepCopyPartitionDistribution
public SlaveStepCopyPartitionDistribution(Node node)
-
-
Method Detail
-
addPartition
public void addPartition(String slaveServerName, String partitionSchemaName, int stepCopyNr, int partitionNr)
Add a partition number to the distribution for re-use at runtime.- Parameters:
slaveServerName
-partitionSchemaName
-stepCopyNr
-partitionNr
-
-
addPartition
public int addPartition(String slaveServerName, String partitionSchemaName, int stepCopyNr)
Add a partition number to the distribution if it doesn't already exist.- Parameters:
slaveServerName
-partitionSchemaName
-stepCopyNr
-- Returns:
- The found or created partition number
-
getPartition
public int getPartition(String slaveServerName, String partitionSchemaName, int stepCopyNr)
-
getXML
public String getXML()
-
getDistribution
public Map<SlaveStepCopyPartitionDistribution.SlaveStepCopy,Integer> getDistribution()
-
getOriginalPartitionSchemas
public List<PartitionSchema> getOriginalPartitionSchemas()
- Returns:
- the originalPartitionSchemas
-
setOriginalPartitionSchemas
public void setOriginalPartitionSchemas(List<PartitionSchema> originalPartitionSchemas)
- Parameters:
originalPartitionSchemas
- the originalPartitionSchemas to set
-
-