Developer guide



This page is specially written for those who want to develop on Gisgraphy. Gisgraphy is a Java framework; it gives you all you need to start coding in Gisgraphy.

Get the source code

All the source code is available on Github :

A little bit of technical detail...

  • Spring services / Hibernate mapping with a custom Hibernate dialect.
  • Lucene schema.
  • Uses PostgreSQL / PostGIS.
  • Built using Maven2.
  • Automatic synchronisation between PostgreSQL and Solr.
  • High test coverage (more than 1500 tests as of when this page was written).
  • Event based design.
  • UTF-8 used throughout.
  • Gisgraphy has it's own Maven repository with all the dependencies.
  • Designed with DSL (Domain Specific Language).
  • Designed with the DDD paradigm.
  • Tested to avoid memory leaks
  • Test are run for each release to see if performance is good

Build

Gisgraphy is based on Maven 2; you simply need to be familiar with it. To ease the build, a dedicated Maven repository is available. You have to Install PostgreSQL, PostGIS, and set up a Gisgraphy database as you would do for a common Gisgraphy installation. Then run:

	mvn clean test

to compile and run the tests.

IDE / Eclipse

We use Eclipse to develop in, but you can use NetBeans or any other IDE. To set up Gisgraphy in Eclipse :

  • Go to File-> New-> Project from GIT
  • Then create a new location repository with the source repository https://github.com/gisgraphy/gisgraphy
  • Once it is checked out, open a command line and run a "mvn eclipse:clean eclipse:eclipse"
  • Go back to Eclipse and refresh the project into your workspace (right click->Refresh).

License

Just a short reminder about license. Gisgraphy is developed under the LGPL license. This license is more flexible than the GPL license (which is copy left, that's to say, you must give all the sources you modify and all the projects or libraries that use a GPL license). With LGPL you can use Gisgraphy for commercial use, modify it in any way. You must give all the sources you modify but you are not obliged to re-distribute sources of the project that use Gisgraphy.

See the attributions page to learn more on data licenses.