views:

83

answers:

1

I'm having a hell of a time trying to find sybase documentation that says if the 12.5 client is thread safe. I need to make sybase threadsafe calls because I'm writing an nsapi plugin which lives in a threaded environment. So either I need to make sure the sybase client can run in a threaded environment or I'd need to serialize calls to sybase which would slow down my webserver. Suggestions?

A: 

The 12.5.1 open client is thread safe, you just need to link to the correct library.

As of this release, the thread-safe version of Open Client/C libraries are written using POSIX threads. All multithreaded libraries use the naming pattern *_r.a for static libraries or *_r.so for shared libraries. For multithreaded applications, use libraries with the “_r” suffix, such as libcs_r.a. For non-multithreaded applications, use libraries without the “_r” suffix, such as libcs.a.

http://download.sybase.com/pdfdocs/sdr1251e/ocssun04.pdf

Byron Whitlock