Hi Christian,
I prepared a pull request for this:
https://github.com/geoserver/geoserver/pull/354
Please, review it if you can.
Regards,
Mauro Bartolomeoli
2013/10/4 Christian Mueller <[email protected]>
> Hi Mauro
>
> No, you cannot backport. Lets assume you add a boolean
> "useRolesFromRoleService" with a default value of false. This is nice
> because you do not have to add migration code. Lets assume you add
> "useRolesFromRoleService" in 2.4.1.
>
> An admin using 2.4.1 changes something in the configuration and saves the
> configuration. The XStream persister saves the xml file including
> "useRolesFromRoleService". Afterwards, the admin decides to switch back to
> 2.4.0. Upon start, you will see a XStream exception because
> "useRolesFromRoleService" is in the xml config file but not in the class of
> the configuration object.
>
> As far as I understand the developer guidelines, it must be possible to
> switch between bug fix versions without migration of the data directory.
>
> Personally, I would like to see your enhancements in the original
> J2EEAuthenticationFilter on trunk.
>
> Possible solutions for 2.4.x
>
> 1) As I already mentioned, hack the J2EEAuthenticationFilter directly and
> replace the class file in the jar file
> 2) Develop you own extension. The security system is designed to allow
> extensions, the CAS extension is an example. This solutions is more time
> consuming and it should not be an "official" extension.
>
> Summary:
>
> The problem occurs if
>
> 1) An admin adds a J2EEAuthenticationFilter on 2.4.x having x > 0
> 2) The admin swtiches back to 2.4.0
>
> The probability of this situations tends to zero but according to Murphys
> law, it will happen.
>
> Sorry for the bad news
>
> Christian
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> On Fri, Oct 4, 2013 at 8:44 AM, Mauro Bartolomeoli <
> [email protected]> wrote:
>
>>
>>
>>
>> 2013/10/3 Christian Mueller <[email protected]>
>>
>>> Hi Mauro
>>>
>>> Sorry, my information was not correct. If you add instance vars to a
>>> config object, you cannot backport.
>>>
>>> Adding instance vars having the Java default value as the GeoServer
>>> default value does not require migration code. (boolean --> false, int -->
>>> 0, String --> null,...).
>>>
>>
>> Hi Christian, it's not clear to me if there is any way to add a new flag
>> and allow backporting. My idea was to add a flag (get roles from
>> roleservice) with a default value of false or an int (0=actual behaviour,
>> 1=use only roleservice to get roles, 2= use both). With both options I
>> would have a default value of false or 0, that does not require migration
>> code. Can I backport this changes if I go this way?
>>
>> Just to be clear, I think my customer would prefer that this enhancement
>> could be included in official 2.4.x versions, and we are too far away from
>> a 2.5.0, so I'm just trying to understand if there is any option to have a
>> backport. Another option coming to my mind is having a completely
>> independent filter very similar to J2EEAuthenticationFilter, maybe even
>> extending it, with this alternative behaviour for fetching roles, but in my
>> opinion it would be preferrable to directly change the original
>> J2EEAuthenticationFilter.
>>
>> What do you think?
>>
>> Regards,
>>
>> Mauro Bartolomeoli
>>
>> --
>> ==
>> Our support, Your Success! Visit http://opensdi.geo-solutions.it for
>> more information.
>> ==
>>
>> Dott. Mauro Bartolomeoli
>> @mauro_bart
>> Senior Software Engineer
>>
>> GeoSolutions S.A.S.
>> Via Poggio alle Viti 1187
>> 55054 Massarosa (LU)
>> Italy
>> phone: +39 0584 962313
>> fax: +39 0584 1660272
>>
>> http://www.geo-solutions.it
>> http://twitter.com/geosolutions_it
>>
>> -------------------------------------------------------
>>
>
>
>
> --
> DI Christian Mueller MSc (GIS), MSc (IT-Security)
> OSS Open Source Solutions GmbH
>
>
--
==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for more
information.
==
Dott. Mauro Bartolomeoli
@mauro_bart
Senior Software Engineer
GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
http://www.geo-solutions.it
http://twitter.com/geosolutions_it
-------------------------------------------------------
------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134071&iu=/4140/ostg.clktrk
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel