Subject | [OT] several connecions with libfbembedded.so Was: Re: [Firebird-Java] Re: Exceptions using org.firebirdsql.gds |
---|---|
Author | Niki Ivanchev |
Post date | 2004-04-01T14:21:31Z |
I had some discussion with Helen Borrie on firebird-user list.
This is what she/he told me
<quote>
Simply, libfbembed.so is
non-threading, so the question of multiple connections from a single
application doesn't arise. It's a genuine "direct-connect": if you are
connected, you are connected to a running server process. If you
disconnect, the server process goes away.
You can run as many instances of libfbembed.so as you want, connecting to
the same database - there is no exclusive file locking on Classic.
The Windows embedded *server* model is a Superserver variant, not a Classic
instance as the embedded *library* (libfbembed.so) is on Linux. The
limitation on having multiple instances of a Windows embedded server
application relates to the exclusive locking of the database by the first
process spawned by the Superserver. An embedded server is always the first
and, therefore the only connection.
I'm reliably informed that libfbclient.so can be used for multi-threading
connections to Fb 1.5 Classic servers on either Windows or Linux, though I
haven't tried it myself.
</quote>
You may browse the discussion under "[firebird-support] TCP/IP
Necessary?" topic
Several months ago, I tried to test this on Linux. I was using
_connection pool_. The test included
100 threads trying to select, insert, update and delete a record(s) on
one database. Test passed on windows
and failed on Linux (crashing the process - core dumped :-( )
Frankly I don't know how to run several instances of libfbembeded.so
within one java app.
Niki Ivanchev
Ryan Baldwin wrote:
This is what she/he told me
<quote>
Simply, libfbembed.so is
non-threading, so the question of multiple connections from a single
application doesn't arise. It's a genuine "direct-connect": if you are
connected, you are connected to a running server process. If you
disconnect, the server process goes away.
You can run as many instances of libfbembed.so as you want, connecting to
the same database - there is no exclusive file locking on Classic.
The Windows embedded *server* model is a Superserver variant, not a Classic
instance as the embedded *library* (libfbembed.so) is on Linux. The
limitation on having multiple instances of a Windows embedded server
application relates to the exclusive locking of the database by the first
process spawned by the Superserver. An embedded server is always the first
and, therefore the only connection.
I'm reliably informed that libfbclient.so can be used for multi-threading
connections to Fb 1.5 Classic servers on either Windows or Linux, though I
haven't tried it myself.
</quote>
You may browse the discussion under "[firebird-support] TCP/IP
Necessary?" topic
Several months ago, I tried to test this on Linux. I was using
_connection pool_. The test included
100 threads trying to select, insert, update and delete a record(s) on
one database. Test passed on windows
and failed on Linux (crashing the process - core dumped :-( )
Frankly I don't know how to run several instances of libfbembeded.so
within one java app.
Niki Ivanchev
Ryan Baldwin wrote:
>Hi,[Non-text portions of this message have been removed]
>
>
>
>>This is normall, driver is trying to guess the name of the library.
>>I do not have the source in front of me (jaybird source),
>>but when I was tampering with embedded client in Linux, I had the same
>>
>>
>problem and
>
>
>>I digged into the code.
>>Jaybird is trying several names for .so files
>>
>>
>
>This is exactly it. I will make some changes so that if a client library is
>loaded then no stack trace is printed to std out(and simply INFO logged as
>to which library was loaded) - and if all attempts to load client library's
>log an ERROR via the logging system. Hopefully this will make things less
>confusing.
>
>I would like to point out though that as far as I am aware - their is no SS
>arch embedded server binaries available for linux.
>
>Their is a libfbembed.so - But I think that it is most likley to be a CS
>arch firebird server - as it comes only in the CS arch firebird server
>package. Therefore I dont believe it will work relaibly with more then one
>connection(a lock up or simple failure to connect is the most likley
>consequence of multiple connections in this case I believe) - also I have
>never tested jaybird against this(granted it looks for a client library with
>this name - possibly not what should occur). If anyone knows otherwise I
>would be gratefull for the information.
>
>Thanks
>Ryan
>
>-----Original Message-----
>From: Niki Ivanchev [mailto:niki_iv@...]
>Sent: 01 April 2004 14:21
>To: Firebird-Java@yahoogroups.com
>Subject: Re: [Firebird-Java] Re: Exceptions using org.firebirdsql.gds
>
>
>This is normall, driver is trying to guess the name of the library.
>I do not have the source in front of me (jaybird source),
>but when I was tampering with embedded client in Linux, I had the same
>problem and
>I digged into the code.
>Jaybird is trying several names for .so files
>Regards
>Niki
>
>
>
>
>
>
>