how to use java mapscript in tomcat4/jsp environment?
Umberto Nicoletti
unicoletti at PROMETEO.IT
Tue Mar 15 23:38:48 PST 2005
Please reply to the ml too next time.
Th error you are getting is relative to the security policy of the jvm
that forbids the servlet to invoke system.loadLibrary. This is rather
unusual, please post the output of the following command:
java -version
and the tomcat version (seems 4.1).
Regards,
Umberto
On Wed, 2005-03-16 at 09:23 +0800, wlx wrote:
> Hi Umberto,
> This is my test.jsp content:
>
> <%@ page language="java" import="edu.umn.gis.mapscript.*" %>
> <%@ page import="java.lang.System" %>
> <%
> System.loadLibrary("mapscript");
> mapObj map = new mapObj("/usr/share/tomcat4/webapps/ROOT/test/test.map");
> // imageObj img = map.draw();
> // img.save("test.gif",map);
> // webObj web = new mapObj(web);
> %>
> <HTML>
> <BODY>
> Hello! The image is :
> <%
> // String test1=img.getImageurl();
> out.println("hello,world");
> %>
> </BODY>
> </HTML>
>
> The error message is :
> The server encountered an internal error () that prevented it from
> fulfilling this request.
> And you can you view the detailed error message here:
> http://210.77.68.214:8180/test.jsp
>
> I have tested with comment the new mapObj sentence,thus it is
> working.
>
> Best regard,
>
> Yours sincerely,
> Liangxu Wang
>
> > tomcat4/jsp environment?
> >
> > On Tue, 2005-03-15 at 10:37 +0800, wlx wrote:
> > > Hi list,
> > > I have compiled java mapscript with mapserver 4.4.1 in my
> > > system,but I don't know how to use it. My system is Debian
> > sarge,and I
> > > compiled mapserver
> > > with:
> > >
> > > ./configure --with-gd=/usr --with-gdal=/usr/bin/gdal-config
> > > --with-ogr --with-proj --with-threads
> > > make
> > > cd mapscript/java
> > > make
> > > make test
> > > cp *.so /usr/lib/jni/
> > > cp *.jar /usr/share/tomcat4/common/lib
> > >
> > > Are there something wrong? I even copy the jar file to tomcat4
> > > webapps/ROOT/WEB-INF/lib/.
> > > But when I want to create a simple test jsp file with java
> > mapscript,
> > > just create a new mapObj,errors happened.
> > >
> >
> > What kind of errors do you get?
> >
> > Umberto
> >
> > > So is there a simple introduction with java mapscript or a
> > simple example?
> > >
> > > Best wish,
> > >
> > > Sincerely yours,
> > >
> > > Liangxu Wang
> > --
> > Umberto Nicoletti | We are Pentium of Borg.
> > +390415701366 unicoletti at prometeo.it | Division is futile.
> > Prometeo S.R.L. The Software Experience | You will be
> > approximated.
> >
> >
>
>
>
--
Umberto Nicoletti | We are Pentium of Borg.
+390415701366 unicoletti at prometeo.it | Division is futile.
Prometeo S.R.L. The Software Experience | You will be approximated.
More information about the MapServer-users
mailing list