Dear devs,
GEOS-7614 “Allowing GeoServer to store property placeholders as templates into the catalog”,
and its related PR (https://github.com/geoserver/geoserver/pull/1663), allow GeoServer to optionally make use of a placeholders on store, services and GWC configurations.
This work is part of the GSIP 145 “Back-up and Restore Extension for GeoServer Configuration” (https://github.com/geoserver/geoserver/wiki/GSIP-145), and more PRs touching the GeoServer core will follow soon.
In particular GEOS-7614 is related to this
https://github.com/geoserver/geoserver/wiki/GSIP-145#making-geoserver-configuration-easier-to-move-across-environments
"The proposal is to allow GeoServer to handle placeholders in configuration and replace them as needed with the provided input in order to customize some portions of the configuration itself. The placeholders would be configured in a separate file not subject to export/import (or subject only on demand). The location where this file is placed will be configurable also via an env variable similarly to how the GeoServer data dir is setup (env variable, system variable, servlet context parameter).
Besides the datastores which already have a neat separation between what’s stored and what’s used, with transformation in the middle, we’ll have to add extra methods/parameters to get the expanded or unexpanded version of a certain object.
Areas of work:
-
Expand variables in datastore configurations
-
Expand variables in service configurations
-
Expand variables in selected security subsystem bits
-
Expand variables in GWC disk quota configurations
The basic idea is to have a singleton, loaded at initialization time, able to transform placeholders defined by the user into real values and vice versa."
It is worth to highlight that even if the PR touches a lot of GeoServer modules it is not invasive. If the environment variable “ALLOW_ENV_PARAMETRIZATION” is absent or set to false everything is exactly the same, all the code for parametrization is ignored and GeoServer works exactly as if the PR is absent.
Two last things to say:
-
In order to work correctly and compile this PR requires also a GeoWebCache PR (https://github.com/GeoWebCache/geowebcache/pull/399) allowing GWC to read environment properties injected from outisde the same way GeoServer does.
-
As part of the same work will follow at least two other core PRs; the first one will introduce some new interfaces for the services allowing plugins and external modules to force configuration reload or storage without knowing anything about GeoServer extensions except their interface. The second one will allow the GeoServer GUI to present a “Server Busy Page” to the user but still allowing him to navigate the read-only/anonymous pages when write-locking the configuration instead of block the whole server.
···
Best Regards,
Alessio Fabiani.
==
GeoServer Professional Services from the experts!
Visit http://goo.gl/it488V for more information.
Ing. Alessio Fabiani
@alfa7691
Founder/Technical Lead
GeoSolutions S.A.S.
Via di Montramito 3/A
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 331 6233686
http://www.geo-solutions.it
http://twitter.com/geosolutions_it
AVVERTENZE AI SENSI DEL D.Lgs. 196/2003
Le informazioni contenute in questo messaggio di posta elettronica e/o nel/i file/s allegato/i sono da considerarsi strettamente riservate. Il loro utilizzo è consentito esclusivamente al destinatario del messaggio, per le finalità indicate nel messaggio stesso. Qualora riceviate questo messaggio senza esserne il destinatario, Vi preghiamo cortesemente di darcene notizia via e-mail e di procedere alla distruzione del messaggio stesso, cancellandolo dal Vostro sistema. Conservare il messaggio stesso, divulgarlo anche in parte, distribuirlo ad altri soggetti, copiarlo, od utilizzarlo per finalità diverse, costituisce comportamento contrario ai principi dettati dal D.Lgs. 196/2003.
The information in this message and/or attachments, is intended solely for the attention and use of the named addressee(s) and may be confidential or proprietary in nature or covered by the provisions of privacy act (Legislative Decree June, 30 2003, no.196 - Italy’s New Data Protection Code).Any use not in accord with its purpose, any disclosure, reproduction, copying, distribution, or either dissemination, either whole or partial, is strictly forbidden except previous formal approval of the named addressee(s). If you are not the intended recipient, please contact immediately the sender by telephone, fax or e-mail and delete the information in this message that has been received in error. The sender does not give any warranty or accept liability as the content, accuracy or completeness of sent messages and accepts no responsibility for changes made after they were sent or for other risks which arise as a result of e-mail transmission, viruses, etc.