in taverna-server-webapp/src/main/java/org/apache/taverna/server/master/localworker/AbstractRemoteRunFactory.java [349:377]
public TavernaRun create(UsernamePrincipal creator, Workflow workflow)
throws NoCreateException {
try {
Date now = new Date();
UUID id = randomUUID();
RemoteSingleRun rsr = getRealRun(creator, workflow, id);
RemoteRunDelegate run = new RemoteRunDelegate(now, workflow, rsr,
state.getDefaultLifetime(), runDB, id,
state.getGenerateProvenance(), this);
run.setSecurityContext(securityFactory.create(run, creator));
@Nonnull
URI feed = interactionFeedSupport.getFeedURI(run);
@Nonnull
URL feedUrl = feed.toURL();
@Nonnull
URL webdavUrl = baseurifactory.getRunUriBuilder(run)
.path(DIR + "/interactions").build().toURL();
@Nullable
URL pub = interactionFeedSupport.getLocalFeedBase(feed);
rsr.setInteractionServiceDetails(feedUrl, webdavUrl, pub);
return run;
} catch (NoCreateException e) {
log.warn("failed to build run instance", e);
throw e;
} catch (Exception e) {
log.warn("failed to build run instance", e);
throw new NoCreateException("failed to build run instance", e);
}
}