Print Plugin

348 views
Skip to first unread message
Assigned to lorenzo...@geosolutionsgroup.com by me

papa...@gmail.com

unread,
Feb 8, 2022, 6:04:08 AM2/8/22
to mapstore-developers
Hello,
When i try to run the command --> mvn clean install -Dmapstore2.version=v2020.02.00 -Pprinting

I got the following error:

[ERROR] Unknown lifecycle phase ".version=v2020.02.00". You must specify a valid lifecycle phase or a goal in the format <plugin-prefix>:<goal> or <plugin-group-id>:<plugin-artifact-id>[:<plugin-version>]:<goal>

Can you help me with that please?

Lorenzo Natali

unread,
Feb 17, 2022, 4:03:33 AM2/17/22
to mapstore-...@googlegroups.com
It looks like you added a space or what between -Dmapstore2 and .version. 
Anyway it seems to be an issue with maven or CLI, not with MapStore in general.
mvn clean install -Dmapstore2.version=v2020.02.00 -Pprinting works for me on bash. I know devs that use it on windows without any problem. 

--
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 view this discussion on the web, visit https://groups.google.com/d/msgid/mapstore-developers/5739c632-3503-461f-8388-21f8e4fe31d6n%40googlegroups.com.

papa...@gmail.com

unread,
Mar 9, 2022, 2:23:39 AM3/9/22
to mapstore-developers
Thanks for your answer Lorenzo!

Now,  I am experiencing this strange issue (please see attached images), where when I try to print a map with openlayers the background is displayed correctly in the print preview, but when I'm in leaflet map type the print background is empty.

Also, even in openlayers when I'm trying to print a map with a tileprovider basemap (google maps hybrid), I got an empty pdf

I'm I missing some print configuration or there is something more here?
Thanks

print3.PNG
print1.PNG
print2.PNG

Lorenzo Natali

unread,
Mar 9, 2022, 5:48:47 AM3/9/22
to mapstore-...@googlegroups.com
Hi,
google layers are not maintained anymore:
see here:

I don't think they was never supported by the printing. 

About the error with leaflet, I can not reproduce it. Could you send the map exported?

vasilis papakonstantinou

unread,
Mar 9, 2022, 7:17:15 AM3/9/22
to mapstore-...@googlegroups.com
I'm using the basemap throught the custom tile provider as below:

GoogleMapsHybrid: {
        options: {
            attribution: '',
            subdomains: ['a', 'b', 'c', 'd']
        }
    },

So it is impossible this basemap to be included in the printed image?

As per leaflet issue, the printed map is a blank page with only mapstore logo and rest graphical elements

You received this message because you are subscribed to a topic in the Google Groups "mapstore-developers" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/mapstore-developers/24ei6Wp7oRg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to mapstore-develo...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/mapstore-developers/CAGBwUg8jyyKtHAG0dZserSBYUEwXx4nf2Ce0qakvQfzUB18V0w%40mail.gmail.com.

vasilis papakonstantinou

unread,
Mar 10, 2022, 7:19:52 AM3/10/22
to mapstore-...@googlegroups.com
I successfully added google maps as basemap for the print module.
Now, I'm facing another issue: the layers added to the map from my geoserver instance aren't printed to the final pdf

I will be really glad if you help me on this
Thanks in advance
Capture.PNG

Lorenzo Natali

unread,
Mar 10, 2022, 7:20:01 AM3/10/22
to mapstore-...@googlegroups.com
Hi, 

I was able to replicate the issue. I opened an issue, so you can follow the evolution of it here: https://github.com/geosolutions-it/MapStore2/issues/7948
I suggest to use openlayers that has more functionalities and are more tested on our platform, at the moment. 
Leaflet is actually used and tested on mobile standard configuration of MapStore. 



vasilis papakonstantinou

unread,
Mar 10, 2022, 7:22:29 AM3/10/22
to mapstore-...@googlegroups.com
Great! Happy that I helped on that!

I successfully added google maps as basemap for the print module.
Now, I'm facing another issue: the layers added to the map from my geoserver instance aren't printed to the final pdf

I will be really glad if you help me on this
Thanks in advance
Capture.PNG

Lorenzo Natali

unread,
Mar 14, 2022, 11:29:25 AM3/14/22
to mapstore-developers
Hi,
When you add a layer to the map, this request that failed is performed to check if there is a time dimension and Multidim extension. 
It is perfectly normal that this request fail. 

Probably you had another problem. 
If you have more questions unrelated to this thread, possibly with the instructions about how to replicate the issue you have. 

Thank you, it helps a lot to identify the problem

Daniele Maggiolo

unread,
Oct 21, 2022, 4:08:16 AM10/21/22
to mapstore-developers
Hi,
Hi, can I ask you please how did you get google basemap in print module?
I added the google basemap in ConfigProvider as you suggested (GoogleMapsHybrid), I activated the basemap in the map, I went to the print panel, I see the basemap in the preview but I don't see it in the final pdf (I use openlayers and not leaflets but I think it's indifferent).

Thanks in advance.

Lorenzo Natali

unread,
Oct 21, 2022, 4:38:01 AM10/21/22
to mapstore-...@googlegroups.com
Hi,
I don't know. The print service is provided by the back-end library mapfish-print 2
One possibility is that Google services recognize the request coming not from a browser and it blocks them.
Notice that also getting the tiles from tile service is a violation of Google Maps TOS

Reply all
Reply to author
Forward
0 new messages