[JBoss jBPM] - Re: Storage of process variables outside jbpm?
by the_dude
"kukeltje" wrote :
| Transactions were managed by the appserver. We configured hibernate to use the appserver transactions and used 2 datasources,
| one for jBPM, one for our own data. They used the same connetionpool so no XA issues arose.
|
Mhm. What about your HQL statements? I haven't manage to build the solution you describe* (two datasources + appserver transactions)
but create my domain model inside the jbpm schema. In doing so I run into recreating all HQL statements for selecting task instances
by some variable value which could be quite time demanding. How do you handle this?
Something different: I have to use several processdefinitions and wonder how to organize my data. These options come into my mind:
a) Put all, processdefinitions and domain data inside one datasource and write the domain data, depending on the process it is connected to to different tables
b) Do the same as in a) but use one datasource per processdefinition
c) Use two datasources put the jbpm data in one and the domain data in the other datasource
d) Use one datasource for jbpm data and one datasource for domain model for each processdefinition (== 2 datasources per processdefinition)
I tend to give c) a try [if I figure out how ;-)] but don't know about performance or other issues.
What do you think?
* Could you describe it in detail how you've done this or give some links, hints & snippets?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3974522#3974522
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3974522
19 years, 7 months
[Installation, Configuration & Deployment] - Error running a portal application in Windows XP
by soundarya
I am using a Hypersonic sqldb. I get this error in Windows XP but not in Windows 2000. What is the workaround for this?
javax.persistence.PersistenceException: org.hibernate.exception.SQLGrammarException: could not execute query
Caused by: java.sql.SQLException: Table not found in statement [select license0_.id as id69_, license0_.date as date69_, license0_.key as key69_, license0_.expirationDate as expirati4_69_ from License license0_]
at org.hsqldb.jdbc.Util.throwError(Unknown Source)
at org.hsqldb.jdbc.jdbcPreparedStatement.(Unknown Source)
at org.hsqldb.jdbc.jdbcConnection.prepareStatement(Unknown Source)
at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.doPrepareStatement(BaseWrapperManagedConnection.java:349)
at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.prepareStatement(BaseWrapperManagedConnection.java:337)
at org.jboss.resource.adapter.jdbc.WrappedConnection.prepareStatement(WrappedConnection.java:187)
at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatcher.java:497)
at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatcher.java:415)
at org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:139)
at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1561)
at org.hibernate.loader.Loader.doQuery(Loader.java:661)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)
at org.hibernate.loader.Loader.doList(Loader.java:2145)
... 271 more
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3974516#3974516
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3974516
19 years, 7 months
[Installation, Configuration & Deployment] - Deployment issues...
by jactor
I have used the installer (patch 1) to setup a configuration of JBoss which use 'all' and 'ejb3'. That is to say that I first setup jboss with the 'all' configuration and then setup jboss with the 'ejb3' confiiguration. I use the same configuration name for both setups.
I hope this is the correct procedure, but I am not sure if this is what is meant at the download page:
anonymous wrote : If you want to use EJB3 or Seam, you MUST download the xxxx-installer.jar installer file. You need to run the installer by double clicking on it or executing java -jar xxxx-installer.jar. Choose the ejb3 or ejb3-clustering profile when asked. JDK 5.0 is required.
The problem is: When I copy a jar-file to the deploy folder, nothing happens. I am waiting for its deployment, but nada... If this procedure of setting up a server with all services which use ejb 3 is not correct, please explain me the righ procedure...
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3974514#3974514
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3974514
19 years, 7 months
[JNDI/Naming/Network] - Re: PortableRemoteObject.narrow() returns null
by GBardou
Hi all,
I got exactly the same issue with JBoss 4.0.3SP1 or 4.0.4 with JDK 1.5.
Here are my info logs :
12:26:51,125 INFO [EjbModule] Deploying StatelessEjb
12:26:51,593 INFO [StatelessEjb] CORBA interface repository for StatelessEjb: IOR:000000000000002149444C3A6F6D672E6F72672F434F5242412F5265706F7369746
F72793A312E300000000000000002000000000000006C000102000000000E31302E3135312E33332E313137000DC8000000154A426F73732F49522F53746174656C657373456A620000000
00000020000000000000008000000004A414300000000010000001C00000000000100010000000105010001000101090000000105010001000000010000002C00000000000000010000000
10000001C00000000000100010000000105010001000101090000000105010001
12:26:51,671 INFO [StatelessEjb] EJBHome reference for StatelessEjb:
IOR:000000000000003D524D493A6F72672E73657373696F6E2E696E74657266616365732E53746174656C657373456A62486F6D653A303030303030303030303030303030300000000000
00000200000000000000B3000102000000000E31302E3135312E33332E313137000DC8000000214A426F73732F454A42486F6D65262553746174656C657373456A622FACED000570000000
000000030000000000000008000000004A414300000000010000001C000000000001000100000001050100010001010900000001050100010000001900000033000000000000002B687474
703A2F2F414F465231313432363A383038332F576562434C5B53746174656C657373456A625D2F000000000001000000670000000000000002000000010000001C00000000000100010000
0001050100010001010900000001050100010000001900000033000000000000002B687474703A2F2F414F465231313432363A383038332F576562434C5B53746174656C657373456A625D
2F00
12:26:51,687 INFO [StatelessEjb] Home IOR for StatelessEjb bound to iiop/StatelessEjb in JNP naming service
12:26:51,734 INFO [naming] re-Bound name: StatelessEjb
12:26:51,734 INFO [StatelessEjb] Home IOR for StatelessEjb bound to StatelessEjb in CORBA naming service
12:26:51,765 INFO [EJBDeployer] Deployed: file:/D:/Logiciels/jboss/jboss-3.2.5DGI/server/all/tmp/deploy/tmp32240SoucheJBossEdfTest.ear-contents/jar/S
oucheJBossEdfTest_ejb.jar
12:26:51,781 INFO [TomcatDeployer] deploy, ctxPath=/xxxxx, warUrl=file:/xxxxxx.ear-contents/war/xxxxx.war/
12:26:51,921 INFO [EARDeployer] Started J2EE application: file:/xxxxx.ear
12:27:11,718 INFO [interceptors] InterceptorManager started with 0 SIs, 0 CIs and 2 IORIs
12:27:11,734 INFO [STDOUT] StatelessEjb
12:27:11,750 INFO [STDOUT] org.jacorb.orb.Reference [interface java.rmi.Remote]
12:27:11,750 INFO [STDOUT] IOR:000000000000003D524D493A6F72672E73657373696F6E2E696E74657266616365732E53746174656C657373456A62486F6D653A30303030303030
303030303030303030000000000000000200000000000000B3000102000000000E31302E3135312E33332E313137000DC8000000214A426F73732F454A42486F6D65262553746174656C65
7373456A622FACED000570000000000000030000000000000008000000004A414300000000010000001C000000000001000100000001050100010001010900000001050100010000001900
000033000000000000002B687474703A2F2F414F465231313432363A383038332F576562434C5B53746174656C657373456A625D2F00000000000100000067000000000000000200000001
0000001C000000000001000100000001050100010001010900000001050100010000001900000033000000000000002B687474703A2F2F414F465231313432363A383038332F576562434C
5B53746174656C657373456A625D2F00
12:27:11,750 INFO [STDOUT] null
Can someone already fixed that ? how ?
I have no exception, but my home is NULL after calling narrow.
Regards,
Gilles.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3974511#3974511
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3974511
19 years, 7 months
[EJB 3.0] - Default JNDI Naming
by nomike
Hi!
I'm currently exploring EJB 3.0 using the Book "Mastering EJB 3.0 4th Edition".
I have written a small test-session-bean.
It consists of the following:
MyMath.java
| package at.tac.ejb3.test.mymath;
|
| /**
| * @author michael
| * @version 0.1.0.0 27.09.2006
| */
| public interface MyMath {
| public Integer sum(Integer a, Integer b);
| }
|
MyMathBean.java
| /**
| *
| * @author michael
| * @version 0.1.0.0 27.09.2006
| */
| package at.tac.ejb3.test.mymath;
|
| import javax.ejb.Stateless;
| import javax.ejb.Remote;
| import javax.ejb.Local;
|
| @Stateless
| @Remote(MyMath.class)
| @Local(MyMath.class)
| public class MyMathBean implements MyMath{
| public Integer sum(Integer a, Integer b) {
| return a + b;
| }
| }
|
It has no ejb-jar.xml and the jboss.xml, persistence.xml and jbosscmp-jdbc.xml don't contain any valuable data.
My first Question now: What is the name of my "Bean" now? "MyMath" or "MyMathBean"?
In the book I read anonymous wrote : The EJB 3.0 specification mandates that containers bind beans to the JNDI tree by their fully qualified names at deployment time. This ensures that we can look up the beans in a very simple way.
But when I invoke list() on the JNDIView Bean using jmx-console I get:
| java: Namespace
| +- XAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
| +- DefaultDS (class: org.jboss.resource.adapter.jdbc.WrapperDataSource)
| +- SecurityProxyFactory (class: org.jboss.security.SubjectSecurityProxyFactory)
| +- DefaultJMSProvider (class: org.jboss.jms.jndi.JNDIProviderAdapter)
| +- comp (class: javax.naming.Context)
| +- JmsXA (class: org.jboss.resource.adapter.jms.JmsConnectionFactoryImpl)
| +- ConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
| +- jaas (class: javax.naming.Context)
| | +- other (class: org.jboss.security.plugins.SecurityDomainContext)
| | +- HsqlDbRealm (class: org.jboss.security.plugins.SecurityDomainContext)
| | +- jbossmq (class: org.jboss.security.plugins.SecurityDomainContext)
| | +- JmsXARealm (class: org.jboss.security.plugins.SecurityDomainContext)
| +- timedCacheFactory (class: javax.naming.Context)
| Failed to lookup: timedCacheFactory, errmsg=org.jboss.util.TimedCachePolicy
| +- TransactionPropagationContextExporter (class: org.jboss.tm.TransactionPropagationContextFactory)
| +- StdJMSPool (class: org.jboss.jms.asf.StdServerSessionPoolFactory)
| +- Mail (class: javax.mail.Session)
| +- comp.ejb3 (class: javax.naming.Context)
| | NonContext: null
| +- TransactionPropagationContextImporter (class: org.jboss.tm.TransactionPropagationContextImporter)
| +- TransactionManager (class: org.jboss.tm.TxManager)
|
| Global JNDI Namespace
| +- XAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
| +- TopicConnectionFactory (class: org.jboss.naming.LinkRefPair)
| +- EventDispatcher (class: org.jboss.ws.eventing.mgmt.DispatcherDelegate)
| +- UserTransactionSessionFactory (proxy: $Proxy42 implements interface org.jboss.tm.usertx.interfaces.UserTransactionSessionFactory)
| +- UIL2ConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
| +- UIL2XAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
| +- QueueConnectionFactory (class: org.jboss.naming.LinkRefPair)
| +- topic (class: org.jnp.interfaces.NamingContext)
| | +- testDurableTopic (class: org.jboss.mq.SpyTopic)
| | +- testTopic (class: org.jboss.mq.SpyTopic)
| | +- securedTopic (class: org.jboss.mq.SpyTopic)
| +- queue (class: org.jnp.interfaces.NamingContext)
| | +- A (class: org.jboss.mq.SpyQueue)
| | +- testQueue (class: org.jboss.mq.SpyQueue)
| | +- ex (class: org.jboss.mq.SpyQueue)
| | +- DLQ (class: org.jboss.mq.SpyQueue)
| | +- D (class: org.jboss.mq.SpyQueue)
| | +- C (class: org.jboss.mq.SpyQueue)
| | +- B (class: org.jboss.mq.SpyQueue)
| +- MyMathBean (class: org.jnp.interfaces.NamingContext)
| | +- local (proxy: $Proxy73 implements interface at.tac.ejb3.test.mymath.MyMath,interface org.jboss.ejb3.JBossProxy,interface javax.ejb.EJBLocalObject)
| | +- remote (proxy: $Proxy72 implements interface at.tac.ejb3.test.mymath.MyMath,interface org.jboss.ejb3.JBossProxy,interface javax.ejb.EJBObject)
| +- ConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
| +- UserTransaction (class: org.jboss.tm.usertx.client.ClientUserTransaction)
| +- jmx (class: org.jnp.interfaces.NamingContext)
| | +- invoker (class: org.jnp.interfaces.NamingContext)
| | | +- RMIAdaptor (proxy: $Proxy36 implements interface org.jboss.jmx.adaptor.rmi.RMIAdaptor,interface org.jboss.jmx.adaptor.rmi.RMIAdaptorExt)
| | +- rmi (class: org.jnp.interfaces.NamingContext)
| | | +- RMIAdaptor[link -> jmx/invoker/RMIAdaptor] (class: javax.naming.LinkRef)
| +- UILXAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
| +- UILConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
|
and JBoss throws an error to the console:
| 13:46:33,895 ERROR [JNDIView] JNDIView.getHAJndiAttributes() failed
| java.lang.NullPointerException: name cannot be null
| at javax.management.ObjectName.construct(ObjectName.java:342)
| at javax.management.ObjectName.<init>(ObjectName.java:1304)
| at org.jboss.naming.JNDIView.getHAJndiAttributes(JNDIView.java:836)
| at org.jboss.naming.JNDIView.getHAUrl(JNDIView.java:811)
| at org.jboss.naming.JNDIView.list(JNDIView.java:193)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
| at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
| at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
| at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
| at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
| at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
| at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
| at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
| at org.jboss.jmx.adaptor.control.Server.invokeOpByName(Server.java:258)
| at org.jboss.jmx.adaptor.control.Server.invokeOp(Server.java:223)
| at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.invokeOp(HtmlAdaptorServlet.java:262)
| at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.processRequest(HtmlAdaptorServlet.java:100)
| at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.doPost(HtmlAdaptorServlet.java:82)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
| at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
| at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
| at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
| at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
| at java.lang.Thread.run(Thread.java:595)
|
So what do I have to do to get
context.lookup(MyMath.class.getName()); or
context.lookup(MyMathBean.class.getName()); (I don't know which is right)
working as in the book?
thx in advance
nomike aka Michael Postmann
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3974509#3974509
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3974509
19 years, 7 months
[Persistence, JBoss/CMP, Hibernate, Database] - RelationSet.getIdList() -> working with Relation Sets
by Oyabun
Hi!
According to the that comment below, it is not possible to work with relation sets, if the calling method ist executed with tx = null.
The getIdList() requires a tx or else the setHandle is always null -> which means that JBOSS (4.0.2) does not allow something like person.getRelatives().iterator() if the tx is null.
Can someone confirm this?
public class RelationSet implements Set {
| private JDBCCMRFieldBridge cmrField;
| private EntityEnterpriseContext ctx;
| private List[] setHandle;
| private Class relatedLocalInterface;
|
| //
| // Most of this class is a boring wrapper arround the id set.
| // The only interesting hitch is the setHandle. This class doesn't
| // have a direct referance to the related id set, it has a referance
| // to a referance to the set. When the transaction is completed the
| // CMR field sets my referance to the set to null, so that I know that
| // this set is no longer valid. See the ejb spec for more info.
| //
|
| public RelationSet(
| JDBCCMRFieldBridge cmrField,
| EntityEnterpriseContext ctx,
| List[] setHandle) {
|
| this.cmrField = cmrField;
| this.ctx = ctx;
| this.setHandle = setHandle;
| relatedLocalInterface = cmrField.getRelatedLocalInterface();
| }
|
| private List getIdList() {
| if(setHandle[0] == null) {
| throw new IllegalStateException("A CMR collection may only be used " +
| "within the transction in which it was created");
| }
|
|
Source:
http://www.cenqua.com/clover/eg/jboss/report/org/jboss/ejb/plugins/cmp/jd...
--
Alex
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3974508#3974508
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3974508
19 years, 7 months