Skip to content

Commit

Permalink
Skipping wf processing during initial objects import.
Browse files Browse the repository at this point in the history
  • Loading branch information
mederly committed Oct 20, 2016
1 parent f486b2b commit 8e75c1e
Showing 1 changed file with 7 additions and 0 deletions.
Expand Up @@ -24,6 +24,7 @@
import com.evolveum.midpoint.model.api.hooks.HookRegistry;
import com.evolveum.midpoint.model.impl.lens.LensContext;
import com.evolveum.midpoint.prism.delta.ObjectDelta;
import com.evolveum.midpoint.schema.constants.SchemaConstants;
import com.evolveum.midpoint.schema.result.OperationResult;
import com.evolveum.midpoint.task.api.Task;
import com.evolveum.midpoint.util.exception.ObjectNotFoundException;
Expand Down Expand Up @@ -98,6 +99,12 @@ public <O extends ObjectType> HookOperationMode invoke(ModelContext<O> context,
return HookOperationMode.FOREGROUND;
}

if (SchemaConstants.CHANNEL_GUI_INIT_URI.equals(context.getChannel())) {
LOGGER.debug("Skipping workflow processing because the channel is '" + SchemaConstants.CHANNEL_GUI_INIT_URI + "'.");
result.recordSuccess();
return HookOperationMode.FOREGROUND;
}

logOperationInformation(context);

try {
Expand Down

0 comments on commit 8e75c1e

Please sign in to comment.