[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-07-20 Thread philipdodds
Thanks for the quick response - I have opened a JIRA

https://jira.jboss.org/jira/browse/EJBTHREE-1870

Cheers

P

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4244720
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-07-20 Thread jaikiran
Please open a JIRA in EJBTHREE https://jira.jboss.org/jira/browse/EJBTHREE and 
attach the source and the logs and any other relevant data. If it turns out to 
be lower level issue (like JCA) we can then decide about moving the issue to 
JCA. 

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4244718
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-07-20 Thread philipdodds
After a chat with the very friendly Andy Taylor in the JBoss Messaging room on 
IRC I have put together a modified version of the EJB3 MDB example,  basically 
you need to run it then while it is consuming messages through JMX execute the 
stopDelivery (if you don't get an error the first time it is worth trying 
again).

The source is available here - 
http://www.fiveclouds.com/stuff/stopdelivery-mdb.zip

Also I posted to the JCA forum - 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4244714#4244714

I'm posting here (not in an attempt to cross post) to allow anyone who stumbles 
upon this thread to follow it since I'm still not sure if it is a problem in 
the EJB3 container or JCA.

Thanks again for the help - hopefully I'm getting closer to working out what is 
wrong :)

Cheers

P

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4244716
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-07-20 Thread philipdodds
I still haven't been able to make much progress on this issue.

I've tried various things to see what is going on - from what I can tell while 
the a transaction is in flight the session is closed in JBoss Messaging,  it is 
as though it doesn't realize that the consumer is active,  the session id is 
that of the consumer that is feeding the MDB. 

I did discover that some of the comments in my last post aren't quite true - I 
was looking at a release of the JCA provider that isn't in 5.1.0.  It appears 
that there was a feature added,  which added all the traditional stuff into the 
JCA layer (see https://jira.jboss.org/jira/browse/JBAS-7084).

I was wondering if this issue might have any bearing on my problem,  since it 
would imply that maxmessages isn't quite being maintained,  and thus maybe this 
is where my rogue transaction that keeps running and is ultimately cut off in 
its prime :)

Any help or guidance would be greatly appreciated.

Cheers

P

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4244553
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-07-14 Thread philipdodds
Its been a while :) but I finally got a little time to dig into this one a 
little more, in the end the bit that seems to bite me is the 
MessageInflowLocalProxy,  when requesting the stopDelivery - messages are 
continuing to pass through the MDB.  The flow of the requests to stop finally 
make it to the MessageInflowProxy which will request a release of the proxy - 
due to a small stack of debugging I was sure I had a transaction in flight and 
I get to the release method.


  |protected void release(Object proxy) throws Throwable
  |{
  |   // We are now released
  |   released.set(true);
  | 
  |   if (trace)
  |  log.trace(MessageEndpoint  + getProxyString(proxy) +  release  
+ Thread.currentThread());
  |   
  |   // Tidyup any outstanding delivery
  |   if (oldClassLoader != null)
  |   {
  |  try
  |  {
  | finish(release, proxy, false);
  |  }
  |  catch (Throwable t)
  |  {
  | log.warn(Error in release , t);
  |  }
  |   }
  |}
  | 

What I don't understand is that the oldClassLoader is null which means that the 
finish didn't get called - looking at that method that means that the finish 
doesn't get called and the transaction manager didn't get tidied up.

So I continued to dig around to see where the oldClassLoader gets set - it 
looks like it is done in the before and after,  which would imply that the 
TransactionDemarcationStrategy in the JmsServerSession needs to be 
TraditionalXATransactionDemarcationStrategy (since that it checked for) in the 
onMessage.  I appear to have an XATransactionDemarcationStrategy in place so 
before and after aren't called.

It looked like in the MessageInflowLocalProxy you look for the oldClassLoader 
in the delivery method too - if it is null you start a transaction.


  | try
  |   {
  |  // Check for starting a transaction
  |  if (oldClassLoader == null)
  |  {
  | boolean isTransacted = 
messageEndpointFactory.isDeliveryTransacted(methodInfo.getAdvisedMethod());
  | startTransaction(delivery, proxy, container, method, args, 
isTransacted);
  |  }
  |  return container.localInvoke(methodInfo, args);
  |   }
  | 

when you try to release how do you perform the check to ensure that the 
transaction has completed (when the oldClassLoader is null)?

All this code is pretty new to me so excuse any things that I got patently 
wrong :)  Any advice or help would be greatly appreciated.

Cheers

P

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4243625
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-06-02 Thread jaikiran
I just tried to reproduce this against AS-5.1.0.GA with the MDB tutorial 
http://www.jboss.org/jbossejb3/docs/ and it worked fine for me - I mean i don't 
see any exceptions when i call a stopDelivery on the MBean corresponding to a 
MDB. Can you provide more details like when do you call this method and does 
the queue have any messages when you call this method? 

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4234724
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-06-02 Thread jaikiran
jaikiran wrote : Can you provide more details like when do you call this 
method and does the queue have any messages when you call this method? 

Bad question :) You already have provided those details:
anonymous wrote : 
  | I had assumed that stopDelivery would simply allow the current transactions 
to complete then it would simply not deliver more messages, however this error 
seems to imply that it is terminating the current transactions, however it does 
seem to be after the MDB itself has finished processing. 

I'll have to look more into it to understand what's going on.


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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4234725
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-06-02 Thread jaikiran
By the way, is this all the log that you see on the console/log file? I am 
failing to see any EJB3 classes in that call hierarchy? Maybe the 
stopDelivery() invocation from the EJB3 MBean went off successfully? 

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4234729
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-06-01 Thread jaikiran
On which MBean are you calling the stopDelivery method? I could not find any 
EJB3 related classes in the exception stacktrace. Maybe the MBean is JBoss 
Messaging related?

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4234504
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-06-01 Thread philipdodds
We are calling the stopDelivery method on the EJB3 MDB MBean - I believe this 
one is the container registered when deploying the MDB.  The stopDelivery 
functionality was only re-introduced recently (I believe maybe 1.1.2/1.1.3?) 
and we have been keen to make use of it.

Thanks for the reply and the continuing help :)

Cheers

P

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4234506
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes a

2009-06-01 Thread philipdodds
I posted back to the JBM forum (I'm sorry I keep jumping between them)

http://www.jboss.org/index.html?module=bbop=viewtopict=155777start=10postdays=postDayspostorder=postOrderhighlight=highlight

The MDB in question is an EJB3 deployed one and it is the EJB3 container,  the 
MBean is listed as org.jboss.ejb3.mdb.MessagingDelegateWrapper.  We are calling 
the stopDelivery method on this to try and pause message consumption and that 
is when we get the exception.  I have checked the MDB and there is no funky 
threading stuff going on it there.

Since stopDelivery is new I'm wondering if there is a threading problem in the 
container,  though this occurs where we have MaxMessages and JMS Sessions both 
a 1 (and it also occurs where JMS sessions is set to a higher value).

Once again thanks for all the help

P

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4234528
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [EJB 3.0] - Re: Calling stopDelivery causes an exception

2009-05-31 Thread philipdodds
We have upgraded to JBoss 5.1.0GA and the problem is the same,  is it a known 
issue, or an exception we can safely ignore?

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

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4234361
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user