Package org.jbpm

Examples of org.jbpm.PvmException


          log.finer("retry sleeping got interrupted");
        }
        sleepTime *= delayFactor;
      }
    }
    throw new PvmException("gave up after "+attempt+" attempts");
  }
View Full Code Here


    } catch (RuntimeException e) {
      log.log(Level.SEVERE, "exception while executing command "+command, e);
      throw e;
    } catch (Exception e) {
      log.log(Level.SEVERE, "exception while executing command "+command, e);
      throw new PvmException("exception while executing command "+command, e);
    }
  }
View Full Code Here

  /** parses the domain object from an inputSource and collects the problems in the given {@link Parse}.
   * @throws PvmException when parse is null.
   */
  public Object parseInputSource(InputSource inputSource, Parse parse) {
    if (parse==null) {
      throw new PvmException("parse is null");
    }
    if (inputSource==null) {
      parse.addProblem("no inputSource");
      return null;
    }
View Full Code Here

    String configurationResource = getInitParameter("jbpm.configuration.resource", "jbpm.cfg.xml");
    EnvironmentFactory environmentFactory = EnvironmentFactory.parseResource(configurationResource);
    Context applicationContext = (Context) environmentFactory;
    jobExecutor = applicationContext.get(JobExecutor.class);
    if (jobExecutor==null) {
      throw new PvmException("no job executor configured in resource "+configurationResource);
    }
    jobExecutor.start();
  }
View Full Code Here

  public Object execute(Environment environment) throws Exception {
    PvmDbSession pvmDbSession = environment.get(PvmDbSession.class);
   
    String name = processDefinition.getName();
    if (name==null) {
      throw new PvmException("process must have a name to deploy it");
    }
   
    int version = processDefinition.getVersion();
   
    if (pvmDbSession.findProcessDefinition(name, version)!=null) {
      throw new PvmException("process ["+name+"|"+version+"] already exists");
    }
   
    pvmDbSession.save(processDefinition);

    return processDefinition;
View Full Code Here

  List<JobHistoryEntry> history = new ArrayList<JobHistoryEntry>();
 
  /** starts the {@link DispatcherThread} and {@link JobExecutorThread}s for this job executor */
  public synchronized void start() {
    if (commandService==null) {
      throw new PvmException("no command executor available in job executor");
    }
    if (! isActive) {
      acquireJobsCommand = new AcquireJobs(this);
      nextDueDateCommand = new NextDueDate(this);
     
View Full Code Here

  public UrlEntity(String resource, ClassLoader classLoader) {
    this.url = classLoader.getResource(resource);
    if (url!=null) {
      this.systemId = url.toString();
    } else {
      throw new PvmException("couldn't create Entity from resource "+resource);
    }
  }
View Full Code Here

      InputStream stream = url.openStream();
      InputSource inputSource = new InputSource(stream);
      inputSource.setSystemId(systemId);
      return inputSource;
    } catch (IOException e) {
      throw new PvmException("couldn't open stream from url "+url, e);
    }
  }
View Full Code Here

public class FilterListener implements Listener {
  Listener listener;
  List<String> eventNames;
 
  public FilterListener(Listener listener, String eventName) {
    if (listener==null) throw new PvmException("listener is null");
    this.listener = listener;
    if (eventName==null) throw new PvmException("eventName is null");
    this.eventNames = new ArrayList<String>();
    this.eventNames.add(eventName);
  }
View Full Code Here

    this.eventNames = new ArrayList<String>();
    this.eventNames.add(eventName);
  }

  public FilterListener(Listener listener, List<String> eventNames) {
    if (listener==null) throw new PvmException("listener is null");
    this.listener = listener;
    if (eventNames==null) throw new PvmException("eventNames is null");
    this.eventNames = eventNames;
  }
View Full Code Here

TOP

Related Classes of org.jbpm.PvmException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.