[rules-users] Deploying Guvnor on a existing repository DB

maav mattias.avelin at netlight.se
Fri Apr 29 08:15:29 EDT 2011


Hi! 

I'm trying to get Guvnor to deploy on a pre-existing existing DB. The use
case beeing that we wan't to be able to bring up a backup instance of guvnor
in case the primary goes down. 

But if a deploy guvnor on a "fresh" DB schema all tables get created along
with trigger and sequences (using Oracle 11). 

But when I un-deploy guvnor.war and remove the repository-folder and then
deploy it again I get the following exception:

Caused by: java.sql.SQLException: ORA-00001: unique constraint
(ID_VERIFICATION.G_DEFAULT_BUNDLE_IDX) violated

	at
oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:331)
	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:288)
	at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:745)
	at
oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:219)
	at
oracle.jdbc.driver.T4CPreparedStatement.executeForRows(T4CPreparedStatement.java:970)
	at
oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1190)
	at
oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3370)
	at
oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStatement.java:3476)
	at
org.apache.jackrabbit.core.persistence.bundle.ConnectionRecoveryManager.executeStmtInternal(ConnectionRecoveryManager.java:371)
	at
org.apache.jackrabbit.core.persistence.bundle.ConnectionRecoveryManager.executeStmtInternal(ConnectionRecoveryManager.java:298)
	at
org.apache.jackrabbit.core.persistence.bundle.ConnectionRecoveryManager.executeStmt(ConnectionRecoveryManager.java:261)
	at
org.apache.jackrabbit.core.persistence.bundle.ConnectionRecoveryManager.executeStmt(ConnectionRecoveryManager.java:239)
	at
org.apache.jackrabbit.core.persistence.bundle.BundleDbPersistenceManager.storeBundle(BundleDbPersistenceManager.java:1207)
	... 59 more

What do I need to do to prevent this?

This is my repository.xml:

<?xml version="1.0"?>


&lt;!DOCTYPE Repository
          PUBLIC &quot;-//The Apache Software Foundation//DTD Jackrabbit
2.0//EN&quot;
         
&quot;http://jackrabbit.apache.org/dtd/repository-2.0.dtd&quot;&gt;


<Repository>
    
    <FileSystem class="org.apache.jackrabbit.core.fs.local.LocalFileSystem">
        
		 
    </FileSystem>

    
    <DataStore class="org.apache.jackrabbit.core.data.FileDataStore">
		 
	</DataStore>
	

    
    <Security appName="Jackrabbit">
        
        <SecurityManager
class="org.apache.jackrabbit.core.security.simple.SimpleSecurityManager"
workspaceName="security">
            
            
            
        </SecurityManager>

        
        <AccessManager
class="org.apache.jackrabbit.core.security.simple.SimpleAccessManager">
            
        </AccessManager>

        <LoginModule
class="org.apache.jackrabbit.core.security.simple.SimpleLoginModule">
           
           
           
           
        </LoginModule>
    </Security>

    
    <Workspaces rootPath="${rep.home}/workspaces"
defaultWorkspace="default"/>
    
    <Workspace name="${wsp.name}">
		<FileSystem class="org.apache.jackrabbit.core.fs.db.OracleFileSystem">
		  
		  
		  
		  
		  
		   
		</FileSystem>

		<PersistenceManager
class="org.apache.jackrabbit.core.persistence.bundle.OraclePersistenceManager">
		  
		  
		  
		  
		   
		</PersistenceManager>
		
        
        <SearchIndex
class="org.apache.jackrabbit.core.query.lucene.SearchIndex">
            
            
        </SearchIndex>
    </Workspace>

    
    <Versioning rootPath="${rep.home}/version">
        <FileSystem
class="org.apache.jackrabbit.core.fs.db.OracleFileSystem">
		  
		  
		  
		  
		  
		   
		</FileSystem>

		<PersistenceManager
class="org.apache.jackrabbit.core.persistence.bundle.OraclePersistenceManager">
		  
		  
		  
		  
		   
		</PersistenceManager>
	</Versioning>
    
    <SearchIndex
class="org.apache.jackrabbit.core.query.lucene.SearchIndex">
        
        
    </SearchIndex>
</Repository>

--
View this message in context: http://drools.46999.n3.nabble.com/Deploying-Guvnor-on-a-existing-repository-DB-tp2878946p2878946.html
Sent from the Drools: User forum mailing list archive at Nabble.com.



More information about the rules-users mailing list