Import/export plugin, problems importing KML files

73 views
Skip to first unread message

Gianfranco Mura

unread,
Nov 8, 2013, 6:21:43 AM11/8/13
to mapstore-...@googlegroups.com

Hi all, I have configured the import/export plugin in my mapstore but it work only for import/export .map files. The KML/KMZ import function present a pop-up with message please wait – uploading your data and stay so. The servicebox service is up (whit .map file all work fine); I tried kml plain, kml compress, kmz, etc. but the result is the same. During the test i logged as admin. No error/warning message in log files. This is the section of my mapStoreConfig.js for import/export plugin

{

"ptype": "gxp_importexport",

"service": "http://localhost:8089/servicebox/",

"types": ["map","kml/kmz"],

"actionTarget": "paneltbar",

"index": 28

}

Any idea? Thanks in advance


Gianfranco

Tobia Di Pisa

unread,
Nov 11, 2013, 8:54:43 AM11/11/13
to mapstore-...@googlegroups.com
Hi Gianfranco,

sorry for the delay of my answer. Probably the MapStore's upload request fails to reach the service ?
Have you the possibility to check the MapStore's request (using a browser tool like Firebug or something like that) ?
Have you MapStore in a Servlet Container (like Apache Tomcat) or you are using the MapStore installer or binary ?
If the MapStore's upload request fails to reach the ServiceBox service, maybe the problem could be the "proxy" configuration.

Best Regards,
    Tobia Di Pisa

==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for
more information.
==

Dott. Ing. Tobia Di Pisa
Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------


2013/11/8 Gianfranco Mura <g.m...@riteco.it>

--
You received this message because you are subscribed to the Google Groups "mapstore-developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mapstore-develo...@googlegroups.com.
To post to this group, send an email to mapstore-...@googlegroups.com.
Visit this group at http://groups.google.com/group/mapstore-developers.
For more options, visit https://groups.google.com/groups/opt_out.

Gianfranco Mura

unread,
Nov 11, 2013, 12:22:04 PM11/11/13
to mapstore-...@googlegroups.com
Hi,
Mapstore is deployed (with the other services like ServiceBox, geostore, html_proxy, etc.) in an apache tomcat 7 and all services are up. The proxy configuration is attached to this post. testing the function I noticed that downloads (export) of map and .kml are working fine but upload hangs. when i upload a .map file in localhost_Access.log is printed this line

82.85.101.163 - - [11/Nov/2013:16:51:32 +0000] "POST /http_proxy-1.0.2/proxy/?url=/servicebox/HTTPWebGISFileUpload HTTP/1.1" 500 1625

and in localhost.log is reported this error

Nov 11, 2013 4:51:32 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet [HttpProxy] in context with path [/http_proxy-1.0.2] threw exception
java.net.MalformedURLException: no protocol: /servicebox/HTTPWebGISFileUpload
    at java.net.URL.<init>(URL.java:585)
    at java.net.URL.<init>(URL.java:482)
    at java.net.URL.<init>(URL.java:431)
    at it.geosolutions.httpproxy.HTTPProxy.doPost(HTTPProxy.java:264)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:647)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)
    at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:936)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1004)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:589)
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:744)


Importing a kml file in localhost_Access.log is printed this line

    82.85.101.163 - - [11/Nov/2013:16:56:38 +0000] "POST /servicebox/FileUploader HTTP/1.1" 404 997

and in localhost.log there is no errors o warnings.

best regards,
Gianfranco
proxy.properties

Tobia Di Pisa

unread,
Nov 11, 2013, 1:38:54 PM11/11/13
to mapstore-...@googlegroups.com
Hi Gianfranco,

as I can see from your log, I think you are using the ServiceBox 1.2, right ?  (and maybe the MapStore 1.3 ?)
Recently several modifications about Upload servlets are been made so, in order to be sure to use all the ImportExport plugin functionalities,
you have to use the 1.2.x stable branch for the moment (waiting for a next release).

However, make sure you have setted correctly the ServiceBox 'app.properties' file with the system path of the ServiceBox's 'temp' directory,
below an example:

temp=/home/tomcat/webapps/servicebox/temp

You can find more information about the pending works on the ImportExport plugin inside the MapStore's issues list at the link below:

https://github.com/geosolutions-it/mapstore/issues?milestone=none&state=open


Best Regards,
     Tobia Di Pisa


==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for
more information.
==

Dott. Ing. Tobia Di Pisa
Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------


2013/11/11 Gianfranco Mura <g.m...@riteco.it>

--

Gianfranco Mura

unread,
Nov 12, 2013, 3:34:59 AM11/12/13
to mapstore-...@googlegroups.com
Hi Tobia,

I will follow your advice and wait for new release of servicebox. Thanks for your answer,

Gianfranco
>> present a pop-up with message please wait - uploading your data and stay
>> so. The servicebox service is up (whit .map file all work fine); I tried
>> kml plain, kml compress, kmz, etc. but the result is the same. During
>> the test i logged as admin. No error/warning message in log files. This is
>> the section of my mapStoreConfig.js for import/export plugin
>>
>> {
>>
>> "ptype": "gxp_importexport",
>>
>> "service": "http://localhost:8089/servicebox/",
>>
>> "types": ["map","kml/kmz"],
>>
>> "actionTarget": "paneltbar",
>>
>> "index": 28
>>
>> }
>>
>> Any idea? Thanks in advance
>>
>>
>> Gianfranco
>>
>
> Il giorno venerdì 8 novembre 2013 12:21:43 UTC+1, Gianfranco Mura ha
> scritto:
>
>> Hi all, I have configured the import/export plugin in my mapstore but
>> it work only for import/export .map files. The KML/KMZ import function
>> present a pop-up with message please wait - uploading your data and stay
>> so. The servicebox service is up (whit .map file all work fine); I tried
>> kml plain, kml compress, kmz, etc. but the result is the same. During
>> the test i logged as admin. No error/warning message in log files. This is
>> the section of my mapStoreConfig.js for import/export plugin
>>
>> {
>>
>> "ptype": "gxp_importexport",
>>
>> "service": "http://localhost:8089/servicebox/",
>>
>> "types": ["map","kml/kmz"],
>>
>> "actionTarget": "paneltbar",
>>
>> "index": 28
>>
>> }
>>
>> Any idea? Thanks in advance
>>
>>
>> Gianfranco
>>
winmail.dat

Giovanni Virdis

unread,
Mar 31, 2014, 8:07:41 AM3/31/14
to mapstore-...@googlegroups.com
Hi Tobia,

I'm continuing the work of Gianfranco. In order this is my installation

1. Ubuntu 12.04.4 LTS
2. Mapstore 1.5-snapshot
3. servicebox 1.5-snapshot
4. http-proxy 1.1-snapshot

when import a kml/kmz the system return the following error

type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
java.lang.NullPointerException
it.geosolutions.httpproxy.MimeTypeChecker.onRemoteResponse(MimeTypeChecker.java:66)
it.geosolutions.httpproxy.HTTPProxy.onRemoteResponse(HTTPProxy.java:224)
it.geosolutions.httpproxy.HTTPProxy.executeProxyRequest(HTTPProxy.java:684)
it.geosolutions.httpproxy.HTTPProxy.doGet(HTTPProxy.java:288)
javax.servlet.http.HttpServlet.service(HttpServlet.java:621)
javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
note The full stack trace of the root cause is available in the Apache Tomcat/7.0.26 logs.

can you help me??

Thanks

Tobia Di Pisa

unread,
Apr 1, 2014, 7:51:04 AM4/1/14
to mapstore-...@googlegroups.com
Hi Giovanni,

you're performing a request through the Http-Proxy and this throw an exception
during the MimeType check. This is a known issue solved recently and for the moment
available inside the master branch of the Http-Proxy. You can update your local version
from GitHub.

Regards,
     Tobia Di Pisa



==
Meet us at GEO Business 2014! in London! Visit http://goo.gl/fES3aK
for more information.
==


Dott. Ing. Tobia Di Pisa
Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

fax: +39 0584 1660272

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------
You'll need Skype CreditFree via Skype


--
You received this message because you are subscribed to the Google Groups "mapstore-developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mapstore-develo...@googlegroups.com.
To post to this group, send email to mapstore-...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Giovanni Virdis

unread,
Apr 1, 2014, 10:37:38 AM4/1/14
to mapstore-...@googlegroups.com, tobia....@geo-solutions.it
Thanks Tobia, 

it works fine!!

Import and show the kml. The function "Zoom to layer extent" doesn't work .Some suggestions about?

Regards

Giovanni Virdis

Tobia Di Pisa

unread,
Apr 1, 2014, 12:25:01 PM4/1/14
to mapstore-...@googlegroups.com
Hi Giovanni,

this is an issue recently closed on master branch:


You can retrieve recent updates from GitHub.

Best Regards,
     Tobia Di Pisa


==
Meet us at GEO Business 2014! in London! Visit http://goo.gl/fES3aK
for more information.
==


Dott. Ing. Tobia Di Pisa
Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy
phone: +39 0584 962313+39 0584 962313
fax: +39 0584 1660272

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------
You'll need Skype CreditFree via Skype


--
Reply all
Reply to author
Forward
0 new messages