}
public void prepareData(ThrottlingDataContext dataContext) throws ThrottlingException {
dataProviderIterator.reset();
while (dataProviderIterator.hasNext()) {
final DataProvider dataProvider = (DataProvider) dataProviderIterator.next();
if (dataProvider == null) {
String msg =
"Error in invoking the data provider. " + "dataProviderConfigs is null or "
+ "data provider is not yet loaded";
log.error(msg);
throw new ThrottlingException(msg);
}
dataProvider.invoke(dataContext);
if (dataContext.isProcessingComplete()) {
break;
}
}
}