Re: OB::TimeoutPolicy problem

Dion Picco <[email protected]> Wed, 18 May 2005 15:34:38 -0230
Newsgroups gmane.comp.corba.orbacus
Organization IONA | Making Software Work Together TM
Message-ID <[email protected]>
Hi Mc,

On Thu, Apr 07, 2005 at 05:14:45PM +0400, Mc wrote:
> Hi,
> 
> I have JavaClient with OB::TimeoutPolicy set to 2000 (milliseconds) and 
> C++Server with thread_pool concurrency model (pool size 2). JavaClient 
> simultaneously (many threads >>2 ) calls long-time method of C++Server. 
> Some JavaClient threads received CORBA::NO_RESPONSE while timeout not 
> expired (<<2000 milliseconds after call) (it seems like waiting threads 
> received exceptions at the same time independently of call-time ). 
> CORBA::NO_RESPONSE stack trace:
> 
> org.omg.CORBA.NO_RESPONSE: Timeout during receive  vmcid: 0x0  minor code: 0 
> completed: Maybe
> 	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
> 	at sun.reflect.NativeConstructorAccessorImpl.newInstance(
> NativeConstructorAccessorImpl.java:39)
> 	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(
> DelegatingConstructorAccessorImpl.java:27)
> 	at java.lang.reflect.Constructor.newInstance(Constructor.java:274)
> 	at com.ooc.OB.Util.copySystemException(Util.java:74)
> 	at com.ooc.OB.GIOPClientWorker.exception(GIOPClientWorker.java:367)
> 	at com.ooc.OB.GIOPClientWorker.exception(GIOPClientWorker.java:455)
> 	at com.ooc.OB.GIOPClientWorkerThreaded.receive(
> GIOPClientWorkerThreaded.java:437)
> 	at com.ooc.OB.GIOPClientWorkerThreaded.sendReceive(
> GIOPClientWorkerThreaded.java:449)
> 	at com.ooc.OB.Downcall.request(Downcall.java:340)
> 	at com.ooc.OB.DowncallStub.invoke(DowncallStub.java:661)
> 	at com.ooc.CORBA.Delegate.invoke(Delegate.java:638)
> 	at org.omg.CORBA.portable.ObjectImpl._invoke(ObjectImpl.java:457)
> 
> Is it possible to JavaClient's threads wait for response exactly the 
> OB::TimeoutPolicy value milliseconds?
> 
> PS. Orbacus 4.1.3 (both client and server) and no other policies for 
> JavaClient are set.
>     
> ---
> Good luck!
> Mc.

I can't immediately see the cause of the problem here.  How long does it
wait before it throws the NO_RESPONSE exception?
Here are a couple of things that you can try to get to the root of the
problem:
- open up <JOB-4.1.3>/ob/src/com/ooc/OB/Downcall.java and go to ~750.
This is the start of the waitUntilCompleted() function that is used
during the send-receive to wait on that particular downcall.  If you
examine this function you will see it obtain the timeout value as well
as allowing the monitor to wait for that period of time.  You should
check to make sure that this timeout value (var t) is in fact set to
2000.  Also note what the value of state_ is during that time.    
- Show me how you are setting this timeout policy (a code snippet is
fine here)

Cheers.

-- 
Dion Picco, Software Engineer
IONA Technologies Inc.
Team Orbacus - Your CORBA Source
mailto:[email protected]
http://www.orbacus.com
_______________________________________________
OB-Users Mailing List - [email protected]
http://mail.ooc.nf.ca/mailman/listinfo/ob-users
Visit our support FAQ before you send a message.
http://www.orbacus.com/faq/support.html