[jboss-user] [jBPM Users] - Re: Using JBPM for document workflow in a Java/Flex CMS soft

mesa do-not-reply at jboss.com
Fri Oct 9 02:28:02 EDT 2009


i have done few things till now and will need bit help from kukeltje :)

i have integrated jcrTemplate using spring  and  now i am able to play with repository,able to add node and all.
 according to jbpm document i can add jcrnode as process variable.
now issue will come up once i try to retrieve store jcrNode from process variable ---

getObject() method is jcrNodeInstance.class says that jbpm will try to get configured services in its context and will try to find a jcrService and once service instance is found then few matching things will be performed and object can be retrieved.

Main problem left down is configuring a JCR Service is JBPMContext :

1) i tried extending jbpmContext and tried to add my service (Extending JcrService)

     @Override
	protected JbpmContext getContext() {
		JbpmContext context = super.getContext();
		context.getServices().getPersistenceService();
		context.getServices().setAuthenticationService(authenticationService);
		return context;
	}
    here i do not see anyway to attach a jcrService instance.

2) i then went to figure out a way in jbpm.cfg.xml . i checked that JackRabbitServiceFactory requires a configuration ----i think it is repository.xml and directory---may be home dir to create a service.

i am unable to configure service in jbpm.cfg.xml.
i added the service like this :::

     <jbpm-context>
    
    
    
    
       
        
          classpath:repository.xml
          /home/mayank/jackrabbit
        
       
       
  </jbpm-context>

i get :: unable to Parse jbpm.cfg.xml


Code of service factory says ::
protected synchronized Repository getRepository() {
    if (repository==null) {
      try {
        InputStream stream = ClassLoaderUtil.getStream(configuration);
        RepositoryConfig config = RepositoryConfig.create(stream, directory);
        repository = RepositoryImpl.create(config);
      } catch (Exception e) {
        // NOTE that Error's are not caught because that might halt the JVM and mask the original Error.
        throw new JbpmException("couldn't create new jackrabbit repository with configResource '"+configuration+"' and directory '"+directory+"'", e);
      }
    }
    return repository;
  }




can someone help on this .....

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4259522#4259522

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4259522



More information about the jboss-user mailing list