[postgresforest-users 78] Re: Something unusual has occured to cause the driver to fail. Please report this exception.

Back to archive index

nagat****@nttda***** nagat****@nttda*****
2007年 8月 24日 (金) 13:18:26 JST


長妻です。

恐らく、接続先URLに記述している「testdb」というデータベースが
GSC上に登録されていないために起こっていると思われます。

forestadm上で、show db; と打ち込み、「testdb」が
登録されているかどうか確認してみてください。


oiron****@yahoo***** さんは書きました:
> 谷口と申します。
> jdk4.5.0_12
> 
> Fedora Core release 2
> 
> postgresql-8.1.9+postgresforesr8.0.2
> で、セットアップしてjavaからテストしようと思いまして
> 以下のコードを書いて実行したところエラーになりました。
> 
> ublic static void hoge() throws ClassNotFoundException, SQLException{
> 		Class.forName("org.postgresforest.Driver");
> 		Connection con = DriverManager.getConnection(
> 		      
> "jdbc:postgresforest:GSC=//f2.blayn.jp:54321/gsc,//f4.blayn.jp:15432/gsc;CONFIG=FOREST_DEFAULT_CONFIG @ testdb",
> 		       "postgres", "password");
> 	}//end method
> 
> 
> 
> 
> 
> 
> 
> 
> 
> エラーが以下のように出る場合どういった原因がかんがえられますでしょうか。
> 
> 
> 
> 
> 
> Exception in thread "main" org.postgresforest.util.PSQLException: Something
> unusual has occured to cause the driver to fail. Please report this
> exception.
> 	at org.postgresforest.Driver.connect(Driver.java:309)
> 	at java.sql.DriverManager.getConnection(DriverManager.java:582)
> 	at java.sql.DriverManager.getConnection(DriverManager.java:185)
> 	at jp.co.blayn.forest.test.TestForest.hoge(TestForest.java:40)
> 	at jp.co.blayn.forest.test.TestForest.main(TestForest.java:21)
> Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
> 	at java.util.ArrayList.RangeCheck(ArrayList.java:547)
> 	at java.util.ArrayList.get(ArrayList.java:322)
> 	at org.postgresforest.vm.gsc.GscData.getLastServer(GscData.java:459)
> 	at
> org.postgresforest.vm.core.ProtocolConnectionImpl.<init>(ProtocolConnectionImpl.java:51)
> 	at
> org.postgresforest.vm.core.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:55)
> 	at
> org.postgresforest.core.ConnectionFactory.openConnection(ConnectionFactory.java:66)
> 	at
> org.postgresforest.jdbc2.AbstractJdbc2Connection.<init>(AbstractJdbc2Connection.java:116)
> 	at
> org.postgresforest.jdbc3.AbstractJdbc3Connection.<init>(AbstractJdbc3Connection.java:30)
> 	at
> org.postgresforest.vm.jdbc.ForestConnection.<init>(ForestConnection.java:39)
> 	at org.postgresforest.Driver.makeConnection(Driver.java:420)
> 	at org.postgresforest.Driver.connect(Driver.java:291)
> 	... 4 more
> 
> 
> --------------------------------------
> Easy + Joy + Powerful = Yahoo! Bookmarks x Toolbar
> http://pr.mail.yahoo.co.jp/toolbar/
> 
> _______________________________________________
> postgresforest-users mailing list
> postg****@lists*****
> http://lists.sourceforge.jp/mailman/listinfo/postgresforest-users
> 




postgresforest-users メーリングリストの案内
Back to archive index