use of nl.nn.adapterframework.core.ISenderWithParameters in project iaf by ibissource.
the class SenderSeries method doSendMessage.
public String doSendMessage(String correlationID, String message, ParameterResolutionContext prc) throws SenderException, TimeOutException {
long t1 = System.currentTimeMillis();
for (Iterator<ISender> it = getSenderIterator(); it.hasNext(); ) {
ISender sender = it.next();
if (log.isDebugEnabled())
log.debug(getLogPrefix() + "sending correlationID [" + correlationID + "] message [" + message + "] to sender [" + sender.getName() + "]");
if (sender instanceof ISenderWithParameters) {
message = ((ISenderWithParameters) sender).sendMessage(correlationID, message, prc);
} else {
message = sender.sendMessage(correlationID, message);
}
long t2 = System.currentTimeMillis();
StatisticsKeeper sk = getStatisticsKeeper(sender);
sk.addValue(t2 - t1);
t1 = t2;
}
return message;
}
Aggregations