Uploaded image for project: 'ModeShape'
  1. ModeShape
  2. MODE-2352

Git Connector exceptions when navigating via the REST service

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 4.1.0.Final
    • 4.0.0.Final, 3.8.1.Final
    • None
    • None

    Description

      When browsing a repository with the Git connector configured via the REST service, accessing certain URLs raises unexpected exceptions:

      1. http://localhost:8080/modeshape-rest/federatedRepository/default/items/gitRepo/tree/72ea74be3b3a50345a1b2f543f78fd6be00caa35

      6:24:01,121 ERROR [org.modeshape.web.jcr.rest.ModeShapeExceptionMapper] (default task-26) Server error: javax.jcr.RepositoryException: No valid property definition on node '/gitRepo/tree/72ea74be3b3a50345a1b2f543f78fd6be00caa35' with primary type 'git:folder' and mixin types [] for the property: git:detail="46f1a0beaa9871/commit/72ea74be3b3a50345a1b2f543f78fd6be00caa35"
             at org.modeshape.jcr.AbstractJcrNode.findJcrProperties(AbstractJcrNode.java:2035) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             at org.modeshape.jcr.AbstractJcrNode.getProperties(AbstractJcrNode.java:2043) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             at org.modeshape.web.jcr.rest.handler.AbstractHandler.createRestNode(AbstractHandler.java:304) [modeshape-web-jcr-rest-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             at org.modeshape.web.jcr.rest.handler.AbstractHandler.createRestItem(AbstractHandler.java:243) [modeshape-web-jcr-rest-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             at org.modeshape.web.jcr.rest.handler.RestItemHandler.item(RestItemHandler.java:67) [modeshape-web-jcr-rest-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             at org.modeshape.web.jcr.rest.ModeShapeRestService.getItem(ModeShapeRestService.java:303) [modeshape-web-jcr-rest-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             at sun.reflect.GeneratedMethodAccessor27.invoke(Unknown Source) [:1.7.0_40]
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_40]
             at java.lang.reflect.Method.invoke(Method.java:606) [rt.jar:1.7.0_40]
             at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:137) [resteasy-jaxrs-3.0.8.Final.jar:]
             at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTarget(ResourceMethodInvoker.java:296) [resteasy-jaxrs-3.0.8.Final.jar:]
             at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:250) [resteasy-jaxrs-3.0.8.Final.jar:]
             at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:237) [resteasy-jaxrs-3.0.8.Final.jar:]
             at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:356) [resteasy-jaxrs-3.0.8.Final.jar:]
             at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:179) [resteasy-jaxrs-3.0.8.Final.jar:]
             at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:220) [resteasy-jaxrs-3.0.8.Final.jar:]
             at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:56) [resteasy-jaxrs-3.0.8.Final.jar:]
             at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:51) [resteasy-jaxrs-3.0.8.Final.jar:]
             at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) [jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
             at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:85) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:61) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)
             at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:113) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:56) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.server.handlers.DisableCacheHandler.handleRequest(DisableCacheHandler.java:27) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.security.handlers.AuthenticationConstraintHandler.handleRequest(AuthenticationConstraintHandler.java:51) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:45) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:61) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.security.ServletSecurityConstraintHandler.handleRequest(ServletSecurityConstraintHandler.java:56) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:58) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:70) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.security.handlers.SecurityInitialHandler.handleRequest(SecurityInitialHandler.java:76) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)
             at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.SessionRestoringHandler.handleRequest(SessionRestoringHandler.java:101) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:240) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:227) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:73) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:146) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.server.Connectors.executeRootHandler(Connectors.java:177) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:727) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
             at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_40]
             at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_40]
             at java.lang.Thread.run(Thread.java:724) [rt.jar:1.7.0_40]
      aused by: javax.jcr.nodetype.ConstraintViolationException: No valid property definition on node '/gitRepo/tree/72ea74be3b3a50345a1b2f543f78fd6be00caa35' with primary type 'git:folder' and mixin types [] for the property: git:detail="46f1a0beaa9871/commit/72ea74be3b3a50345a1b2f543f78fd6be00caa35"
             at org.modeshape.jcr.AbstractJcrNode.propertyDefinitionFor(AbstractJcrNode.java:473) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             at org.modeshape.jcr.AbstractJcrNode.createJcrProperty(AbstractJcrNode.java:394) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             at org.modeshape.jcr.AbstractJcrNode.getProperty(AbstractJcrNode.java:358) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             at org.modeshape.jcr.AbstractJcrNode.findJcrProperties(AbstractJcrNode.java:2028) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
             ... 48 more
      

      2. http://localhost:8080/modeshape-rest/federatedRepository/default/items/gitRepo/commits/d1f7daf32bd67edded7545221cd5c79d94813310

      16:28:33,217 ERROR [org.modeshape.web.jcr.rest.ModeShapeExceptionMapper] (default task-33) Server error: org.modeshape.jcr.cache.DocumentStoreException: /commits
              at org.modeshape.connector.git.GitConnector.getChildren(GitConnector.java:252)
              at org.modeshape.jcr.federation.FederatedDocumentStore.getChildrenBlock(FederatedDocumentStore.java:407) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
              at org.modeshape.jcr.cache.document.WorkspaceCache.blockFor(WorkspaceCache.java:195) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
              at org.modeshape.jcr.cache.document.ImmutableChildReferences$Segment.next(ImmutableChildReferences.java:800) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
              at org.modeshape.jcr.cache.document.ImmutableChildReferences$Segmented$2.hasNext(ImmutableChildReferences.java:596) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
              at org.modeshape.jcr.JcrChildNodeIterator.hasNext(JcrChildNodeIterator.java:102) [modeshape-jcr-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
              at org.modeshape.web.jcr.rest.handler.AbstractHandler.createRestNode(AbstractHandler.java:310) [modeshape-web-jcr-rest-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
              at org.modeshape.web.jcr.rest.handler.AbstractHandler.createRestItem(AbstractHandler.java:243) [modeshape-web-jcr-rest-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
              at org.modeshape.web.jcr.rest.handler.RestItemHandler.item(RestItemHandler.java:67) [modeshape-web-jcr-rest-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
              at org.modeshape.web.jcr.rest.ModeShapeRestService.getItem(ModeShapeRestService.java:303) [modeshape-web-jcr-rest-4.1-SNAPSHOT.jar:4.1-SNAPSHOT]
              at sun.reflect.GeneratedMethodAccessor27.invoke(Unknown Source) [:1.7.0_40]
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_40]
              at java.lang.reflect.Method.invoke(Method.java:606) [rt.jar:1.7.0_40]
              at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:137) [resteasy-jaxrs-3.0.8.Final.jar:]
              at org.jboss.resteasy.core.ResourceMethodInvoker.invokeOnTarget(ResourceMethodInvoker.java:296) [resteasy-jaxrs-3.0.8.Final.jar:]
              at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:250) [resteasy-jaxrs-3.0.8.Final.jar:]
              at org.jboss.resteasy.core.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:237) [resteasy-jaxrs-3.0.8.Final.jar:]
              at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:356) [resteasy-jaxrs-3.0.8.Final.jar:]
              at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:179) [resteasy-jaxrs-3.0.8.Final.jar:]
              at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:220) [resteasy-jaxrs-3.0.8.Final.jar:]
              at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:56) [resteasy-jaxrs-3.0.8.Final.jar:]
              at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:51) [resteasy-jaxrs-3.0.8.Final.jar:]
              at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) [jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
              at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:85) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:61) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)
              at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:113) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:56) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.server.handlers.DisableCacheHandler.handleRequest(DisableCacheHandler.java:27) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.security.handlers.AuthenticationConstraintHandler.handleRequest(AuthenticationConstraintHandler.java:51) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:45) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:61) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.security.ServletSecurityConstraintHandler.handleRequest(ServletSecurityConstraintHandler.java:56) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:58) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:70) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.security.handlers.SecurityInitialHandler.handleRequest(SecurityInitialHandler.java:76) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at org.wildfly.extension.undertow.security.jacc.JACCContextIdHandler.handleRequest(JACCContextIdHandler.java:61)
              at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.SessionRestoringHandler.handleRequest(SessionRestoringHandler.java:101) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:240) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:227) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:73) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:146) [undertow-servlet-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.server.Connectors.executeRootHandler(Connectors.java:177) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:727) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_40]
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_40]
              at java.lang.Thread.run(Thread.java:724) [rt.jar:1.7.0_40]
      Caused by: org.eclipse.jgit.errors.AmbiguousObjectException: Object abbreviation 15 is ambiguous
              at org.eclipse.jgit.lib.Repository.resolveAbbreviation(Repository.java:774)
              at org.eclipse.jgit.lib.Repository.resolveSimple(Repository.java:714)
              at org.eclipse.jgit.lib.Repository.resolve(Repository.java:683)
              at org.eclipse.jgit.lib.Repository.resolve(Repository.java:383)
              at org.modeshape.connector.git.GitFunction.addCommitsAsPageOfChildren(GitFunction.java:272)
              at org.modeshape.connector.git.GitHistory.execute(GitHistory.java:138)
              at org.modeshape.connector.git.GitConnector.getChildren(GitConnector.java:250)
              ... 52 more
      

      Attachments

        Activity

          People

            hchiorean Horia Chiorean (Inactive)
            hchiorean Horia Chiorean (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: