Subject Re: [IBO] ISAPI / multithread
Author stewartbourke
Helen,

Thanks for that.

One very quick point of clarification - can I reference 127.0.0.1 in
the connection string, or must it be 'localhost'?
Thanks,

Stewart Bourke

--- In IBObjects@yahoogroups.com, Helen Borrie <helebor@t...> wrote:
> At 08:16 AM 24/06/2003 +0000, you wrote:
> >I am using d5, Ent, IBO V5 to create an ISAPI dll.
> >
> >I am still using the the BDE-equivalents - tiboQuery with a
> >tIboDatabase on the webmodule.
> >
> >In this case, in order to be multi-threaded, do I need to use an
> >ib_session
>
> Yes
>
> >or the standard Delphi-tSession?
>
> No.
>
> > if it is an ib_session,
> >apart from dropping the component on the webmodule
> > are there any
> >additional properties etc that I need to set to make sure the DLL
> >handles the multiple calls correctly?
>
> Just make sure that the ib_session is the first thing in the
creation
> order. That way, everything created inside the module will attach
to that
> ib_session instead of the default one for the application.
>
> >Are there any other 'pitfalls' or things that I need to be aware of
> >when using IBO in a DLL?
>
> The main pitfall isn't an IBO one, it's with the client. You'll be
running
> the client on the web host server...if you are also using the same
host
> machine for the database server, make sure the ib_connection
connects to
> localhost, using cpTCP_IP. (This is called TCP/IP local loopback.
You
> don't need a NIC installed for it to work.) Don't use Windows
local
> connection (cpLOCAL), or your client instances will trample all
over one
> another in the inter-process communication space and derail the
train. It
> is *not* a pretty exercise cleaning up after an ISAPI train smash.
>
> Make sure your HOSTS file has a localhost entry:
>
> 127.0.0.1 localhost # Local loopback server
>
> Helen