Uploaded image for project: 'Jackrabbit Content Repository'
  1. Jackrabbit Content Repository
  2. JCR-3123

Jackrabbit 1.6 doesn't work with JNDI datasource against Oracle database

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • 1.6, 1.6.5
    • None
    • None
    • Liferay 6.0.6 + Oracle 11g + jboss 5

    Description

      This is the error to configure datasource through to JNDI (Oracle)
      -------------------------------------------------------
      2011-10-13 08:47:54,411 ERROR [org.apache.jackrabbit.core.RepositoryImpl] (main) failed to start Repository: failed to load repository properties: failed to persist repository properties: null
      javax.jcr.RepositoryException: failed to load repository properties: failed to persist repository properties: null: failed to persist repository properties: null: null
      -----------------------------------------
      Repository.xml example:

      <!-- FILESYSTEM -->
      <FileSystem class="org.apache.jackrabbit.core.fs.db.OracleFileSystem">
      <param name="driver" value="javax.naming.InitialContext"/>
      <param name="url" value="java:jdbc/LiferayPool"/>
      <param name="schema" value="oracle"/>
      <param name="schemaObjectPrefix" value="LR_FS_"/>
      <param name="tableSpace" value="default"/>
      </FileSystem>

      <!-- SECURITY CONFIGURATION-->
      <Security appName="Jackrabbit">
      <AccessManager class="org.apache.jackrabbit.core.security.SimpleAccessManager" />
      <LoginModule class="org.apache.jackrabbit.core.security.SimpleLoginModule">
      <param name="anonymousId" value="anonymous" />
      </LoginModule>
      </Security>

      <!-- WORKSPACE location of workspaces root directory and name of default workspace -->
      <Workspaces rootPath="${rep.home}/workspaces" defaultWorkspace="liferay" />
      <Workspace name="Liferay">

      <FileSystem class="org.apache.jackrabbit.core.fs.db.OracleFileSystem">
      <param name="driver" value="javax.naming.InitialContext"/>
      <param name="url" value="java:jdbc/LiferayPool"/>
      <param name="schema" value="oracle"/>
      <param name="schemaObjectPrefix" value="LR_WS_FS_" />
      </FileSystem>
      <PersistenceManager class="org.apache.jackrabbit.core.persistence.bundle.OraclePersistenceManager">
      <param name="driver" value="javax.naming.InitialContext"/>
      <param name="url" value="java:jdbc/LiferayPool"/>
      <param name="schema" value="oracle" />
      <param name="schemaObjectPrefix" value="LR_WS_PM_" />
      <param name="externalBLOBs" value="false" />
      </PersistenceManager>
      </Workspace>

      <Versioning rootPath="${rep.home}/version">
      <!-- Uncomment to move to DB -->
      <FileSystem class="org.apache.jackrabbit.core.fs.db.OracleFileSystem">
      <param name="driver" value="javax.naming.InitialContext"/>
      <param name="url" value="java:jdbc/LiferayPool"/>
      <param name="schema" value="oracle"/>
      <param name="schemaObjectPrefix" value="LR_V_FS_"/>
      </FileSystem>

      <PersistenceManager class="org.apache.jackrabbit.core.persistence.bundle.OraclePersistenceManager">
      <param name="driver" value="javax.naming.InitialContext"/>
      <param name="url" value="java:jdbc/LiferayPool"/>
      <param name="schema" value="oracle" />
      <param name="schemaObjectPrefix" value="LR_V_PM_" />
      <param name="externalBLOBs" value="false" />
      </PersistenceManager>
      </Versioning>

      <!-- Cluster Configuration -->
      <!-- Uncomment to move to database -->
      <Cluster id="nodo1" syncDelay="2000">
      <Journal class="org.apache.jackrabbit.core.journal.OracleDatabaseJournal">
      <param name="revision" value="${rep.home}/revision.log" />
      <param name="driver" value="javax.naming.InitialContext"/>
      <param name="url" value="java:jdbc/LiferayPool"/>
      <param name="schema" value="oracle"/>
      <param name="schemaObjectPrefix" value="LR_C_" />
      </Journal>
      </Cluster>
      </Repository>

      If i prove with the JNDI parameters:

      <param name="driver" value="javax.naming.InitialContext"/>
      <param name="url" value="java:comp/env/jdbc/LiferayPool"/>

      mark this error:
      "jdbc not bound"

      In contrast if only it's change in FileSystem by jdbc whether it works correctly

      repository.xml (example):

      <Repository>
      <!-- FILESYSTEM -->
      <FileSystem class="org.apache.jackrabbit.core.fs.db.OracleFileSystem">
      <param name="driver" value="oracle.jdbc.driver.OracleDriver"/>
      <param name="url" value="jdbc:oracle:thin:@xxx.xxx.xxx.xxx:1521:name" />
      <param name="user" value="qua" />
      <param name="password" value="qua" />
      <param name="schema" value="oracle"/>
      <param name="schemaObjectPrefix" value="LR_FS_"/>
      </FileSystem>
      ....
      .....
      "next parameters configured (workspace, versioning, cluster,...) through jndi..."

      ......

      Attachments

        Activity

          People

            Unassigned Unassigned
            rmartinez Ricardo Martínez
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: