Re: JDBC driver debug out?

From: Tatsuo Ishii <ishii(at)postgresql(dot)org>
To: pg(at)fastcrypt(dot)com
Cc: ishii(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org, pgsql-jdbc(at)postgresql(dot)org
Subject: Re: JDBC driver debug out?
Date: 2015-10-24 12:45:21
Message-ID: 20151024.214521.955343919000811055.t-ishii@sraoss.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-jdbc

Thanks. It works.

Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp

> Add
>
> DriverManager.setLogWriter(new PrintWriter(System.out));
>
> below the setLogLevel and it will
>
> I'll fix this though
>
> Dave Cramer
>
> davec(at)postgresintl(dot)com
> www.postgresintl.com
>
> On 23 October 2015 at 22:35, Tatsuo Ishii <ishii(at)postgresql(dot)org> wrote:
>
>> Unfortunately it doesn't work (no debug trace).
>>
>> Best regards,
>> --
>> Tatsuo Ishii
>> SRA OSS, Inc. Japan
>> English: http://www.sraoss.co.jp/index_en.php
>> Japanese:http://www.sraoss.co.jp
>>
>> > This should work better
>> >
>> >
>> https://oss.sonatype.org/content/repositories/snapshots/org/postgresql/postgresql/9.4-1204-jdbc41-SNAPSHOT/
>> >
>> > Dave Cramer
>> >
>> > davec(at)postgresintl(dot)com
>> > www.postgresintl.com
>> >
>> > On 23 October 2015 at 21:32, Dave Cramer <pg(at)fastcrypt(dot)com> wrote:
>> >
>> >> No, I need to provide you with a 41 version.
>> >>
>> >> I just happened to have java 1.8 on my machine.
>> >>
>> >> Dave Cramer
>> >>
>> >> davec(at)postgresintl(dot)com
>> >> www.postgresintl.com
>> >>
>> >> On 23 October 2015 at 21:31, Tatsuo Ishii <ishii(at)postgresql(dot)org> wrote:
>> >>
>> >>> Dave,
>> >>>
>> >>> Thanks for the quick response. Unfortunately now I'm getting error
>> >>> with the JDBC driver.
>> >>>
>> >>> warning:
>> >>>
>> /usr/local/pgsql/share/postgresql-9.4-1204-jdbc42-20151023.230759-1.jar(org/postgresql/Driver.class):
>> >>> major version 52 is newer than 51, the highest major version supported
>> by
>> >>> this compiler.
>> >>> It is recommended that the compiler be upgraded.
>> >>> 1 warning
>> >>> [snip]
>> >>> Exception in thread "main" java.lang.UnsupportedClassVersionError:
>> >>> org/postgresql/Driver : Unsupported major.minor version 52.0
>> >>> at java.lang.ClassLoader.defineClass1(Native Method)
>> >>> at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
>> >>> at
>> >>> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
>> >>> at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
>> >>> at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
>> >>> at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
>> >>> at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
>> >>> at java.security.AccessController.doPrivileged(Native Method)
>> >>> at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
>> >>> at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
>> >>> at
>> sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
>> >>> at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
>> >>> at java.lang.Class.forName0(Native Method)
>> >>> at java.lang.Class.forName(Class.java:191)
>> >>> at begin_select_sleep.dbAccess(begin_select_sleep.java:39)
>> >>> at begin_select_sleep.main(begin_select_sleep.java:21)
>> >>>
>> >>> $ java -version
>> >>> java version "1.7.0_79"
>> >>> OpenJDK Runtime Environment (IcedTea 2.5.6)
>> (7u79-2.5.6-0ubuntu1.14.04.1)
>> >>> OpenJDK 64-Bit Server VM (build 24.79-b02, mixed mode)
>> >>>
>> >>> Probably I should upgrade Java...
>> >>>
>> >>> Best regards,
>> >>> --
>> >>> Tatsuo Ishii
>> >>> SRA OSS, Inc. Japan
>> >>> English: http://www.sraoss.co.jp/index_en.php
>> >>> Japanese:http://www.sraoss.co.jp
>> >>>
>> >>> > Tatsuo,
>> >>> >
>> >>> > Can you confirm it is fixed in this snapshot
>> >>> >
>> >>>
>> https://oss.sonatype.org/content/repositories/snapshots/org/postgresql/postgresql/9.4-1204-jdbc42-SNAPSHOT/
>> >>> >
>> >>> > Dave Cramer
>> >>> >
>> >>> > davec(at)postgresintl(dot)com
>> >>> > www.postgresintl.com
>> >>> >
>> >>> > On 23 October 2015 at 19:00, Dave Cramer <pg(at)fastcrypt(dot)com> wrote:
>> >>> >
>> >>> >> Tatsuo,
>> >>> >>
>> >>> >> posting to jdbc list
>> >>> >>
>> >>> >> Dave Cramer
>> >>> >>
>> >>> >> davec(at)postgresintl(dot)com
>> >>> >> www.postgresintl.com
>> >>> >>
>> >>> >> On 23 October 2015 at 18:28, Tatsuo Ishii <ishii(at)postgresql(dot)org>
>> >>> wrote:
>> >>> >>
>> >>> >>> It seems
>> >>> >>> org.postgresql.Driver.setLogLevel(org.postgresql.Driver.DEBUG) does
>> >>> >>> not work anymore in the newer JDBC driver.
>> >>> >>>
>> >>> >>> As far as I know, postgresql-9.2-1003.jdbc4.jar or
>> >>> >>> postgresql-9.3-1104.jdbc41.jar work fine and produce following
>> output
>> >>> >>> for example:
>> >>> >>>
>> >>> >>> 16:36:36.459 (1) PostgreSQL 9.3 JDBC4.1 (build 1104)
>> >>> >>> 16:36:36.464 (1) Trying to establish a protocol version 3
>> connection
>> >>> to
>> >>> >>> localhost:11000
>> >>> >>> 16:36:36.481 (1) Receive Buffer Size is 530904
>> >>> >>> 16:36:36.481 (1) Send Buffer Size is 1313280
>> >>> >>> 16:36:36.481 (1) FE=> StartupPacket(user=t-ishii, database=test,
>> >>> >>> client_encoding=UTF8, DateStyle=ISO, TimeZone=Asia/Tokyo,
>> >>> >>> extra_float_digits=2)
>> >>> >>> 16:36:36.487 (1)<=BE AuthenticationOk
>> >>> >>>
>> >>> >>> However postgresql-9.4-1204.jdbc41.jar shows nothing.
>> >>> >>>
>> >>> >>> Best regards,
>> >>> >>> --
>> >>> >>> Tatsuo Ishii
>> >>> >>> SRA OSS, Inc. Japan
>> >>> >>> English: http://www.sraoss.co.jp/index_en.php
>> >>> >>> Japanese:http://www.sraoss.co.jp
>> >>> >>>
>> >>> >>>
>> >>> >>> --
>> >>> >>> Sent via pgsql-hackers mailing list (pgsql-hackers(at)postgresql(dot)org)
>> >>> >>> To make changes to your subscription:
>> >>> >>> http://www.postgresql.org/mailpref/pgsql-hackers
>> >>> >>>
>> >>> >>
>> >>> >>
>> >>>
>> >>
>> >>
>>

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Noah Misch 2015-10-24 16:31:32 Re: Parallel Seq Scan
Previous Message Simon Riggs 2015-10-24 12:14:17 Re: Proposal: Trigonometric functions in degrees

Browse pgsql-jdbc by date

  From Date Subject
Next Message Victor Wagner 2015-10-26 07:58:56 Patch (3): Implement failover on libpq connect level.
Previous Message Robert Haas 2015-10-24 11:55:59 Re: Patch (2): Implement failover on libpq connect level.