Community
Participate
Working Groups
We would like to reuse the Jsch session we already have, but keep it encapsulated and thus not pass it to JGit. Thus it would be nice if TransportGitSsh had a setConnectionFactory method and newConnection would use that factory to create a connection if a factory is available. The connection factory should return a class extending TransportGitSsh.Connection. Thus this class would have to be made public.
We'd love a patch to start the discussion... http://wiki.eclipse.org/EGit/Contributor_Guide#Contributing_Patches
Created attachment 189039 [details] Ease access restrictions to allow subclassing of TransportGitSsh Rather than creating a connection factory, as first suggested, Roland and I can achieve our goal by being able to subclass TransportGitSsh. This allows us to create our own TransportGitSsh.Connection. Also, the resulting patch is much smaller (only the word "protected" is added in several places, along with required javadoc comments). A more elegant solution could use a connection factory and make the TransportGitSsh.Connection class non-nested. Such a Connection class could allow the remote execution by any method (e.g. telnet, rsh, etc.) (In our case we use org.eclipse.ptp.remote.core.IRemoteProcessBuilder)
Do you mind contributing this patch to our Gerrit instance at http://egit.eclipse.org as outlined in our contributor guide? http://wiki.eclipse.org/EGit/Contributor_Guide#Contributing_Patches
I have just contributed the patch to your Gerrit instance.
Thanks John, we'll look at this soon!
Can you update your patch based on Shawn's comments John?
Yes, we are working on a patch that includes a connection factory. It should be ready by tomorrow or Wednesday at the latest.
I have just contributed a new patch to your Gerrit instance.
A new patch is now available on your Gerrit instance.
John and Roland, the foundation requests that you confirm the following by replying to this bug: 1. You have authored 100% of the content contained within the patch. 2. You have the rights to contribute the content to the JGit project. 3. You agree you are contributing the content under the EDL, which is the BSD license appearing in our file headers.
(In reply to comment #10) 1. I have authored together with John Eblen 100% of the content contained within the patch. 2. I have the rights to contribute the content to the JGit project. 3. I agree I am contributing the content under the EDL. (In case it matters: I am Eclipse Committer (for the PTP project))
John, can you make similar statements?
1. I have authored, along with Roland Schulz, 100% of the content contained within the patch. 2. I have the rights to contribute the content to the JGit project. 3. I agree I am contributing the content under the EDL.
Thanks guys. Now we just have to wait for the CQ... https://dev.eclipse.org/ipzilla/show_bug.cgi?id=5004
CQ is approved now and code is merged into master. Thanks guys! Sorry for the wait, the IP team is busy around this time of year.