use of org.pentaho.di.trans.CheckStepsExtension in project pdi-dataservice-server-plugin by pentaho.
the class StepValidationExtensionPointPlugin method callExtensionPoint.
@Override
public void callExtensionPoint(LogChannelInterface log, Object o) throws KettleException {
if (!validInputs(o, log)) {
return;
}
CheckStepsExtension checkStepExtension = (CheckStepsExtension) o;
TransMeta transMeta = checkStepExtension.getTransMeta();
for (StepValidation stepValidation : getStepValidations()) {
StepMeta stepMeta = checkStepExtension.getStepMetas()[0];
if (stepValidation.supportsStep(stepMeta, log)) {
DataServiceMeta dataServiceMeta = metaStoreUtil.getDataServiceByStepName(transMeta, stepMeta.getName());
if (dataServiceMeta == null) {
// We won't validate Trans not associated with a DataService
return;
}
stepValidation.checkStep(checkStepExtension, dataServiceMeta, log);
}
}
}
use of org.pentaho.di.trans.CheckStepsExtension in project pdi-dataservice-server-plugin by pentaho.
the class BaseStepValidationTest method before.
@Before
public void before() throws KettleStepException {
stepMetas[0] = stepMeta;
space = new Variables();
checkStepsExtension = new CheckStepsExtension(remarks, space, transMeta, stepMetas, repository, metaStore);
pushDownOptMetas = new ArrayList<PushDownOptimizationMeta>();
when(dataServiceMeta.getPushDownOptimizationMeta()).thenReturn(pushDownOptMetas);
init();
}
Aggregations