A component of MapFish for printing templated cartographic maps. This module is the Java serverside module. For support post to the mailing list: https://groups.google.com/forum/#!forum/mapfish-print-users
Clone or download
pvalsecc Merge pull request #735 from mapfish/faster_boot
Disable automatic detection of WebApplicationInitializer
Latest commit 0f953ce Sep 24, 2018
Permalink
Failed to load latest commit information.
.idea Allow to have sub_apps and allow to have apps appear at runtime Aug 31, 2018
.travis Reformatting of the code Jul 31, 2018
core Disable automatic detection of WebApplicationInitializer Sep 24, 2018
docs Bump jmustache from 1.12 to 1.14 Sep 19, 2018
examples Reformatting of the code Jul 31, 2018
gradle/wrapper Fix CORS for tomcat. Mar 13, 2017
jMeter Add missing newline at end of file May 5, 2017
publish Merge pull request #715 from mapfish/cli_tar_out Sep 18, 2018
travis Automatic release to mvnrepository Sep 14, 2018
.dockercfg.enc Add the generation of a Docker image. Nov 27, 2015
.gitattributes Fix transparent JPEG layer Oct 6, 2017
.gitignore Don't publish debian packages anymore Sep 14, 2018
.travis.yml Automatic release to mvnrepository Sep 14, 2018
BREAKING-CHANGES.md Fail in case of extra attribute Apr 6, 2018
LICENSE Change license to BSD 2-clause Mar 17, 2016
README.rst Be able to use DPI in legend Jul 16, 2018
V2-V3-BREAKING-CHANGES.rst Add missing newline at end of file May 5, 2017
build.gradle Bump groovy-all from 2.4.15 to 2.5.2 Sep 19, 2018
checkstyle_checks.xml Reformatting of the code Jul 31, 2018
checkstyle_suppressions.xml Removes VisibilityModifier check May 5, 2017
findbugs-exclude.xml Fix SVG rendering Dec 1, 2017
gradle.properties Automatic release to mvnrepository Sep 14, 2018
gradle.properties.enc Automatic release to mvnrepository Sep 14, 2018
gradlew Remove MaxPermSize Aug 30, 2017
gradlew-debug Add missing newline at end of file May 5, 2017
gradlew-debug.bat Add missing newline at end of file May 5, 2017
gradlew.bat Remove MaxPermSize Aug 30, 2017
settings.gradle Don't publish debian packages anymore Sep 14, 2018
signing.gpg.enc Automatic release to mvnrepository Sep 14, 2018

README.rst

https://travis-ci.org/mapfish/mapfish-print.svg?branch=master

Please read the documentation available here: http://mapfish.github.io/mapfish-print/

For support or questions post on the mailing list: https://groups.google.com/forum/#!forum/mapfish-print-users

Build

Execute the following command():

> ./gradlew build

This will build three artifacts: print-servlet-xxx.war, print-lib.jar, print-standalone.jar

The build also builds the documentation in the docs/build/site folder. To deploy the documentation it should simply be copied to the gh-pages branch and then committed GitHub will automatically build the updated site at: http://mapfish.github.io/mapfish-print/

If you only want to build the docs simply run

> ./gradlew docs:build

or run build in the docs directory

Note

The test (part of the build) requires the 'Liberation Sans' font, witch can be downloaded here.

Deploy

The following command will build and upload all artifacts to the maven central repository.

> ./gradlew uploadArchives -DsshPassphrase=...

You can as well generate a docker image using this command:

> ./gradlew createDocker

If you want to force the version to something custom, you can define the DOCKER_VERSION environment variable.

To use in Eclipse

Create Eclipse project metadata:

> ./gradlew eclipse

Import project into Eclipse

Run from commandline

The following command will run the mapfish printer. The arguments must be supplied to the -PprintArgs="..." parameter.

To list all the commandline options then execute (the current direstory is ./core):

> ./gradlew print -PprintArgs="-help"
> ./gradlew print -PprintArgs="-config ../examples/config.yaml -spec ../examples/spec.json -output ./output.pdf"

If you want to run in debug mode you can do the following:

Run using gretty/jettyRun

The following command will run mapfish print using gretty/jetty. The default port is 8080, but can be changed using -PhttpPort="..." parameter.

> ./gradlew jettyRun -PhttpPort=8090

Run in Eclipse

  • Create new Java Run Configuration
  • Main class is org.mapfish.print.cli.Main
  • Program arguments: -config samples/config.yaml -spec samples/spec.json -output $HOME/print.pdf

Contributor License Agreement

Before accepting a contribution, we ask that you provide us a Contributor License Agreement. If you are making your contribution as part of work for your employer, please follow the guidelines on submitting a Corporate Contributor License Agreement. If you are making your contribution as an individual, you can submit a digital Individual Contributor License Agreement.

Credits

https://www.yourkit.com/images/yklogo.png

Thanks to YourKit for letting us use their Java profiler!