Hi Irfan!
It's very much possible to call native code from a servlet. As far as Java
Web Server is concerned... the native code (DLL) is put in
<server_root>/native_lib.
Cheers,
--Manish Bhatnagar--
----- Original Message -----
From: Muhammad Irfan Khan <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, February 27, 2001 11:39 AM
Subject: Calling Native code from Servlets


> Hi all,
>
> I want to know wheather it's possible or not to call the native code from
> Servlets(I mean from Servlet container environment). I'm using Tomcat
3.2.1
> and my OS is Solaris 8.
>
> Actually I'm trying to call native code. But my servlet is unable to load
the
> library. I have placed the library at /usr/lib. Whenever I try to access
my
> servlet I recieve the following error(GetPS is my class which is trying to
> load the native code library)
>
> Error: 500
> Location: /myapp/servlet/ClientPullPS
> Internal Servlet Error:
> java.lang.UnsatisfiedLinkError: getPSInfo
>         at GeoStream.src.GetPS.getPSInfo(Compiled Code)
>         at GeoStream.src.ClientPullPS.doGet(Compiled
> Code)
>         at
> javax.servlet.http.HttpServlet.service(Compiled Code)
>         at
> javax.servlet.http.HttpServlet.service(Compiled Code)
>         at
> org.apache.tomcat.core.ServletWrapper.doService(Compile
> d Code)
>         at
> org.apache.tomcat.core.Handler.service(Compiled Code)
>         at
> org.apache.tomcat.core.ServletWrapper.service(Compiled
> Code)
>         at
> org.apache.tomcat.core.ContextManager.internalService(C
> ompiled Code)
>         at
> org.apache.tomcat.core.ContextManager.service(Compiled
> Code)
>         at
> org.apache.tomcat.service.http.HttpConnectionHandler.pr
> ocessConnection(Compiled Code)
>         at
> org.apache.tomcat.service.TcpWorkerThread.runIt(Compile
> d Code)
>         at
> org.apache.tomcat.util.ThreadPool$ControlRunnable.run(C
> ompiled Code)
>         at java.lang.Thread.run(Compiled Code)
>
> with regards,
>
> Muhammad Irfan Khan
>
>
___________________________________________________________________________
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to