错误如下:
两个配置文件如下:
c-jdbc-2.0.2-bin\config\virtualdatabase\mysql-raidb1-distribution.xml
<?xml version="1.0" encoding="UTF8"?> <!DOCTYPE C-JDBC PUBLIC "-//ObjectWeb//DTD C-JDBC 2.0.2//EN" "http://c-jdbc.objectweb.org/dtds/c-jdbc-2.0.2.dtd">
<C-JDBC> <VirtualDatabase name="myDB">
<Distribution> </Distribution> <AuthenticationManager> <Admin> <User username="admin" password="c-jdbc"/> </Admin> <VirtualUsers> <VirtualLogin vLogin="boss" vPassword="boss"/> </VirtualUsers>
</AuthenticationManager> <DatabaseBackend name="mysqlNode211" driver="org.gjt.mm.mysql.Driver" url="jdbc:mysql://192.168.3.25/clusterdb" connectionTestStatement="select 1"> <ConnectionManager vLogin="boss" rLogin="root" rPassword="123456"> <VariablePoolConnectionManager initPoolSize="10" minPoolSize="10" maxPoolSize="50" idleTimeout="30" waitTimeout="10"/> </ConnectionManager>
</DatabaseBackend> <DatabaseBackend name="mysqlNode213" driver="org.gjt.mm.mysql.Driver" url="jdbc:mysql://192.168.3.88/clusterdb" connectionTestStatement="select 1"> <ConnectionManager vLogin="boss" rLogin="root" rPassword="">
<VariablePoolConnectionManager initPoolSize="10" minPoolSize="10" maxPoolSize="50" idleTimeout="30" waitTimeout="10"/> </ConnectionManager> </DatabaseBackend> <RequestManager> <RequestScheduler> <RAIDb-1Scheduler level="passThrough"/> </RequestScheduler> <LoadBalancer> <RAIDb-1> <WaitForCompletion policy="first"/> <RAIDb-1-LeastPendingRequestsFirst/> </RAIDb-1> </LoadBalancer> </RequestManager> </VirtualDatabase> </C-JDBC>
c-jdbc-2.0.2-bin\config\controller\uud-controller-distributed.xml <?xml version="1.0" encoding="UTF8" ?> <!DOCTYPE C-JDBC-CONTROLLER PUBLIC "-//ObjectWeb//DTD C-JDBC-CONTROLLER 2.0.2//EN" "http://c-jdbc.objectweb.org/dtds/c-jdbc-controller-2.0.2.dtd"> <C-JDBC-CONTROLLER> <Controller port="25323"> <JmxSettings> <RmiJmxAdaptor port="1091"/> </JmxSettings> <VirtualDatabase configFile="mysql-raidb1-distribution.xml" virtualDatabaseName="myDB" autoEnableBackends="true"/> </Controller> </C-JDBC-CONTROLLER>
我也遇到同样的问题,C-JDBC这个中间件,在测试环境中经常报错!