[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Intermittent TransactionRollbackLocalExceptions

2005-11-02 Thread darretta
Sorry for the late response, dragon_jdh. I have not been monitoring this 
list

There is nothing magical about the resolution. Essentially, we create beans 
that represent a user request to add or delete an entity in the system. If an 
administrator approves the add/delete, then the actual entity bean is 
created/removed as requested. In the business logic, I was allowing user to 
request multiple delete requests for the same bean. If the admin user tried to 
approve all requests in batch mode, the system was not robust enough to handle 
the duplicate requests.

For whatever it's worth, we have some session beans that wrap direct JDBC calls 
for lookup requests only. (This improved performance 10-fold in some cases.) To 
prevent transaction rollback exceptions for these methods, we set the 
@ejb:transaction type=Not Supported. Since the methods are read-only, 
transactionalization is not important.

View the original post : 
http://www.jboss.com/index.html?module=bbop=viewtopicp=3904939#3904939

Reply to the post : 
http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3904939


---
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42 plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [EJB/JBoss] - Hybrid EJB/JDBC Causing App Deadlocks

2005-05-25 Thread darretta
For performance reasons, we have implemented a hybrid EJB/direct-JDBC 
implementation. Essentially, for queries that produce large result sets, I have 
implemented direct JDBC calls within our many session facade beans. These JDBC 
calls are interspersed with some basic entity bean lookups that have produced a 
significant performance increase.

Example code in a session bean:
--

SiteStatusLocal siteStatusEjb = siteHome.findByName(...)
  | 
  | ConnectionWrapper wrapper = ConnectionWrapper.getInstance();
  | Connection conn = wrapper.getConnection();
  | 
  | PreparedStatement stmt = wrapper.getPreparedStatement(conn, );
  | stmt.setInt(1, siteStatusEjb.getId());
  | 
  | ResultSet result = stmt.executeQuery()

-

As the code suggests, I have a connection wrapper that retrieves a JDBC 
connection from the JBoss pool. The wrapper is then used to retrieve a 
pre-compiled statement. An entity bean is used to retrieve a status ID for the 
statement parameter.

My problem is that application deadlocks occasionally occur when accessing the 
siteStatusEjb.getId() method (or similar EJB calls) under light stress (10-15 
concurrent threads).

I am using Commit Option A/Pessimistic Locking.

Can anyone direct me on how to address this issue? Note that direct JDBC is 
used only for SELECT statements.

Thanks in advance...





View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=3879065#3879065

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=3879065


---
SF.Net email is sponsored by: GoToMeeting - the easiest way to collaborate
online with coworkers and clients while avoiding the high cost of travel and
communications. There is no equipment to buy and you can meet as often as
you want. Try it free.http://ads.osdn.com/?ad_id=7402alloc_id=16135op=click
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [EJB/JBoss] - Re: Hybrid EJB/JDBC Causing App Deadlocks

2005-05-25 Thread darretta
Also, I am seeing occasional javax.ejb.ObjectNotFoundExceptions under light 
stress. The data is present in the database and the exception only occurs in 
'batches' (that is, many exceptions for a short period, then none for an 
extended period).

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=3879066#3879066

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=3879066


---
SF.Net email is sponsored by: GoToMeeting - the easiest way to collaborate
online with coworkers and clients while avoiding the high cost of travel and
communications. There is no equipment to buy and you can meet as often as
you want. Try it free.http://ads.osdn.com/?ad_id=7402alloc_id=16135op=click
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence CMP/JBoss] - Re: Intermittent TransactionRollbackLocalExceptions

2005-01-19 Thread darretta
Problem was resolved. There was business logic that was causing multiple beans 
to share a single ID.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=3862807#3862807

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=3862807


---
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag--drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [Persistence CMP/JBoss] - Re: Intermittent TransactionRollbackLocalExceptions

2005-01-11 Thread darretta
Sorry for the long delay in my reply.

Here is the stack trace:

15:54:26,636 ERROR [BeanLock] Saw rolled back tx=TransactionImpl:XidImpl 
[FormatId=257, GlobalId=moonrock.metnet.navy.mil//10, BranchQual=]
15:54:26,636 ERROR [LogInterceptor] TransactionRolledbackLocalException in 
method: public abstract java.lang.Object 
mil.navy.ia.nicweb.dos.ejb.entity.PorRequestLocal.createValueObject(), causedBy:
java.lang.RuntimeException: Transaction marked for rollback, possibly a timeout
at 
org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.doSchedule(QueuedPessimisticEJBLock.java:228)
at 
org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.schedule(QueuedPessimisticEJBLock.java:183)
at 
org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:85)
at 
org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreationInterceptor.java:54)
at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:84)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:315)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:148)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:120)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
at 
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
at 
org.jboss.ejb.EntityContainer.internalInvoke(EntityContainer.java:484)
at org.jboss.ejb.Container.invoke(Container.java:723)
at 
org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invoke(BaseLocalProxyFactory.java:359)
at org.jboss.ejb.plugins.local.EntityProxy.invoke(EntityProxy.java:44)
at $Proxy258.createValueObject(Unknown Source)
at 
mil.navy.ia.nicweb.dos.ejb.session.PorFacadeBean.createPorRequest(PorFacadeBean.java:545)
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:324)
at 
org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:683)
at 
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:185)
at 
org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.java:72)
at 
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:84)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:315)
at 
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:148)
at 
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:120)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
at 
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
at 
org.jboss.ejb.StatelessSessionContainer.internalInvoke(StatelessSessionContainer.java:331)
at org.jboss.ejb.Container.invoke(Container.java:723)
at 
org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invoke(BaseLocalProxyFactory.java:359)
at 
org.jboss.ejb.plugins.local.StatelessSessionProxy.invoke(StatelessSessionProxy.java:83)
at $Proxy303.createPorRequest(Unknown Source)
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:324)
at 
org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:402)
at 
org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:309)
at 
org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:333)
at 
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:71)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:150)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:120)
at 
org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:481)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:323)
at 
org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:854)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at 
org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:339)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
at 

[JBoss-user] [Persistence CMP/JBoss] - Intermittent TransactionRollbackLocalExceptions

2004-12-20 Thread darretta
I inherited my first EJB project. The specs are:

JBoss 3.2.5
Struts -- SessionBean -- EntityBean (CMP)
Postgres 7.3.6
Redhat Linux ES 3.0

On rare occassions, I am seeing intermittent 
TransactionRollbackLocalExceptions:

-

javax.ejb.TransactionRolledbackLocalException?: Transaction marked for 
rollback, possibly a timeout; CausedByException? is:

Transaction marked for rollback, possibly a timeout: 
javax.ejb.TransactionRolledbackLocalException?: Transaction marked for 
rollback, possibly a timeout; CausedByException? is: Transaction marked for 
rollback, possibly a timeout at 
sun.reflect.NativeConstructorAccessorImpl?.newInstance0(Native Method) at 



Though I have not been able to profile each occurrence, at least in this case I 
was trying to update multiple rows in a single table. The exception occurs 
almost immediately after making the remote call. If I simply let the system run 
idle for 10 or so minutes, the problem disappears !!!

From what I've been able to muster, this is probably an issue with the 
findByPrimaryKey method. I have found many similar issues on the web, but no 
answers that can address my problem.

I'm sure I need to provide more information, but I'm not up enough on EJBs to 
know where to start. Any help is greatly appreciated.

Regards,
Mike

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=3859342#3859342

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=3859342


---
SF email is sponsored by - The IT Product Guide
Read honest  candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user