[Geoserver-devel] Adding a new method to the GeoServerLifecycleHandler interface

Hi,
I’m proposing we add a new method to the GeoServerLifecycleHandler interface:

/**

  • Called when a reload is starting, see onReload for a notification that the reload ended
    */
    void beforeReload();

The method will allow implementors to do special actions during the reload period,
and the implementation in GeoServerImpl will make sure once beforeReload() is
called, a call to onReload() is guaranteed().

Use cases for this method:

  • interact with a custom servlet filter that will block all incoming ogc requests
    during the reload (they will likely fail anyways)
  • notify load balancers and put the node temporary out of the pool

The change will affect all implementations of GeoServerLifecycleHandler and break them, of course all
the ones in GeoServer will be fixed. Given this, no attempt to backport the change will be made
(GeoServerLifecycleHandler is after all a pluggable interface, everybody can implement
it and use it custom extensions).

Cheers
Andrea

==

GeoServer Professional Services from the experts! Visit
http://goo.gl/NWWaa2 for more information.

==

Ing. Andrea Aime

@geowolf
Technical Lead

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

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


Sounds good to me, +1

···

On Wed, Jun 11, 2014 at 10:17 AM, Andrea Aime <andrea.aime@anonymised.com> wrote:

Hi,
I’m proposing we add a new method to the GeoServerLifecycleHandler interface:

/**

  • Called when a reload is starting, see onReload for a notification that the reload ended
    */
    void beforeReload();

The method will allow implementors to do special actions during the reload period,
and the implementation in GeoServerImpl will make sure once beforeReload() is
called, a call to onReload() is guaranteed().

Use cases for this method:

  • interact with a custom servlet filter that will block all incoming ogc requests
    during the reload (they will likely fail anyways)
  • notify load balancers and put the node temporary out of the pool

The change will affect all implementations of GeoServerLifecycleHandler and break them, of course all
the ones in GeoServer will be fixed. Given this, no attempt to backport the change will be made
(GeoServerLifecycleHandler is after all a pluggable interface, everybody can implement
it and use it custom extensions).

Cheers
Andrea

==

GeoServer Professional Services from the experts! Visit
http://goo.gl/NWWaa2 for more information.

==

Ing. Andrea Aime

@geowolf
Technical Lead

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

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



HPCC Systems Open Source Big Data Platform from LexisNexis Risk Solutions
Find What Matters Most in Your Big Data with HPCC Systems
Open Source. Fast. Scalable. Simple. Ideal for Dirty Data.
Leverages Graph Analysis for Fast Processing & Easy Data Exploration
http://p.sf.net/sfu/hpccsystems


Geoserver-devel mailing list
Geoserver-devel@anonymised.comsts.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Justin Deoliveira
Vice President, Engineering | Boundless
jdeolive@anonymised.com
@j_deolive

On Wed, Jun 11, 2014 at 6:22 PM, Justin Deoliveira <
jdeolive@anonymised.com> wrote:

Sounds good to me, +1

And here comes the pull request:
https://github.com/geoserver/geoserver/pull/617

Cheers
Andrea

--

GeoServer Professional Services from the experts! Visit
http://goo.gl/NWWaa2 for more information.

Ing. Andrea Aime
@geowolf
Technical Lead

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

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

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