[
https://issues.apache.org/jira/browse/SSHD-1280?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17569036#comment-17569036
]
dgü commented on SSHD-1280:
---------------------------
This is for {_}OpenFuture#cancel(){_}:
{code:java}
/**
* Cancels the connection attempt and notifies all threads waiting for this
future.
*/
void cancel();
{code}
Ref:
[https://github.com/apache/mina-sshd/blob/master/sshd-core/src/main/java/org/apache/sshd/client/future/OpenFuture.java]
According to my tests;
* OpenFuture#cancel() cancels channel open attempt only if channel open is not
completed yet. If channel open is completed, it doesn't cancel.
> Clarification of ConnectFuture#cancel(), AuthFuture#cancel(),
> OpenFuture#cancel behaviours if connection,auhentication,channel open are
> already done respectively
> -----------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: SSHD-1280
> URL: https://issues.apache.org/jira/browse/SSHD-1280
> Project: MINA SSHD
> Issue Type: Documentation
> Affects Versions: 2.8.0
> Environment: Java SE 8, NetBeans IDE 8.2
> Reporter: dgü
> Priority: Major
>
> Hello!
>
> {code:java}
> /**
> * Cancels the connection attempt and notifies all threads waiting for
> this future.
> */
> void cancel();
> {code}
> Ref:
> [https://github.com/apache/mina-sshd/blob/master/sshd-core/src/main/java/org/apache/sshd/client/future/ConnectFuture.java]
> {code:java}
> /**
> * Cancels the authentication attempt and notifies all threads waiting
> for this future.
> */
> void cancel();
> {code}
> Ref:
> [https://github.com/apache/mina-sshd/blob/master/sshd-core/src/main/java/org/apache/sshd/client/future/AuthFuture.java]
> According to my tests;
> * ConnectFuture#cancel() cancels client session connection attempt only if
> connection is not established yet. If connection is established, it doesn't
> cancel.
> * AuthFuture#cancel() cancels client authentication attempt only if
> authentication is not completed yet. If authentication is completed, it
> doesn't cancel.
> are these behaviours are expected ? If so, it is possible to update the
> documentation to rely on these behaviours ?
> Thanks in advance!
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]