[omniORB] Getting in trouble with threads.

Niels Basjes (NLR) basjes@nlr.nl
Mon, 13 Jul 1998 11:20:48 +0200 (CDT)


On Mon, 13 Jul 1998, Henrik Schulz wrote:

> OS: Solaris 2.5

> 1. ...  a separate thread ...  pthreads, ....

> 6. Call on client of server based object member, but the call is not
> performed on server's object member.

> In case I don't start this separate thread before using the CORBA
> interface, the call will be performed sucessful. What's wrong? Any idea?

I've seen similar behaviour using Orbix 2.01MT and pthread on Solaris
2.5.1.

The behaviour I found was that the external corba calls are blocked until
the other thread terminates. This implies that the Solaris pthread library
isn't doing much multithreading.

I (just now) decided to check the comp.unix.solaris news group and there
is a posting (posted 12-jul-98) which describes the EXACT same problem.
Someone replied that there are 2 possibilities:
1) libc.so contains dummy versions for pthread : try putting the -lpthread
   at the beginning of your link commandline.
2) Use thr_setconcurrence(). I've read the man page on this one and it has
   to do with how the OS handles threads.

My personal conclusion is that this is a Solaris specific problem that has
nothing to do with either omniORB or Orbix.

Please let me know if this helped.

--

Best regards,

Niels.

=======================================================================
| ir. Niels Basjes              | National Aerospace Laboratory |  _  |
| Phone       : +31-20-5113381  | Anthony Fokkerweg 2           | /   |
| Fax         : +31-20-5113912  | 1059 CM Amsterdam             |(NLR)|
| E-Mail@NLR  : Basjes@NLR.nl   | The Netherlands               |  _/ |
| E-Mail@Home : Niels@Basjes.nl | http://www.nlr.nl             |     |
=======================================================================