PDA

View Full Version : Tomcat native library?


kjkoster
11-08-2008, 19:27
Dear All,

In my log files I keep getting this message:
INFO: The Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: .:/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java

Do any you guys use this native library? What kind of performance increase are you seeing?

Kees Jan

zwets
15-08-2008, 14:44
In my log files I keep getting this message:
"INFO: The Apache Tomcat Native library which allows optimal performance in production environments ..."

That same log message triggered me to try the APR at various points in time. Invariably, it led to stability and compatibility problems, so I gave up trying. Note that this was back in the 4.x or early 5.x days, so these issues may have been solved by now.

I just looked through my personal logs, but can't find references to the problem (it must have been at a client site). I am quite certain that the APR did not play well with the "Java Service Wrapper" which was the preferred way to run Tomcat (pre 5.5.x) as a Windows NT service. Also, if I remember correctly, there was a problem with the AJP proxy connector when combined with the APR.

Nowadays, Tomcat comes with its own Windows service installer, and the AJP-connector has been improved, so these issues may have been resolved. I'd definitely be interested in a review ... if only to get rid of that feeling of inadequacy whenever I see the "sub-optimality message" in the logs :D

Marco

ronaldmathies
16-08-2008, 14:34
I also encountered the problem, i have written about it on this page:

http://java.sodeso.nl/application-servers/apache-tomcat/when-starting-tomcat-i-get-the-following-message-info-the-apache-tomcat-native-library-which-allows-optimal-performance-in-production-environments-was-not-found-on-the-javalibrarypath-

kjkoster
16-08-2008, 22:27
Dear ronaldmathies,

Thanks for the links on your page. That should prove useful to those who want to start using the APR.

Do you have any comments on the stability issues that zwets observed? Do you have experience using APR in production?

Kees Jan

ronaldmathies
17-08-2008, 07:46
I haven't had those problems experienced by zwets, but i also have not used it in production environment. I only tried to figure out what the message means and how to solve it. I have used it while i was developing and then i did not have any problem.

kjkoster
17-08-2008, 12:19
Well, that adds up to some old, negative reports on production use and some positive reports on a development machine.

It would be nice to get some more data points. ;-)

Kees Jan

Barry
23-08-2008, 12:06
I have the definitive guide on Tomcat (2nd edition) which includes a benchmark.
The result is (surprisingly) that standalone tomcat is now faster at serving small text files then APR (the native library) or the NIO implementation.
The "JIO" mode is fastest (normal Java IO)

NIO mode is probably best if you keep connections open a long time (AJAX/Comet applications)
Run your own tests