[JBoss Seam] - Re: I cannot get this test through, please help
by transvia
I found the test defaultly use datasource files under the folder project/bootstrap/deploy. I try to put mysql datasource file to this fold. But I get an error when the test is loaded:
org.jboss.deployers.spi.IncompleteDeploymentException: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):
|
| *** DEPLOYMENTS IN ERROR: Name -> Error
|
| vfsfile:/C:/workspace/tt/bootstrap/deploy/test-ds.xml -> java.lang.IllegalStateException: jboss.jca:name=DefaultDS,service=ManagedConnectionFactory is already installed.
|
|
| at org.jboss.embedded.Bootstrap.checkIncomplete(Bootstrap.java:144)
| at org.jboss.embedded.Bootstrap.bootstrapURL(Bootstrap.java:169)
| at org.jboss.embedded.Bootstrap.bootstrap(Bootstrap.java:201)
| at org.jboss.embedded.Bootstrap.bootstrap(Bootstrap.java:214)
| at org.jboss.seam.mock.EmbeddedBootstrap.startAndDeployResources(EmbeddedBootstrap.java:11)
| at org.jboss.seam.mock.BaseSeamTest.startJbossEmbeddedIfNecessary(BaseSeamTest.java:968)
| at org.jboss.seam.mock.BaseSeamTest.init(BaseSeamTest.java:893)
| at org.jboss.seam.mock.SeamTest.init(SeamTest.java:42)
| ... Removed 22 stack frames
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4088411#4088411
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4088411
18 years, 7 months
[JBossWS] - Re: Cannot find service endpoint target
by hansOtto
Sorry for my late response, but I was on vacation.
Thank you for the ideas.
Yes, the Error occur also with JbossWS 2.0.1.
I´ve taken the TestSample called 'webservice' of the JbossWS-native-2.0.1GA package and modified it by adding a simple TestBean with the @EJB annotation inside of the 'EJB3Bean01.java'. See the listing below:
[EJB3Bean01.java]
| .....
| public class EJB3Bean01 implements EJB3RemoteInterface
| {
| @EJB
| private TestBeanIntf testBean;
|
| @WebMethod
| public String echo(String input)
| {
| return testBean.printString();
| }
| }
[TestBean.java]
@Stateless
| @LocalBinding(jndiBinding = "TestBeanIntf")
| public class TestBean implements TestBeanIntf {
|
| public String printString(){
| return "Hello Peter!!";
| }
| }
This works very well, only if all classes are in the same package,
if you move the TestBean in another package, the Error I described in the startposting occur.
So, I think this is the problem.
Unfortunately, I have more than ten packages with several beans.
Should I create a new Jira Issue and add the whole zipped eclipse project as an attachment?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4088404#4088404
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4088404
18 years, 7 months
[JBoss jBPM] - jBPM 3.2 using CMT
by MSchmidke
Hello all,
the following post deals with one simple question: do I have to do something to tell JBoss to include the jBPM hibernate.cfg.xml when he bootstraps his own CMP hibernate configuration?
In detail:
I'm trying to get jBPM 3.2 running in a JBoss 4.2 application server. Mainly, I'm evaluating the question: should I use EJB3 entity beans or pure hibernate beans beneath jBPM (I want to use the same schema / datasource / transactions and I want to have own beand as process variables).
To achieve this, I've followed the wiki article http://wiki.jboss.org/wiki/Wiki.jsp?page=Jbpm32UsingCMT.
Unfortunately, it does not work at all. I've followed the instructions in the wiki article with absolutely no success.
My first disappointment was "createSchema", which only gives "You cannot commit during a managed transaction". I've googled a lot and finally found a french article which told me to call createSchema with a jbpmContext parameter, after having put an injected hibernate session into this context. Sounds plausible, but unfortunately, createSchema can't be called with a context parameter. Only with a context name parameter, which doesn't help much. Don't know which version of jBPM was used in France.
Ok, creating the schema is not that important. I've created the schema using the supplied scripts and skipped this step.
Next step was trying to deploy a process definition. Again I wrote in my stateless session bean:
| @PersistenceContext
| private Session session;
| public void deployProcessDefinition() {
| ProcessDefinition processDefinition = ProcessDefinition
| .parseXmlString("<process-definition name='hello world'>"
| + " <start-state name='start'>"
| + " <transition to='s' />" + " </start-state>"
| + " <state name='s'>" + " <transition to='end' />"
| + " </state>" + " <end-state name='end' />"
| + "</process-definition>");
|
| JbpmConfiguration jbpmConfiguration = JbpmConfiguration.getInstance();
| JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
| jbpmContext.setSession(session);
| jbpmContext.deployProcessDefinition(processDefinition);
| jbpmContext.close();
| }
|
Of course, I get an error, it's the following:
anonymous wrote :
| Named query not known: GraphSession.findLatestProcessDefinitionQuery
|
Some lines up in the log, he told me:
anonymous wrote :
| 14:34:29,065 INFO [Configuration] Reading mappings from resource : org/jbpm/db/hibernate.queries.hbm.xml
|
, and there is absolutely nothing suspicious in the log (I think).
It sounds to me that he has build a second Hibernate config, but setSession forces him to use JBoss' Hibernate config which does not contain the jBPM stuff.
I've taken the jbpm.cfg.xml and hibernate.cfg.xml from jbpm-enterprise.jar with only little modifications (in hibernate, I've put my own datasource, and in jbpm I changed the non-existent message and scheduler entries.
Altogether packaged in a rather basic EAR.
Can anybody help me?
Marcus.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4088402#4088402
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4088402
18 years, 7 months
[JBoss jBPM] - customTaskInstance example failing with error
by rossputin
Hi guys,
I tried to run 'ant test' in /jbpm-jpdl-3.2.1/examples/customTaskInstance today, and the same in 3.2.2, first of all it failed to compile, the 'compile.test' target seems to be failing, unless there is some config I need to do first.
Anyhow, after some tweaking of example.base.build.xml to make it work... see...
| <target name="create.manifest">
| <mkdir dir="target/META-INF" />
| <manifest file="target/META-INF/MANIFEST.MF">
| <attribute name="Implementation-Title" value="jBPM Core Library"/>
| <attribute name="Implementation-Version" value="${lib.jbpm.jpdl.version} (date:${now})"/>
| <attribute name="Implementation-URL" value="http://www.jboss.org/"/>
| <attribute name="Implementation-Vendor" value="JBoss Inc."/>
| <attribute name="Implementation-Vendor-Id" value="http://www.jboss.org/"/>
| </manifest>
| </target>
|
| <target name="package.jar" depends="compile, create.manifest">
| <jar jarfile="target/jbpm-custom-task.jar" manifest="target/META-INF/MANIFEST.MF">
| <fileset dir="target/classes" />
| </jar>
| </target>
|
I got the test running... but then it bombed out with the following error...
| org.jbpm.taskmgmt.exe.TaskInstance
|
| java.lang.ClassCastException: org.jbpm.taskmgmt.exe.TaskInstance
| at org.jbpm.taskinstance.CustomTaskControllerHandler.initializeTaskVariables(Unknown Source)
| at org.jbpm.taskmgmt.def.TaskController.initializeVariables(TaskController.java:82)
| at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
| at org.jbpm.taskmgmt.def.TaskController$$EnhancerByCGLIB$$edd862d3.initializeVariables()
| at org.jbpm.taskmgmt.exe.TaskInstance.initializeVariables(TaskInstance.java:149)
| at org.jbpm.taskmgmt.exe.TaskMgmtInstance.createTaskInstance(TaskMgmtInstance.java:131)
| at org.jbpm.graph.node.TaskNode.execute(TaskNode.java:168)
| at org.jbpm.graph.def.Node.enter(Node.java:319)
| at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
| at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$28c8528a.enter()
| at org.jbpm.graph.def.Transition.take(Transition.java:151)
| at org.jbpm.graph.def.Node.leave(Node.java:394)
| at org.jbpm.graph.node.StartState.leave(StartState.java:70)
| at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
| at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$28c8528a.leave()
| at org.jbpm.graph.exe.Token.signal(Token.java:195)
| at org.jbpm.graph.exe.Token.signal(Token.java:140)
| at org.jbpm.taskinstance.CustomTaskInstanceTest.createNewProcessInstance(Unknown Source)
| at org.jbpm.taskinstance.CustomTaskInstanceTest.testCustomTaskInstance(Unknown Source)
|
I left the hibernate.cfg.xml and jbpm.cfg.xml files untouched.
Possibly I was running the ant targets from the wrong place, or I forgot to configure something?
Anyhow, any help is greatly appreciated,
regards
Ross
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4088401#4088401
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4088401
18 years, 7 months