felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Guillaume Nodet (JIRA)" <j...@apache.org>
Subject [jira] Commented: (FELIX-2115) The api offers no way to have a timeout or cancel the resolution if it takes too long
Date Mon, 22 Feb 2010 08:06:28 GMT

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

Guillaume Nodet commented on FELIX-2115:

Yeah, I suppose so too.  I was gonna propose something even more disruptive, which is to split
the outcome of the resolution from the Resolver and have something like
    Future<Resolution> resolve();
But that might be a bit too disruptive.

Unless, there is some problems, I'm gonna go for the minimal api changes, i.e. just modify
the resolve() method in this way:
   boolean resolve() throws InterruptedException;

To cancel a resolution, the user would have to call Thread#interrupt() on the resolution thread
and this would abort the resolution and throw an InterruptedException.

> The api offers no way to have a timeout or cancel the resolution if it takes too long
> -------------------------------------------------------------------------------------
>                 Key: FELIX-2115
>                 URL: https://issues.apache.org/jira/browse/FELIX-2115
>             Project: Felix
>          Issue Type: Improvement
>          Components: Bundle Repository (OBR)
>            Reporter: Guillaume Nodet
> One way would be either to add some methods to the Resolver such as:
>    boolean resolve(long timeout)
>    void cancel();
> I'd be much happier if we could use a Future instead.
>    Future<Boolean> resolve();
> This would make it easier for the user because he doesn't have to start a thread on its
> However this breaks compatibility.
> We could therefore use something like:
>    Future<Boolean> startResolve();

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message