PTCInc / thingworx-gitbackup-extension

[Unofficial/Not supported] ThingWorx GitBackup Extension for storing your ThingWorx application code in a Git repository
MIT License
25 stars 11 forks source link

If i Push the entities it'll only getting pushed in File Repository and not in Git Repository. Thingworx version -9.2.3 #28

Closed anitas4 closed 1 year ago

anitas4 commented 2 years ago

Logs - -Error [authenticating connection], Server websocket will be closed. cause: Missing application key!

anitas4 commented 2 years ago

Can anyone reply?

cbadici commented 2 years ago

Hi, This looks to me like an authorization issue related to your Git repository. Have you properly configured your Git Backup Thing? Please describe the steps you performed so I can try to reproduce your issue.

anitas4 commented 2 years ago

image image Referred the Guide and configured same.

cbadici commented 2 years ago

Connectivity to a variety of Git repositories has been previously verified and it works as expected. I notice that your error is related to permissions for a GitHub repository. Did you set up your personal access token in GitHub and used it in the Password field in your Git Backup thing's configuration table?

anitas4 commented 2 years ago

yes, added PAT and tried still getting error.

org.eclipse.jgit.api.errors.TransportException: https://github.com/xyz/xyz.git: error occurred during unpacking on the remote end: index-pack abnormal exit at org.eclipse.jgit.api.PushCommand.call(PushCommand.java:147) at gb.GitBackupTemplate.Push(GitBackupTemplate.java:244) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:566)_ at

cbadici commented 2 years ago

This error is related to the fact that the git client cannot write to the remote repository because either permissions are missing or the capacity is full. I assume it is related to missing permissions since the remote repository would be empty right now. Did you assign all the permissions when you created the PAT? Just edit the token and check all the boxes for the permissions.

anitas4 commented 2 years ago

i have given all the permissions to PAT and my repo is also empty

anitas4 commented 2 years ago

Please reply

anitas4 commented 2 years ago

access issue resolved but not able to push into another branch other than 'master', if try to push to another branch it is getting added in master branch only.

anitas4 commented 2 years ago

Can someone reply?

stefan-lacatus commented 2 years ago

What repository are you pushing to? Is it literally https://github.com/xyz/xyz.git? Do you have access to it?

anitas4 commented 2 years ago

I am pushing into my personal repo and this is just demo repo link i have given, and yes i have access. Not able to push into another branch is related to Access issue?

anitas4 commented 2 years ago

any suggestions?

cbadici commented 2 years ago

@anitas4 Have you managed to push your entities on a different branch? I have tested the Git extension on multiple branches and I have no issues. You need to first create your remote branch, pull the repository. Then in the Mashup you select your remote branch (a local branch will be automatically created for you). You can check it out, you add your content/or remove content and then you push it. The commit info will show that you have pushed the content on your respective branch. let me know if this has worked for you. The same can be done just with services, by switching the branch in the Git configuration table.

ksmbasha1 commented 2 years ago

when I am trying to push the files in GIT, I a getting this error org.eclipse.jgit.api.errors.TransportException: https://github.com/ksmbasha11/repo101.git: not authorized at org.eclipse.jgit.api.PushCommand.call(PushCommand.java:147) at gb.GitBackupTemplate.Push(GitBackupTemplate.java:243) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.thingworx.common.processors.ReflectionProcessor.processService(ReflectionProcessor.java:261) at com.thingworx.handlers.ReflectionServiceHandler.processService(ReflectionServiceHandler.java:50) at com.thingworx.handlers.ServiceHandlerBase.processServiceWithMetrics(ServiceHandlerBase.java:48) at com.thingworx.things.Thing.processServiceRequestDirect(Thing.java:8248) at com.thingworx.things.Thing.processAPIServiceRequest(Thing.java:8186) at com.thingworx.webservices.BaseService.handleInvoke(BaseService.java:3220) at com.thingworx.webservices.BaseService.service(BaseService.java:491) at javax.servlet.http.HttpServlet.service(HttpServlet.java:742) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.thingworx.security.contenttype.ContentTypeFilter.doFilter(ContentTypeFilter.java:138) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.thingworx.security.filter.ValidationFilter.doFilter(ValidationFilter.java:22) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.thingworx.security.authentication.AuthenticationFilter.propagateRequest(AuthenticationFilter.java:541) at com.thingworx.security.authentication.AuthenticationFilter.doFilter(AuthenticationFilter.java:210) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176) at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145) at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92) at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:389) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.thingworx.security.filter.ClickjackFilter.doFilter(ClickjackFilter.java:178) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.thingworx.security.filter.ProhibitIfNotLeaderFilter.doFilter(ProhibitIfNotLeaderFilter.java:120) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at com.thingworx.security.filter.HttpResponseHeadersFilter.doFilter(HttpResponseHeadersFilter.java:173) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:478) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81) at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:650) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342) at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:803) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1459) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:745)Caused by: org.eclipse.jgit.errors.TransportException: https://github.com/ksmbasha11/repo101.git: not authorized at org.eclipse.jgit.transport.TransportHttp.connect(TransportHttp.java:540) at org.eclipse.jgit.transport.TransportHttp.openPush(TransportHttp.java:436) at org.eclipse.jgit.transport.PushProcess.execute(PushProcess.java:127) at org.eclipse.jgit.transport.Transport.push(Transport.java:1335) at org.eclipse.jgit.api.PushCommand.call(PushCommand.java:137) ... 60 more__

ksmbasha1 commented 2 years ago

No Entities are showing image

ksmbasha1 commented 2 years ago

access issue resolved but not able to push into another branch other than 'master', if try to push to another branch it is getting added in master branch only.

can you help me on access isssue, i am having still that issue.

vrosu commented 1 year ago

In case you have new problems, please open a new issue. One issue in Github must belong to a single issue, not to be reused for multiple ones.