Issue Details (XML | Word | Printable)

Key: DIRMINA-120
Type: Improvement Improvement
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Trustin Lee
Reporter: Trustin Lee
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
MINA

Callbacks for IoFutures

Created: 12/Nov/05 08:33 AM   Updated: 14/Nov/05 06:37 PM
Component/s: None
Affects Version/s: None
Fix Version/s: 0.9.0

Time Tracking:
Not Specified

File Attachments:
  Size
Java Source File Licensed for inclusion in ASF works ConnectFuture.java 2005-11-12 07:35 PM dave irving 4 kB
Java Source File Licensed for inclusion in ASF works IoFuture.java 2005-11-12 07:34 PM dave irving 4 kB

Resolution Date: 14/Nov/05 06:37 PM


 Description  « Hide
IoFuture provides only blocking-way ('join' method) for user to find out the result of an I/O request. It would be great if users can specify a callback:

ConnectFuture future = connector.connect(...);
future.setCallback( new ConnectFuture.Callback() {
    public void connectionEstablished( IoSession session ) {
    }
    public void connectionFailed( Throwable cause ) {
    }
} );

There can be a race condition if the connection process ends before a user calls setCallback() method, but we can resolve this carefully so users don't notice any issue.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
There are no subversion log entries for this issue yet.