Please Enable JavaScript!
Gon[ Enable JavaScript ]

Multi Pool 구성 예 - config.xml

자바(JAVA)
반응형

<JDBCConnectionPool

    ConnectionCreationRetryFrequencySeconds="0"      

    CapacityIncrement="1"  

    CountOfRefreshFailuresTillDisable= "1"    

    CountOfTestFailuresTillFlush="1"    

    DriverName="oracle.jdbc.xa.client.OracleXADataSource"   

    InitialCapacity="5"    

    KeepXAConnTillTxComplete="true"     

    MaxCapacity="100"      

    Name="cgPool1"  

    PasswordEncrypted="{3DES}lBifoTsg8fc="    

    Properties="user=user_name"  

    RefreshMinutes="1"     

    SupportsLocalTransaction="true"     

    Targets="cgServer"     

    TestConnectionsOnReserve="true"     

    TestTableName="dual"   

    URL="jdbc:oracle:thin:@dbhost1:1521:dbname1"     

    XARetryDurationSeconds="300"

    XASetTransactionTimeout="true"      

    XATransactionTimeout="302"/>

 

<JDBCConnectionPool        

    ConnectionCreationRetryFrequencySeconds="0"

    CapacityIncrement="1"  

    CountOfRefreshFailuresTillDisable= "1"    

    CountOfTestFailuresTillFlush="1"    

    DriverName="oracle.jdbc.xa.client.OracleXADataSource"   

    InitialCapacity="5"    

    KeepXAConnTillTxComplete="true"     

    MaxCapacity="100"      

    Name="cgPool2"  

    PasswordEncrypted="{3DES}lBifoTsg8fc="    

    Properties="user=user_name"  

    RefreshMinutes="1"     

    SupportsLocalTransaction="true"     

    Targets="cgServer"     

    TestConnectionsOnReserve="true"     

    TestTableName="dual"   

    URL="jdbc:oracle:thin:@dbhost2:1521:dbname2"     

    XARetryDurationSeconds="300"

    XASetTransactionTimeout="true"      

    XATransactionTimeout="302"/>

   

<JDBCMultiPool     

    Name="cgMultiPool"     

    PoolList="cgPool1,cgPool2"

    FailoverRequestIfBusy="true" 

    HealthCheckFrequencySeconds="300"   

    Targets="cgServer"     

    AlgorithmType="High-Availability"/>

   

<JDBCTxDataSource  

    JNDIName="cgDataSource"      

    Name="cgDataSource"    

    EnableTwoPhaseCommit="true"  

    PoolName="cgMultiPool"

    Targets="cgServer"/>

반응형
Posted by 녹두장군1
,