public class PassthroughDatumCounterProcessor extends Object implements org.apache.streams.core.StreamsProcessor
Modifier and Type | Field and Description |
---|---|
static Set<Integer> |
CLAIMED_ID
Set of all ids that have been claimed.
|
static ConcurrentHashMap<String,AtomicLong> |
COUNTS
The total count of data seen by a all instances of a processor.
|
static Random |
RAND
Random instance to generate ids
|
static Set<Integer> |
SEEN_DATA
Set of instance ids that received data.
|
static String |
STREAMS_ID |
Constructor and Description |
---|
PassthroughDatumCounterProcessor(String procId) |
Modifier and Type | Method and Description |
---|---|
void |
cleanUp() |
String |
getId() |
int |
getMessageCount() |
void |
prepare(Object configurationObject) |
List<org.apache.streams.core.StreamsDatum> |
process(org.apache.streams.core.StreamsDatum entry) |
public static final String STREAMS_ID
public static Set<Integer> CLAIMED_ID
public static final Random RAND
public static final Set<Integer> SEEN_DATA
public static final ConcurrentHashMap<String,AtomicLong> COUNTS
public PassthroughDatumCounterProcessor(String procId)
public String getId()
getId
in interface org.apache.streams.core.StreamsOperation
public List<org.apache.streams.core.StreamsDatum> process(org.apache.streams.core.StreamsDatum entry)
process
in interface org.apache.streams.core.StreamsProcessor
public void prepare(Object configurationObject)
prepare
in interface org.apache.streams.core.StreamsOperation
public void cleanUp()
cleanUp
in interface org.apache.streams.core.StreamsOperation
public int getMessageCount()
Copyright © 2017 The Apache Software Foundation. All rights reserved.