Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » Cannot connect to a git server using JGit
Cannot connect to a git server using JGit [message #1821356] Tue, 11 February 2020 17:10 Go to next message
Thomas Eidenmüller is currently offline Thomas EidenmüllerFriend
Messages: 1
Registered: February 2020
Junior Member
Hello, I have problems using JGit in combination with a payara server. Connecting to a remote git repository when manually calling the methods through tests works absolutely fine. But when these methods are called from an endpoint through a payara server I get the following error.

javax.ejb.TransactionRolledbackLocalException: Exception thrown from bean: java.lang.NoSuchFieldError: isEC
javax.ejb.TransactionRolledbackLocalException: Exception thrown from bean: java.lang.NoSuchFieldError: isEC
	at com.sun.ejb.containers.EJBContainerTransactionManager.checkExceptionClientTx(EJBContainerTransactionManager.java:668)
...
Caused by: java.lang.NoSuchFieldError: isEC
	at sun.security.ssl.Handshaker.getActiveProtocols(Handshaker.java:790)
	at sun.security.ssl.Handshaker.activate(Handshaker.java:549)
	at sun.security.ssl.SSLSocketImpl.kickstartHandshake(SSLSocketImpl.java:1482)
	at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1351)
	at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1403)
	at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1387)
	at sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:559)
        ...


I already debugged both methods, where I call the method through the endpoint over payara and through tests. In both cases the variables are identical. The authentication should be set through setCredentialsProvider() where username and password are correctly set in both cases. E.g. like in the following case:

Git.cloneRepository()
     .setURI(uri)
     .setDirectory(target)
     .setCredentialsProvider(new UsernamePasswordCredentialsProvider(auth.get("user").toString(), auth.get("pwd").toString()))
     .call();


When executed via the endpoint over payara the authentication to the git server fails. Does anyone have experience in this case? I am running a payara server version 5.183, which also runs only locally, and the latest version of JGit. Thanks in advance.
Re: Cannot connect to a git server using JGit [message #1821405 is a reply to message #1821356] Wed, 12 February 2020 16:10 Go to previous message
Thomas Wolf is currently offline Thomas WolfFriend
Messages: 374
Registered: August 2016
Senior Member
Sounds like https://github.com/payara/Payara/issues/2626 . Make sure you're running payara on at least Java 8u161. (Found by googling for "payara server isEC", came up as the third hit.)

[Updated on: Wed, 12 February 2020 16:10]

Report message to a moderator

Previous Topic:Can't update EGit
Next Topic:JGit - GerritHook?
Goto Forum:
  


Current Time: Wed Jun 23 16:04:08 GMT 2021

Powered by FUDForum. Page generated in 0.02402 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top