pnoltes opened a new pull request #370:
URL: https://github.com/apache/celix/pull/370


   This PR makes the `celix::Deferred<T>::fail` and 
`celix::Deferred<T>::resolve` robust for resolving a  promise if it is already 
resolved. 
   
   This is different from the OSGi spec and this is done  because it always a 
race condition to check if a promise is already resolved (`isDone()`) and then 
resolve the promise. 
   
   The methods `celix::Deferred<T>::tryFail` and 
`celix::Deferred<T>::tryResolve` are added to resolve a promise and check if it 
was already resolved atomically.  


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@celix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to