本文整理汇总了Java中storm.trident.operation.TridentOperationContext.numPartitions方法的典型用法代码示例。如果您正苦于以下问题:Java TridentOperationContext.numPartitions方法的具体用法?Java TridentOperationContext.numPartitions怎么用?Java TridentOperationContext.numPartitions使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类storm.trident.operation.TridentOperationContext
的用法示例。
在下文中一共展示了TridentOperationContext.numPartitions方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(Map conf, TridentOperationContext context) {
partitionNum = context.getPartitionIndex();
numPartitions = context.numPartitions();
myturn = partitionNum;
threshold = Double.valueOf((String) conf.get("THRESHOLD"));
}
示例2: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(Map conf, TridentOperationContext context) {
_agg.prepare(conf, context);
this.myPartitionIndex = context.getPartitionIndex();
this.totalPartitions = context.numPartitions();
}
示例3: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(Map conf, TridentOperationContext context) {
this.partitionIndex = context.getPartitionIndex();
this.numPartitions = context.numPartitions();
}
示例4: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(Map conf, TridentOperationContext context) {
this.partitionId = context.getPartitionIndex();
this.numPartitions = context.numPartitions();
}
示例5: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(final Map map, final TridentOperationContext tridentOperationContext) {
localPartition = tridentOperationContext.getPartitionIndex() + 1;
numPartitions = tridentOperationContext.numPartitions();
Logger.getAnonymousLogger().log(Level.INFO, MessageFormat.format("Preparing {0} for execution. Thread {1}.", getClass().getCanonicalName(), Thread.currentThread().getName()));
}
示例6: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(final Map map, final TridentOperationContext tridentOperationContext) {
localPartition = tridentOperationContext.getPartitionIndex() + 1;
numPartitions = tridentOperationContext.numPartitions();
}
示例7: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(final Map map, final TridentOperationContext tridentOperationContext) {
localPartition = tridentOperationContext.getPartitionIndex();
numPartitions = tridentOperationContext.numPartitions();
}
示例8: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(final Map map, final TridentOperationContext tridentOperationContext) {
this.partition = tridentOperationContext.getPartitionIndex() + 1;
this.numPartitions = tridentOperationContext.numPartitions();
}
示例9: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(final Map conf, final TridentOperationContext context) {
localPartition = context.getPartitionIndex() + 1;
numPartitions = context.numPartitions();
}
示例10: prepare
import storm.trident.operation.TridentOperationContext; //导入方法依赖的package包/类
@Override
public void prepare(Map conf, TridentOperationContext context) {
this.partitionIndex = context.getPartitionIndex();
this.numPartitions = context.numPartitions();
}