XoomCode / AcidMaps

Interpolated Images Generator
GNU Lesser General Public License v3.0
33 stars 10 forks source link

Runs on Windows 7? #1

Closed edmarmoretti closed 13 years ago

edmarmoretti commented 13 years ago

I installed the plugin in geoserver (Windows 7) but does not work:

"java.lang.UnsatisfiedLinkError: no acid-maps-jni in java.library.path no acid-maps-jni in java.library.path"

Any tips?

maurimiranda commented 13 years ago

Yes, it does. You need to use the right library, which actually is not available for download. I'll check and let you know when it's ready.

fpanettieri commented 13 years ago

I've just uploaded the 64 bits library for Windows 7. You can download it from https://github.com/downloads/XoomCode/AcidMaps/AcidMaps_2.0_JNI_Windows_64_bit.rar

You can extract acid-maps-jni.dll into your windows/system32 folder, or modify the java.library.path to the location of the library.

I'll build the 32 bit version now.

edmarmoretti commented 13 years ago

The error message now is:

ows:ExceptionTextjava.lang.NoClassDefFoundError: Could not initialize class com.xoomcode.acidmaps.adapter.JCAdapter Could not initialize class com.xoomcode.acidmaps.adapter.JCAdapter/ows:ExceptionText /ows:Exception /ows:ExceptionReport Log Geoserver (partial): at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringS ecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain .doFilter(FilterChainProxy.java:406) at org.springframework.security.context.HttpSessionContextIntegrationFil ter.doFilterHttp(HttpSessionContextIntegrationFilter.java:235) at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringS ecurityFilter.java:53) at org.springframework.security.util.FilterChainProxy$VirtualFilterChain .doFilter(FilterChainProxy.java:406) at org.springframework.security.util.FilterChainProxy.doFilter(FilterCha inProxy.java:185) at org.springframework.security.util.FilterToBeanProxy.doFilter(FilterTo BeanProxy.java:99) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet Handler.java:1084) at org.geoserver.filters.LoggingFilter.doFilter(LoggingFilter.java:71) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet Handler.java:1084) at org.geoserver.filters.ReverseProxyFilter.doFilter(ReverseProxyFilter. java:183) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet Handler.java:1084) at org.geoserver.filters.GZIPFilter.doFilter(GZIPFilter.java:41) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(Servlet Handler.java:1084) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:3 60) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.jav a:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:1 81) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:7 26) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) ``` at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHand ``` lerCollection.java:206) at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection. java:114) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:1 52) at org.mortbay.jetty.Server.handle(Server.java:324) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:50 5) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpCo nnection.java:828) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:514) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:380) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.ja va:395) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool .java:450) 07 Abr 18:53:59 WARN [geoserver.ows] - Could not get a ServiceInfo for service a ms thus could not check if the service is enabled 07 Abr 18:53:59 WARN [acidmaps.AcidMapService] - Processing request {SIMPLIFY_ME THOD=1, BBOX=-48.416933678673,-24.879794549867,-40.334350900945,-20.771414529251 , TILED=true, SERVICE=AMS, HEIGHT=643, INTERVALS[]=10,20,45,70,100, SIMPLIFY_SIZ E=400, REQUEST=GetMap, RENDERER_TYPE=2, STYLES=, WIDTH=1265, STYLE=, EXCEPTIONS= application/vnd.ogc.se_inimage, TRANSPARENT=FALSE, VERSION=1.1.1, FORMAT=image/p ng, INTERPOLATION_STRATEGY=2, LAYERS=i3geo:locali, VALUE_COLUMN=VALOR, INTERVALS _COLORS[]=0xffffff00,0xffb2,0xff00b2,0xffff00b2,0xff0000b2, RADIUS=32, SRS=EPSG: 4326} 07 Abr 18:53:59 WARN [acidmaps.AcidMapService] - Cache missed 07 Abr 18:53:59 ERROR [geoserver.ows] - java.lang.NoClassDefFoundError: Could not initialize class com.xoomcode.acidmaps .adapter.JCAdapter at com.xoomcode.acidmaps.AcidMapService.run(AcidMapService.java:250) at com.xoomcode.acidmaps.AcidMapService.synchronizedRun(AcidMapService.j ava:205) at com.xoomcode.acidmaps.AcidMapService.GetMap(AcidMapService.java:124)
fpanettieri commented 13 years ago

Sorry for my late reply. Didn't saw the notification This error is caused by system - java architecture mismatch.

If your system runs on 32 bits, you should extract the 32 bit JNI in "Windows\system32" If your systems run on 64 bits, but you've installed the 32 bit java version, you should use the 32 bit JNI, and extract it on "Windows\SysWOW64", where 32 bits libraries are stored. If everything runs on 64 bits, you should use the 64 bits library, extracting it on "Windows\system32"

Hope this help

asa-shingo commented 12 years ago

Hi, I have the exact same issue.

I have following java version on my 64bit Windows 7 machine: java version "1.6.0_27" Java(TM) SE Runtime Environment (build 1.6.0_27-b07) Java HotSpot(TM) 64-Bit Server VM (build 20.2-b06, mixed mode)

Here is steps I have taken: 1) installed Geoserver, published data on postgres (postgis) table (includes primary key, geom fields) 2) verified the wms call via browser 3) extracted "AcidMaps_2.0.1_GeoServer_Plugin.tar.gz" and copied to C:\Program Files (x86)\GeoServer 2.1.1\webapps\geoserver\WEB-INF\lib 4) extracted "AcidMaps_2.0_JNI_Windows_64_bit.rar" and Windows/system32 folder 5) sent wms request: http://localhost:8084/geoserver/wms?bbox=-130,24,-66,50&styles=point&Format=image/png&request=GetMap&layers=asa-ctd:aqtr_stn&width=550&height=250&srs=EPSG:4326&INTERVALS_COLORS[]=0xffffff80,0xff000080,0xffff0080,0x00ff0080,0x0000ff80&RENDERER_TYPE=2&INTERPOLATION_STRATEGY=3&SIMPLIFY_METHOD=3&SIMPLIFY_SIZE=90&VALUE_COLUMN=value&RADIUS=40&service=AMS&INTERVALS[]=0.001,0.005,0.008,0.01,0.015

and got the same error as above:

2011-10-06 10:18:08,400 WARN [geoserver.ows] - Could not get a ServiceInfo for service ams thus could not check if the service is enabled 2011-10-06 10:18:08,409 WARN [acidmaps.AcidMapService] - Processing request {SIMPLIFY_METHOD=3, BBOX=590223.4382724703,4914107.882513998,608462.4604629107,4920523.89081033, SERVICE=AMS, INTERVALS[]=10,20,45,70,100, HEIGHT=330, SIMPLIFY_SIZE=90, REQUEST=GetMap, RENDERER_TYPE=2, STYLES=, WIDTH=938, VERSION=1.1.0, FORMAT=image/png, INTERPOLATION_STRATEGY=2, LAYERS=sf:bugsites, VALUE_COLUMN=cat, RADIUS=40, INTERVALS_COLORS[]=0xffffff80,0xff000080,0xffff0080,0x00ff0080,0x0000ff80, SRS=EPSG:26713} 2011-10-06 10:18:08,425 WARN [acidmaps.AcidMapService] - Cache missed 2011-10-06 10:18:08,466 ERROR [geoserver.ows] - java.lang.NoClassDefFoundError: Could not initialize class com.xoomcode.acidmaps.adapter.JCAdapter at com.xoomcode.acidmaps.AcidMapService.run(AcidMapService.java:250) at com.xoomcode.acidmaps.AcidMapService.synchronizedRun(AcidMapService.java:205) at com.xoomcode.acidmaps.AcidMapService.GetMap(AcidMapService.java:124).....

Any idea?

fpanettieri commented 12 years ago

The error indicates that ams java library is not loaded, or can't be located by Geoserver.

Please check with the guide if you're placing the jar in the right folder.

I'll check if there is any compatibility problem with the new version or something, and tell you about that.

asa-shingo commented 12 years ago

Thanks for the quick reply. When I removed INTERVALS[] parameter from above service call, it gives warning in png as: "Opaaa. Error in AcidMapsLibrary interval is null" with following geoserver log:

2011-10-06 12:54:22,733 WARN [geoserver.ows] - Could not get a ServiceInfo for service ams thus could not check if the service is enabled 2011-10-06 12:54:22,734 WARN [acidmaps.AcidMapService] - Processing request {SIMPLIFY_METHOD=3, BBOX=-130,24,-66,50, SERVICE=AMS, HEIGHT=250, SIMPLIFY_SIZE=90, REQUEST=GetMap, RENDERER_TYPE=2, STYLES=point, WIDTH=550, FORMAT=image/png, INTERPOLATION_STRATEGY=3, LAYERS=asa-ctd:aqtr_stn, VALUE_COLUMN=value, INTERVALS_COLORS[]=0xffffff80,0xff000080,0xffff0080,0x00ff0080,0x0000ff80, RADIUS=40, SRS=EPSG:4326} 2011-10-06 12:54:22,735 ERROR [acidmaps.AcidMapService] - Opaaa. Error in acidMapsLibrary. Intervals is null. com.xoomcode.acidmaps.error.AcidMapException: Opaaa. Error in acidMapsLibrary. Intervals is null. at com.xoomcode.acidmaps.AcidMapService.run(AcidMapService.java:247) at com.xoomcode.acidmaps.AcidMapService.GetMap(AcidMapService.java:122) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.geoserver.ows.Dispatcher.execute(Dispatcher.java:630) at org.geoserver.ows.Dispatcher.handleRequestInternal(Dispatcher.java:234)

I thought the initial parameter check is performed by the jar library..

Thanks for checking!

fpanettieri commented 12 years ago

Yes, paramters check is done in the jar library. Then probably the JNI adapter is what's wrong. please check the paths, and if you're using the right version.