[ 
https://issues.apache.org/jira/browse/FELIX-5198?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15167251#comment-15167251
 ] 

Richard S. Hall edited comment on FELIX-5198 at 2/25/16 2:36 PM:
-----------------------------------------------------------------

I won't say I remember all of the specifics, but there are issues around this. 
I think at one time we did implement it so that a service became unavailable as 
soon as unregistering started, but we received a lot of blow back from people 
who wanted to do something with the service to say goodbye. The compromise we 
came up with was [I think] to only allow people who already had services 
references to be able to get a service, but to not allow any new lookups once 
unregistration started.


was (Author: rickhall):
I won't say I remember all of the specifics, but there are issues around this. 
I think at one time we did implement it so that a service became unavailable as 
soon as unregistering started, but we received a lot of blow back from people 
who wanted to do something with the service to say goodbye. The compromise we 
came up with was [I think] to only allow people who already had services 
references to be able to get a service, but to now allow any new lookups once 
unregistration started.

> Service should not be available while being unregistered
> --------------------------------------------------------
>
>                 Key: FELIX-5198
>                 URL: https://issues.apache.org/jira/browse/FELIX-5198
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework
>    Affects Versions: framework-5.4.0
>            Reporter: Carsten Ziegeler
>            Assignee: David Bosschaert
>             Fix For: framework-5.6.0
>
>
> Currently it is possible to get a service while it is  being unregistered - 
> if the service is get during processing of the unregistering event. This is 
> the order of events:
> a) a service (factory) is unregistered in the framework
> b) the UNREGISTERING event is sent before the service is actually 
> unregistered (this is as defined in the spec)
> c) the above event is handled synchronously, reactivating dependent components
> d) during this reactivation, some component looks up the service that is 
> unregistered in a). as this service is still registered and marked as valid, 
> it gets it
> According to ServiceRegistration.unregister the service should not be 
> available anymore while the events are sent



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to