DriverManager.setLoginTimeout question

Поиск
Список
Период
Сортировка
От kangch
Тема DriverManager.setLoginTimeout question
Дата
Msg-id 006c01c2ff26$b00cbc60$6101a8c0@jn07
обсуждение исходный текст
Список pgsql-jdbc
Hi,
 
According to JDBC API, DriverManager.setLoginTimeout methos is
Sets the maximum time in seconds that a driver will wait while attempting to connect to a database
 
I am testing this method "setLoginTimeout(3) -> 3 seconds"
 
Class.forName("org.postgresql.Driver");
DriverManager.setLoginTimeout(3);
conn = DriverManager.getConnection(
                                        "jdbc:postgresql://test:5432/test1",
                                        "test2",
                                        "test3");
but, it's not working...
It takes about 2 minutes or 3 minutes, if the postgreSQL is not exist
I want to know that setLoginTimeout is work or not work in postgreSQL.
 
If you know another method, please answer to me the solution...
I want to receive more quickly to the postgreSQL, if postgreSQL is not exist.
 
Cheers
 
Kang
 

В списке pgsql-jdbc по дате отправления:

Предыдущее
От: .
Дата:
Сообщение: "text" type is java.sql.Types.varchar not longvarchar
Следующее
От: "Jason Dinger"
Дата:
Сообщение: tomcat/postgres problem