[jBPM] - Re: show user task forms in task client application
by reza sadeghzadeh
reza sadeghzadeh [http://community.jboss.org/people/reza_sadeghzadeh] created the discussion
"Re: show user task forms in task client application"
To view the discussion, visit: http://community.jboss.org/message/614301#614301
--------------------------------------------------------------
Hi Kris,
thanks for your reply,
I checked out the jbpm-gwt codes from github and read its codes.
I figured out that there is some classes like CommandDelegate,ProcessManager,... that they are the core of connection to repository and manage process.
I want to get list of ProcessDefinitions and ProcessInstances , so I did it:
get list of process definitions:
|
|
| List<ProcessDefinitionRef> processDefinitions = processManager.getProcessDefinitions(); |
that it works properly
but I want get list of process Instances:
List<ProcessDefinitionRef> processDefinitions = processManager.getProcessDefinitions();
for(ProcessDefinitionRef processDefinition : processDefinitions){
List<ProcessInstanceRef> processInstances = processManager.getProcessInstances(processDefinition.getId());
System.out.println("ProcessDefinition Id=" + processDefinition.getId() + " Size=" + processInstances.size() )
}
but the List is empty and no processInstances return.
I started some processInstances in jbpm-gwt console and I can see now list of them.
Would you please help me ?
Thanks
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/614301#614301]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
12 years, 11 months
[JBoss Microcontainer] - JBoss 6.0: ignore persistence.xml in jar file
by Gonne Martens
Gonne Martens [http://community.jboss.org/people/gonne] created the discussion
"JBoss 6.0: ignore persistence.xml in jar file"
To view the discussion, visit: http://community.jboss.org/message/611442#611442
--------------------------------------------------------------
Hello!
As Sergey I want to ignore the persistence.xml in a jar lib placed in the lib folder of my ear.
I tried to use the AbstractIgnoreDeployer by placing a jboss-ignore.txt file in ear/META-INF.
Structure of my ear:
playground.ear
\ lib
\ playgroundTool.jar
*\ META-INF\persistence.xml*
\ META-INF
\ jboss-ignore.txt
\ playgroundEJB.jar
\ META-INF\persistence.xml
\ other jars and wars
content of jboss-ignore.txt:
lib/playgroundTool.jar/META-INF/persistence.xml
Debugging of the AbstractIgnoreDeployer showed me that the jboss-ignore.txt file is parsed and creates an instance of CollectionNameIgnoreMechanism with "lib/playgroundTool.jar/META-INF/persistence.xml" as ignored path. I am not sure that this is correct, but through further debugging I could see that only the ignoreName() method is called once for the name persistence.xml of the playground.ear deployment unit (the variable ignoredNames is always null, so the method returns false). The method ignorePath is never called.
How should it work right?
Please help!
Kind regards,
Gonne
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/611442#611442]
Start a new discussion in JBoss Microcontainer at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
12 years, 11 months
[JBoss Web Services] - XmlSeeAlso usage
by jaroslav skraban
jaroslav skraban [http://community.jboss.org/people/jskraban] created the discussion
"XmlSeeAlso usage"
To view the discussion, visit: http://community.jboss.org/message/614186#614186
--------------------------------------------------------------
Hello @,
I have following problem with Jboss 5.1and WS Native 3.4.1
Wsdl defines lot of anyType that are mapped to Object in java. I provide schema that generates objects to be used as parameters. I created service from generated sei and tested it using soapui. I got failure that schema types are not known.
I included schema to wsdl and I see that generated sei contains ObjectFactory from the schema. Calling the operation fails again. I found out in the jaxws code that just ObjectFactory was added to the jaxb context and not referenced classes.
So I tried to extend generated sei, annotate it as necessary (also providing classes from schema again) and use this interface in my service as sei (service implements it and also @WebService(endpointInterface="new interface")). Again failure when testing. In code I see that XmlSeeAlso is checked during deployment (class JAXWSMetaDataBuilder) but during invocation only types from wsdl are taken into account and used for jaxb context construction (in EndpointMetadata.eagerInitializeTypes, JAXBSerializer.serialize)...
Looks like bug to me or did I missed something? Is there some workaround (maybe update wsdl or provide bindings)?
Thanks
Jaro
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/614186#614186]
Start a new discussion in JBoss Web Services at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
12 years, 11 months
[Beginner's Corner] - Struggling with injecting singleton in 6.0
by Robin Hughes
Robin Hughes [http://community.jboss.org/people/rhinmass] created the discussion
"Struggling with injecting singleton in 6.0"
To view the discussion, visit: http://community.jboss.org/message/597183#597183
--------------------------------------------------------------
Hello,
I am having trouble figuring out how to inject a singleton into another class - in this case a servlet.
My singleton looks like this:
package com.robin.ejb
import javax.ejb.Singleton;
import javax.ejb.Startup;
@Singleton
@Startup
public class HelloWorld
{
public HelloWorld()
{
System.out.println("constructing HelloWorld");
}
public String sayHello() {
return "Hello World !!!";
}
}
My servlet looks like this:
import ...
import com.robin.ejb.HelloWorld;
@WebServlet(name="helloServlet", urlPatterns={"/hello"},
initParams={ @WebInitParam(name="nameParam", value="world")})
public class HelloServlet extends HttpServlet {
private static final long serialVersionUID = 1L;
@Inject
private HelloWorld hw;
@Override
protected void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
PrintWriter out = response.getWriter();
String nameParam = request.getParameter("nameParam");
if (nameParam == null)
nameParam = getServletConfig().getInitParameter("nameParam");
out.println("hello " + nameParam + " " + hw.sayHello());
out.flush();
out.close();
}
}
When I run this in JBoss AS 6.0.0.Final I get the following errors:
2011-04-01 10:23:43,299 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] (Thread-2) Error installing to Start: name=vfs:///C:/jboss/jboss-6.0.0.Final/server/rbh/deploy/myapp-0.0.1.ear_WeldBootstrapBean state=Create: org.jboss.weld.exceptions.DeploymentException: WELD-001409 Ambiguous dependencies for type [HelloWorld] with qualifiers [@Default] at injection point [[field] @Inject private com.robin.webapp.HelloServlet.hw]. Possible dependencies [[Session bean [class com.robin.ejb.HelloWorld with qualifiers [@Any @Default]; local interfaces are [HelloWorld], Session bean [class com.robin.ejb.HelloWorld with qualifiers [@Any @Default]; local interfaces are [HelloWorld]]]
at org.jboss.weld.bootstrap.Validator.validateInjectionPoint(Validator.java:309) [:6.0.0.Final]
at org.jboss.weld.bootstrap.Validator.validateBean(Validator.java:139) [:6.0.0.Final]
at org.jboss.weld.bootstrap.Validator.validateRIBean(Validator.java:162) [:6.0.0.Final]
at org.jboss.weld.bootstrap.Validator.validateBeans(Validator.java:377) [:6.0.0.Final]
at org.jboss.weld.bootstrap.Validator.validateDeployment(Validator.java:363) [:6.0.0.Final]
at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:388) [:6.0.0.Final]
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/597183#597183]
Start a new discussion in Beginner's Corner at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
12 years, 11 months
[jBPM] - JPA Persistence and issues
by Marco Piraccini
Marco Piraccini [http://community.jboss.org/people/mpiraccini] created the discussion
"JPA Persistence and issues"
To view the discussion, visit: http://community.jboss.org/message/613967#613967
--------------------------------------------------------------
Hi guys,
Since I switched to the JPA Persistence, I have some weird issues:
1) When i get a ProcessInstance, it seems that the InternalKnowledgeRuntime is always null! That produces some NPE at runtime, for instance in:
at org.jbpm.workflow.instance.node.WorkItemNodeInstance.getWorkItem(WorkItemNodeInstance.java:65) when I execute: workItemNodeInstance.getWorkItem()
All I do is:
StatefulKnowledgeSession session =
JPAKnowledgeService.
newStatefulKnowledgeSession(knowledgeBase,
getKnowledgeSessionConfiguration(),
getEnvironment());
WorkflowProcessInstance processInstance = (WorkflowProcessInstance) session
.startProcess(processId, params);
processInstance.getKnowledgeRuntime().toString() // NPE!!!!!!!!!!!!!!
2) The ProcessInstance.getState() returns "STATE_ACTIVE" even when the process is (correctly) ended. All seems ok (the ProcessEventListener method are fired, etc)...but if I use the ProcessInstance getState() method to test the state, that returns always STATE_ACTIVE.
I'm using JBPM 5.1 final.
Marco.
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/613967#613967]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
12 years, 11 months