users@jax-rs-spec.java.net

[jax-rs-spec users] [jsr339-experts] Re: No way to disable a Feature

From: Marek Potociar <marek.potociar_at_oracle.com>
Date: Tue, 13 Dec 2011 15:44:59 +0100

On Tue 13 Dec 2011 03:20:15 PM CET, Bill Burke wrote:
>
>
> On 12/13/11 6:11 AM, Marek Potociar wrote:
>>
>>
>> On 12/12/2011 03:48 PM, Bill Burke wrote:
>>> While the Feature interface has a onDisable() method, there's no way for the onDisable() method to be able to
>>> unregister
>>> providers. The Configuration.getProviderXXXX() methods return immutable sets.
>>
>> Please clarify - are you suggesting to remove onDisable() and deffer the disabling mechanism to the Feature
>> implementation or to add a common API for feature disabling?
>>
>
> I'll clarify. The Configuration interface has no way to unregister a provider at the moment.

That's what I am trying to get at - do you want to be able to do this
via a common API set of methods or do you think that deferring the
means of disabling features or providers (e.g. via a custom property,
static method) work for you?

>>>
>>> Also, the Configuration.setProperty() method should state that if the property value is null, then this means to delete
>>> the property....OR...a removeProperty() method should be added.
>>
>> Can you (or anyone) think of a valid use case when a property can be expected to contain 'null' value? If not, I'll
>> update the setProperty(...) javadoc shortly.
>>
>
> Servlet spec works in the same way IIRC.

Ok. Will update javadoc.

Marek
>