Attaching resources to a VCS connection in Data Virtualization fails with error "not authorized"

Attaching resources to a VCS connection in Data Virtualization fails with error "not authorized"

book

Article ID: KB0137915

calendar_today

Updated On:

Products Versions
TIBCO Data Virtualization All supported versions

Description

After creating a VCS connection in Data Virtualization(DV), attaching resources fails with below error in the cs_server.log file - 

====

ERROR [jetty thread pool-11024] 2025-08-21 21:19:59.222 -0400 VCSRestAPI - null
com.compositesw.server.vcs.VCSException: Failed to execute vcs command, error detail is "".  [vcs-2970001]
at com.compositesw.server.api.core.VCSApi.pushToVCS(VCSApi.java:1373) ~[csserver.jar:?]
at com.compositesw.server.api.core.VCSApi.addRootPath(VCSApi.java:360) ~[csserver.jar:?]
at com.compositesw.rest.VCSRestAPI.addRootPath(VCSRestAPI.java:815) ~[csrestapi.jar:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[?:?]
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:568) ~[?:?]
at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory.lambda$static$0(ResourceMethodInvocationHandlerFactory.java:52) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher$1.run(AbstractJavaResourceMethodDispatcher.java:134) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:177) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:176) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:81) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:478) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:400) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:81) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:256) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:248) ~[jersey-common-2.39.1.jar:?]
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:244) ~[jersey-common-2.39.1.jar:?]
at org.glassfish.jersey.internal.Errors.process(Errors.java:292) ~[jersey-common-2.39.1.jar:?]
at org.glassfish.jersey.internal.Errors.process(Errors.java:274) ~[jersey-common-2.39.1.jar:?]
at org.glassfish.jersey.internal.Errors.process(Errors.java:244) ~[jersey-common-2.39.1.jar:?]
at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:265) ~[jersey-common-2.39.1.jar:?]
at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:235) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:684) ~[jersey-server-2.39.1.jar:?]
at org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:394) ~[jersey-container-servlet-core-2.39.1.jar:?]
at org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:346) ~[jersey-container-servlet-core-2.39.1.jar:?]
at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:358) ~[jersey-container-servlet-core-2.39.1.jar:?]
at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:311) ~[jersey-container-servlet-core-2.39.1.jar:?]
at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:205) ~[jersey-container-servlet-core-2.39.1.jar:?]
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:811) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1668) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at dist.apps.server.dmServlet.NoCacheFilter.doFilter(NoCacheFilter.java:25) ~[csserver.jar:?]
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1651) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at com.compositesw.server.services.AccessToolsUriFilter.doFilter(AccessToolsUriFilter.java:64) ~[csserver.jar:?]
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1651) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at com.compositesw.server.services.AuthenticationFilter.doFilter(AuthenticationFilter.java:107) ~[csserver.jar:?]
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1651) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at com.compositesw.server.services.SecureSessionCookieFilter.doFilter(SecureSessionCookieFilter.java:59) ~[csserver.jar:?]
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1651) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at com.compositesw.server.services.SecurityHeadersFilter.doFilter(SecurityHeadersFilter.java:106) ~[csserver.jar:?]
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1651) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:584) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:142) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:576) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:222) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1126) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:514) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:184) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1060) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:140) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:212) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:109) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:96) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.Server.handle(Server.java:498) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:310) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:258) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.io.AbstractConnection$2.run(AbstractConnection.java:544) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555) ~[jetty-all-9.2.30.v20200428.jar:9.2.30.v20200428]
at java.lang.Thread.run(Thread.java:842) ~[?:?]
Caused by: com.compositesw.server.vcs.VCSException: Failed to execute vcs command, error detail is "".  [vcs-2970001]
at com.compositesw.server.vcs.GitVCSOperations.commitToVCS(GitVCSOperations.java:221) ~[csserver.jar:?]
at com.compositesw.server.api.core.VCSApi.pushToVCS(VCSApi.java:1366) ~[csserver.jar:?]
... 59 more
Caused by: org.eclipse.jgit.api.errors.TransportException: https://github.com/sidvcs03/testrepo: not authorized
at org.eclipse.jgit.api.PushCommand.call(PushCommand.java:180) ~[org.eclipse.jgit-4.11.8.201904181247-r.jar:4.11.8.201904181247-r]
at com.compositesw.server.vcs.GitVCSOperations.commitToVCS(GitVCSOperations.java:214) ~[csserver.jar:?]
at com.compositesw.server.api.core.VCSApi.pushToVCS(VCSApi.java:1366) ~[csserver.jar:?]
... 59 more
Caused by: org.eclipse.jgit.errors.TransportException: https://github.com/sidvcs03/testrepo: not authorized
at org.eclipse.jgit.transport.TransportHttp.connect(TransportHttp.java:529) ~[org.eclipse.jgit-4.11.8.201904181247-r.jar:4.11.8.201904181247-r]
at org.eclipse.jgit.transport.TransportHttp.openPush(TransportHttp.java:435) ~[org.eclipse.jgit-4.11.8.201904181247-r.jar:4.11.8.201904181247-r]
at org.eclipse.jgit.transport.PushProcess.execute(PushProcess.java:160) ~[org.eclipse.jgit-4.11.8.201904181247-r.jar:4.11.8.201904181247-r]
at org.eclipse.jgit.transport.Transport.push(Transport.java:1344) ~[org.eclipse.jgit-4.11.8.201904181247-r.jar:4.11.8.201904181247-r]
at org.eclipse.jgit.api.PushCommand.call(PushCommand.java:169) ~[org.eclipse.jgit-4.11.8.201904181247-r.jar:4.11.8.201904181247-r]
at com.compositesw.server.vcs.GitVCSOperations.commitToVCS(GitVCSOperations.java:214) ~[csserver.jar:?]
at com.compositesw.server.api.core.VCSApi.pushToVCS(VCSApi.java:1366) ~[csserver.jar:?]
... 59 more

====

Screenshot for reference - 

image.png

Environment

All supported Operating Systems

Resolution

To resolve this issue we need to generate a token in version control system and grant scopes.

Follow below steps - 

(1) Login to GitHub profile > click on the top right corner user icon. Go to settings > Developer Settings. 

(2) Select Personal access tokens > Tokens (classic).  Click on 'Generate new token' > Generate new token (classic). 

Screenshot for reference - 

image.png

(3) Give a name for the token. Select all the checkboxes under scopes and click 'generate token'.

(4) Save the token in a safe place for future use. 

(5) In DV Studio > VCS > manage connection. Create a new connection. 

In the Verify connection section, provide the user and copy the token in the password field. 

Select Type as 'Git' and provide the URL. Set an encryption password and verify the connection by clicking on 'verify' button to get the branch list - 

image.png

 

(6) After the VCS connection is created, now attach the required resources to the VCS connection. Choose the correct option that meets your needs - 

image.png

(7) The resources should not be attached successfully to the VCS connection - 

 image.png

 

 

Issue/Introduction

Attaching resources to a VCS connection in Data Virtualization fails with error "not authorized".