Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Multi-threaded Pro*C application on NT

Re: Multi-threaded Pro*C application on NT

From: Paul Passarelli <paulp_at_spam.talkthru.com>
Date: 1997/08/15
Message-ID: <01bca99c$cd5cbad0$be6964c7@kosh>#1/1

-- 
Fri 08/15/1997 

  If you're using 7.2 then the multi threading capabilities are
*definately* not what you'd expect.  The Pro*C app can certainly be multi
threaded, but, and it's a big but, you'll have to mutex the code around the
PL/SQL, --OR-- duplicate a mess-o-code.  I've written a MT app that handles
client connections, and it has to mutex the calls.  The upside is it's
small :)  the down side is it can only handle a few hundred simultaneous
users :(  Probably, unfortunately, because it has to, run on the same box
as Oracle, and several other *largeish* applications, with only 64MB of RAM
and a single CPU, --please don't ask--.  

If you do try to call PL/SQL routines from MT C/C++ remember to keep your
SQLDA thread local, it'll save you a lot of grief.

/** private data **/
//.015 make these thread local

__declspec(thread) static SQLDA * bind_dp ;
__declspec(thread) static SQLDA * select_dp ;
__declspec(thread) static int sql_error_action = SQL_ACTION_CONTINUE ;
--Paul ---------|^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^|--------- Legitimate replies must remove spam from my address. ---------|____________________________________________________|--------- Space. The final frontier. These are the voyages of the starship Enterprise. Its five year mission to explore strange new worlds... Brad Witt <Brad_Witt_at_cpqm.saic.com> wrote in article <33F216E3.42AC2503_at_cpqm.saic.com>... > Looking for any information regarding multi-threaded Pro*C/C++ > applications running on an NT server. We're coding a multi-threaded NT > service that will invoke Pro*C routines located within a DLL. We're > getting all the code to compile and link; but, are getting runtime > errors when the Pro*C routines are called. The errors have to do with > runtime contexts. We've implemented the multiple threads using separate > runtime contexts model that is described in the Programmer's Guide to > the Pro*C/C++ Precompiler. Any thoughts?? > > >
Received on Fri Aug 15 1997 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US