Return-Path: X-Original-To: apmail-commons-issues-archive@minotaur.apache.org Delivered-To: apmail-commons-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id DAAA49016 for ; Thu, 21 Jun 2012 08:55:48 +0000 (UTC) Received: (qmail 81401 invoked by uid 500); 21 Jun 2012 08:55:48 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 81144 invoked by uid 500); 21 Jun 2012 08:55:48 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 79358 invoked by uid 99); 21 Jun 2012 08:55:43 -0000 Received: from issues-vm.apache.org (HELO issues-vm) (140.211.11.160) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 21 Jun 2012 08:55:43 +0000 Received: from isssues-vm.apache.org (localhost [127.0.0.1]) by issues-vm (Postfix) with ESMTP id 35BEE1416E9 for ; Thu, 21 Jun 2012 08:55:43 +0000 (UTC) Date: Thu, 21 Jun 2012 08:55:43 +0000 (UTC) From: "Benjamin Piwowarski (JIRA)" To: issues@commons.apache.org Message-ID: <991008362.38179.1340268943224.JavaMail.jiratomcat@issues-vm> In-Reply-To: <1700702922.18746.1339767462993.JavaMail.jiratomcat@issues-vm> Subject: [jira] [Commented] (VFS-422) Allows to create other channels in SftpFileSystem MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/VFS-422?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13398297#comment-13398297 ] Benjamin Piwowarski commented on VFS-422: ----------------------------------------- Please find a patch for this new functionality (along with tests & copyright information) A few comments on the patch: - SftpFileSystem has a counter for externally opened channels (and a read access to it in order to test the new functionality) - I had to create a CommonsVFSChannelHelper in the com.jcraft.jsch package in order to get access to package protected classes. - I added a new test case so that both the creation and the counter are tested, so that the function does not break in future versions. > Allows to create other channels in SftpFileSystem > ------------------------------------------------- > > Key: VFS-422 > URL: https://issues.apache.org/jira/browse/VFS-422 > Project: Commons VFS > Issue Type: Improvement > Affects Versions: 2.0 > Environment: Any > Reporter: Benjamin Piwowarski > Attachments: 0001-SftpFileSystems-allows-opening-external-channels.patch > > Original Estimate: 3h > Remaining Estimate: 3h > > In the software I am writing, I need to execute commands when the filesystems "allows" it, i.e. local or via ssh (i.e. sftp filesystem). > For a local filesystem, I can easily do this, but for Sftp, there is no way to get a channel different than the SFTP on, so it would be great if other channels could be open. > I could submit a patch that would: > 1) Allows a call to session.openChannel(String type) [following getChannel()] > 2) Overwrite isReleaseable to keep the filesystem open if some external channels are open -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira