[ 
https://issues.apache.org/jira/browse/DIRMINA-661?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Emmanuel Lecharny updated DIRMINA-661:
--------------------------------------

    Fix Version/s: 2.0.0-M5

> DummySession.close(true) not notifying close listener
> -----------------------------------------------------
>
>                 Key: DIRMINA-661
>                 URL: https://issues.apache.org/jira/browse/DIRMINA-661
>             Project: MINA
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.0.0-M4
>         Environment: All?
>            Reporter: David Rosenstrauch
>            Assignee: Emmanuel Lecharny
>            Priority: Minor
>             Fix For: 2.0.0-M5
>
>
> I'm trying to add a close listener onto a session, and perform some 
> processing after the session close is completed. 
> This works fine on a live system (i.e., when using a NioSocketSession), but 
> when I unit test using a DummySession I never get notified about 
> operationComplete.
> See example JUnit test case at:
> http://www.darose.net/TestDummyIoSession.java
> -----
> Additional analysis, as per Emmanuel Lécharny :
> I think that the listeners are never called in the awaitUninterruptibly() 
> method :
>    /**
>     * {...@inheritdoc}
>     */
>    public IoFuture awaitUninterruptibly() {
>        try {
>            await0(Long.MAX_VALUE, false);
>        } catch ( InterruptedException ie) {
>            // Do nothing : this catch is just mandatory by contract
>        }
>   ...
> The doc is explicit here :
>    /**
>     * Wait for the asynchronous operation to complete uninterruptibly.
>     * *The attached listeners will be notified when the operation is
>     * completed.*
>     *
>     * @return the current IoFuture
>     */
>    IoFuture awaitUninterruptibly();
> The listeners are never called... 

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

Reply via email to