[jboss-jira] [JBoss JIRA] Closed: (JBREM-640) Implement an asynchronous method for handling callbacks.
Ron Sigal (JIRA)
jira-events at jboss.com
Sun Feb 4 03:21:19 EST 2007
[ http://jira.jboss.com/jira/browse/JBREM-640?page=all ]
Ron Sigal closed JBREM-640.
---------------------------
Resolution: Done
It is now possible to invoke push callbacks asynchronously in a manner analogous to ordinary asynchronous invocations.
A new interface, org.jboss.remoting.callback.AsynchInvokerCallbackHandler has been introduced:
public interface AsynchInvokerCallbackHandler extends InvokerCallbackHandler
{
public void handleCallbackOneway(Callback callback) throws HandleCallbackException;
public void handleCallbackOneway(Callback callback, boolean serverSide) throws HandleCallbackException;
public void handleCallback(Callback callback, boolean asynch, boolean serverSide) throws HandleCallbackException;
}
and org.jboss.remoting.callback.ServerInvokerCallbackHandler has been updated to implement AsynchInvokerCallbackHandler.
The serverSide argument to the second and third method is analogous to the clientSide argument to org.jboss.remoting.Client.invokeOneWay(). If serverSide is true, then the invocation will be performed in a separate thread on the server side, and if serverSide is false the invocation will be performed in a separate thread on the client side.
The changes have been committed to remoting_2_x and HEAD.
Unit tests are in org.jboss.test.callback.asynch and are of the form <transport>AsynchCallbackTestCase.
> Implement an asynchronous method for handling callbacks.
> --------------------------------------------------------
>
> Key: JBREM-640
> URL: http://jira.jboss.com/jira/browse/JBREM-640
> Project: JBoss Remoting
> Issue Type: Feature Request
> Security Level: Public(Everyone can see)
> Affects Versions: 2.2.0.Beta1 (Bluto)
> Reporter: Ron Sigal
> Assigned To: Ron Sigal
> Fix For: 2.2.0.Beta1 (Bluto)
>
>
> Tim Fox:
> Currently, it's my understanding that push callbacks (using socket transport anyway) are synchronous, i.e. the server side thread that executes the callback blocks until the callback has been delivered to the client side and returned.
> Is it currrently possible to execute asynch push callbacks? I.e. the thread that calls the callback returns immediately once it has registered the callback with remoting. And it is then delivered on a different thread?
> Ideally executing using some kind of executor (e.g. PooledExecutor) with a bounded queue size which blocks when it is full would be ideal.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list