1 Reply Latest reply on Jun 30, 2011 3:55 AM by Marek Posolda

    Repository not started exception while starting Gatein

    Megha Shah Newbie

      Hi,

      I am trying to setup Oracle DB 10g with Gatein 3.1 and getting the following errors while server startup. (see attached 'server.log' file for complete stacktrace)

       

      05:07:59,128 ERROR [RepositoryServiceImpl] Error start repository service: org.exoplatform.services.jcr.config.RepositoryConfigurationException: Repository conatainer repository was not started.

              at org.exoplatform.services.jcr.impl.RepositoryServiceImpl.createRepository(RepositoryServiceImpl.java:172) [:1.14.0-CR1]

              at org.exoplatform.services.jcr.impl.RepositoryServiceImpl.init(RepositoryServiceImpl.java:333) [:1.14.0-CR1]

              at org.exoplatform.services.jcr.impl.RepositoryServiceImpl.start(RepositoryServiceImpl.java:277) [:1.14.0-CR1]

              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_21]

              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) [:1.6.0_21]

              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) [:1.6.0_21]

              at java.lang.reflect.Method.invoke(Method.java:597) [:1.6.0_21]

              at org.exoplatform.container.LifecycleVisitor.traverse(LifecycleVisitor.java:100) [:2.3.0-CR1]

              at org.exoplatform.container.LifecycleVisitor.start(LifecycleVisitor.java:170) [:2.3.0-CR1]

              at org.exoplatform.container.ConcurrentPicoContainer.start(ConcurrentPicoContainer.java:554) [:2.3.0-CR1]

              at org.exoplatform.container.ExoContainer.start(ExoContainer.java:225) [:2.3.0-CR1]

              at org.exoplatform.container.PortalContainer.start(PortalContainer.java:667) [:2.3.0-CR1]

              at org.exoplatform.container.ExoContainer.start(ExoContainer.java:213) [:2.3.0-CR1]

              at org.exoplatform.container.RootContainer.createPortalContainer(RootContainer.java:399) [:2.3.0-CR1]

              at org.exoplatform.container.RootContainer.createPortalContainers(RootContainer.java:287) [:2.3.0-CR1]

              at org.exoplatform.container.web.PortalContainerCreator$2.run(PortalContainerCreator.java:74) [:2.3.0-CR1]

              at org.exoplatform.container.web.PortalContainerCreator$2.run(PortalContainerCreator.java:71) [:2.3.0-CR1]

              at java.security.AccessController.doPrivileged(Native Method) [:1.6.0_21]

              at org.exoplatform.commons.utils.SecurityHelper.doPrivilegedAction(SecurityHelper.java:284) [:2.3.0-CR1]

              at org.exoplatform.container.web.PortalContainerCreator.contextInitialized(PortalContainerCreator.java:70) [:2.3.0-CR1]

              at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3369) [:6.0.0.Final]

              at org.apache.catalina.core.StandardContext.start(StandardContext.java:3828) [:6.0.0.Final]

              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeployInternal(TomcatDeployment.java:294) [:6.0.0.Final]

              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeploy(TomcatDeployment.java:146) [:6.0.0.Final]

              at org.jboss.web.deployers.AbstractWarDeployment.start(AbstractWarDeployment.java:477) [:6.0.0.Final]

              at org.jboss.web.deployers.WebModule.startModule(WebModule.java:118) [:6.0.0.Final]

              at org.jboss.web.deployers.WebModule.start(WebModule.java:95) [:6.0.0.Final]

              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_21]

              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) [:1.6.0_21]

              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) [:1.6.0_21]

              at java.lang.reflect.Method.invoke(Method.java:597) [:1.6.0_21]

              at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157) [:6.0.0.GA]

              at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96) [:6.0.0.GA]

              at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) [:6.0.0.GA]

              at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:271) [:6.0.0.GA]

              at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:670) [:6.0.0.GA]

              at org.jboss.system.microcontainer.ServiceProxy.invoke(ServiceProxy.java:206) [:2.2.0.GA]

              at $Proxy41.start(Unknown Source)       at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:53) [:

      2.2.0.GA]

              at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:41) [:2.2.0.GA]

              at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62) [jboss-dependency.jar:

      2.2.0.GA]

              at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:379) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.system.microcontainer.ServiceControllerContext.install(ServiceControllerContext.java:301) [:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2044) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1083) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1322) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1246) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1139) [jboss-dependency.jar:2.2.0.GA]

      :

        at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:894) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:641) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:182) [:2.2.0.GA]

              at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:58) [:2.2.0.GA]

              at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62) [:2.2.0.GA]

              at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:55) [:2.2.0.GA]

              at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:179) [:2.2.0.GA]

              at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1832) [:2.2.0.GA]

              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1550) [:2.2.0.GA]

              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1571) [:2.2.0.GA]

              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1603) [:2.2.0.GA]

              at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1491) [:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:379) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2044) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1083) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1322) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1246) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1139) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:939) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:654) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.deployers.plugins.deployers.DeployersImpl.change(DeployersImpl.java:1983) [:2.2.0.GA]

              at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:1076) [:2.2.0.GA]

              at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:679) [:2.2.0.GA]

              at org.jboss.system.server.profileservice.deployers.MainDeployerPlugin.process(MainDeployerPlugin.java:106) [:6.0.0.Final]

              at org.jboss.profileservice.dependency.ProfileControllerContext$DelegateDeployer.process(ProfileControllerContext.java:143) [:0.2.2]

              at org.jboss.profileservice.dependency.ProfileDeployAction.deploy(ProfileDeployAction.java:151) [:0.2.2]

              at org.jboss.profileservice.dependency.ProfileDeployAction.installActionInternal(ProfileDeployAction.java:94) [:0.2.2]

              at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:54) [jboss-kernel.jar:2.2.0.GA]

              at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:42) [jboss-kernel.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:379) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2044) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1083) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1322) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1246) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1139) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:939) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:654) [jboss-dependency.jar:2.2.0.GA]

              at org.jboss.profileservice.dependency.ProfileActivationWrapper$BasicProfileActivation.start(ProfileActivationWrapper.java:190) [:0.2.2]

              at org.jboss.profileservice.dependency.ProfileActivationWrapper.start(ProfileActivationWrapper.java:87) [:0.2.2]

              at org.jboss.profileservice.dependency.ProfileActivationService.activateProfile(ProfileActivationService.java:215) [:0.2.2]

              at org.jboss.profileservice.dependency.ProfileActivationService.activate(ProfileActivationService.java:159) [:0.2.2]

              at org.jboss.profileservice.bootstrap.AbstractProfileServiceBootstrap.activate(AbstractProfileServiceBootstrap.java:112) [:0.2.2]

              at org.jboss.profileservice.resolver.BasicResolverFactory$ProfileResolverFacade.deploy(BasicResolverFactory.java:87) [:0.2.2]

              at org.jboss.profileservice.bootstrap.AbstractProfileServiceBootstrap.start(AbstractProfileServiceBootstrap.java:91) [:0.2.2]

              at org.jboss.system.server.profileservice.bootstrap.BasicProfileServiceBootstrap.start(BasicProfileServiceBootstrap.java:132) [:6.0.0.Final]

              at org.jboss.system.server.profileservice.bootstrap.BasicProfileServiceBootstrap.start(BasicProfileServiceBootstrap.java:56) [:6.0.0.Final]

              at org.jboss.bootstrap.impl.base.server.AbstractServer.startBootstraps(AbstractServer.java:827) [jboss-bootstrap-impl-base.jar:2.1.0-alpha-5]

              at org.jboss.bootstrap.impl.base.server.AbstractServer$StartServerTask.run(AbstractServer.java:417) [jboss-bootstrap-impl-base.jar:2.1.0-alpha-5]

              at java.lang.Thread.run(Thread.java:619) [:1.6.0_21]

      Caused by: org.picocontainer.PicoIntrospectionException: Failed when calling start on org.exoplatform.services.jcr.impl.WorkspaceContainer@3bcd4840

              at org.exoplatform.container.LifecycleVisitor.traverse(LifecycleVisitor.java:136) [:2.3.0-CR1]

              at org.exoplatform.container.LifecycleVisitor.start(LifecycleVisitor.java:170) [:2.3.0-CR1]

              at org.exoplatform.container.ConcurrentPicoContainer.start(ConcurrentPicoContainer.java:554) [:2.3.0-CR1]

              at org.exoplatform.container.ExoContainer.start(ExoContainer.java:225) [:2.3.0-CR1]

              at org.exoplatform.services.jcr.impl.RepositoryContainer.start(RepositoryContainer.java:540) [:1.14.0-CR1]

              at org.exoplatform.services.jcr.impl.RepositoryServiceImpl$1.run(RepositoryServiceImpl.java:161) [:1.14.0-CR1]

      :

       

      My configuration.properties file looks like below: ( the portion in bold is the only place I made changes)

       

      gatein.conf.dir=${jboss.server.home.dir}/conf/gatein

      gatein.data.dir=${jboss.server.data.dir}/gatein

       

       

      # DB

      gatein.db.data.dir=${gatein.data.dir}/db

       

       

      # JCR

      gatein.jcr.config.type=local

      gatein.jcr.datasource.name=java:jdbcjcr

      gatein.jcr.datasource.dialect=auto

      gatein.jcr.datasource.driver=oracle.jdbc.driver.OracleDriver

      gatein.jcr.datasource.url=jdbc:oracle:thin:jbportal/tskyjbportal@10.130.82.44:1527:ucportal

      gatein.jcr.datasource.username=jbportal

      gatein.jcr.datasource.password=tskyjbportal

       

       

      gatein.jcr.data.dir=${gatein.data.dir}/jcr

      gatein.jcr.storage.data.dir=${gatein.jcr.data.dir}/values

      gatein.jcr.cache.config=classpath:/conf/jcr/jbosscache/${gatein.jcr.config.type}/config.xml

      gatein.jcr.lock.cache.config=classpath:/conf/jcr/jbosscache/${gatein.jcr.config.type}/lock-config.xml

      gatein.jcr.index.data.dir=${gatein.jcr.data.dir}/lucene

      gatein.jcr.index.changefilterclass=org.exoplatform.services.jcr.impl.core.query.DefaultChangesFilter

      gatein.jcr.index.cache.config=classpath:/conf/jcr/jbosscache/cluster/indexer-config.xml

      gatein.jcr.jgroups.config=classpath:/conf/jcr/jbosscache/cluster/udp-mux.xml

       

       

      # IDM

      gatein.idm.datasource.name=java:jdbcidm

      gatein.idm.datasource.driver=org.hsqldb.jdbcDriver

      gatein.idm.datasource.url=jdbc:hsqldb:file:${gatein.db.data.dir}/data/jdbcidm_${name}

      gatein.idm.datasource.username=sa

      gatein.idm.datasource.password=

       

       

      # EMail

      gatein.email.smtp.username=

      gatein.email.smtp.password=

      gatein.email.smtp.host=smtp.gmail.com

      gatein.email.smtp.port=465

      gatein.email.smtp.starttls.enable=true

      gatein.email.smtp.auth=true

      gatein.email.smtp.socketFactory.port=465

      gatein.email.smtp.socketFactory.class=javax.net.ssl.SSLSocketFactory

       

       

      # Global portlet.xml

      gatein.portlet.config=${gatein.conf.dir}/portlet.xml

       

      # Web

      gatein.web.compressor.js.level=simple

       

      I have also removed the 'gatein-sample-portal.ear' from the /deploy directory.

       

      What I am noticing is the JCR has created the following tables in my database (the server started properly the first time)

       

      1. JCRLOCK_PORTAL_SYSTEM

      2. JCRLOCK_PORTAL_SYSTEM_D

      3. JCRLOCK_PORTAL_WORK

      4. JCRLOCK_PORTAL_WORK_D

      5. JCRLOCK_SAMPLE_WS

      6. JCRLOCK_SAMPLE_WS_D7. JCRLOCK_SYSTEM

      8. JCRLOCK_SYSTEM_D

      9. JCR_SCONTAINER

      10. JCR_SITEM

      11. JCR_SREF

      12. JCR_SVALUE

       

      I suspect some/many tables are missing. Is that so?

       

      Please help.

       

      Thanks,

      Megha

        • 1. Re: Repository not started exception while starting Gatein
          Marek Posolda Apprentice

          Hi Megha,

           

          GateIn portal is using 2 databases. First for Identity stuff (Picketlink IDM) and second for JCR. Picketlink tables have prefix "jbid_" and JCR tables have prefix "JCR". From your post http://community.jboss.org/message/611140#611140, it seems that only JCR tables were created in your Oracle DB, because IDM datasource is still configured to use HSQLDB . You will need to change it and then you will see tables "jbid_..." in your DB.

           

          Updating of role /platform/users is done in Picketlink IDM database (namely in table jbid_io_rel ). Once you will uncomment CustomMembershipLoginModule, users will be automatically added and DB will be updated according to it.

           

          I guess the hardest part will be to setup login modules to successfully authenticate users from legacy JBoss Portal DB. Maybe you can reuse some parts from JBoss Portal codebase and add login modules from JBP .

           

          Another option (and maybe easier but it depends on your needs) can be to left GateIn login modules, but create your own implementation of interface org.exoplatform.services.security.Authenticator and bind your implementation into eXo kernel to override default implementation, which is org.exoplatform.services.organization.auth.OrganizationAuthenticatorImpl . Especially you will need to implement method "validateUser" to perform validation against JBoss Portal database.

           

          Good luck,

          Marek