Skip site navigation (1) Skip section navigation (2)

Re: Patch to remove connection hook and JDK 1.3 dependencies

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Barry Lind <barry(at)xythos(dot)com>
Cc: pgsql-patches(at)postgresql(dot)org, pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Patch to remove connection hook and JDK 1.3 dependencies
Date: 2001-07-02 16:20:13
Message-ID: 200107021620.f62GKDa09291@candle.pha.pa.us (view raw or flat)
Thread:
Lists: pgsql-jdbcpgsql-patches
Your patch has been added to the PostgreSQL unapplied patches list at:

	http://candle.pha.pa.us/cgi-bin/pgpatches

I will try to apply it within the next 48 hours.

> 
> Attached is a patch to remove the ConnectionHook functionality and thus 
> the JDK 1.3 dependency.  For a further explanation see my posting to the 
> JDBC list on Friday, explaining why this is being done.
> 
> thanks,
> --Barry
> 
> PS.  In addition to the diffs in this patch, the file 
> src/interfaces/jdbc/org/postgresql/core/ConnectionHook.java is obsoleted 
> and needs to be removed from 7.2, but of course the file is still needed 
> for 7.1 builds.

> *** ./interfaces/jdbc/build.xml.orig	Fri Jun 29 19:06:30 2001
> --- ./interfaces/jdbc/build.xml	Fri Jun 29 19:09:20 2001
> ***************
> *** 37,43 ****
>     -->
>     <target name="check_versions">
>       <available property="jdk1.2+" classname="java.lang.ThreadLocal" />
> -     <available property="jdk1.3+" classname="java.lang.StrictMath" />
>       <available property="jdk1.2e+" classname="javax.sql.DataSource" />
>       <available property="junit" classname="junit.framework.Test" />
>     </target>
> --- 37,42 ----
> ***************
> *** 58,68 ****
>       <property name="connectclass" value="org.postgresql.jdbc1.Connection" />
>       <available property="connectclass" value="org.postgresql.jdbc2.Connection" classname="java.lang.ThreadLocal" />
>   
> -     <!-- comment out 1.3+ stuff -->
> -     <property name="jdk13only" value="//" />
> -     <available property="jdk13only" value="" classname="java.lang.StrictMath" />
> -     <filter token="JDK1.3ONLY" value="${jdk13only}" />
> - 
>       <!-- Some defaults -->
>       <filter token="MAJORVERSION" value="${major}" />
>       <filter token="MINORVERSION" value="${minor}" />
> --- 57,62 ----
> ***************
> *** 104,110 ****
>     <target name="compile" depends="prepare,check_versions,driver">
>       <javac srcdir="${src}" destdir="${dest}">
>         <include name="${package}/**" />
> -       <exclude name="${package}/core/ConnectionHook.java" unless="jdk1.3+" />
>         <exclude name="${package}/jdbc1/**" if="jdk1.2+" />
>         <exclude name="${package}/jdbc2/**" unless="jdk1.2+" />
>         <exclude name="${package}/largeobject/PGblob.java" unless="jdk1.2+" />
> --- 98,103 ----
> *** ./interfaces/jdbc/org/postgresql/Driver.java.in.orig	Fri Jun 29 19:13:40 2001
> --- ./interfaces/jdbc/org/postgresql/Driver.java.in	Fri Jun 29 19:16:58 2001
> ***************
> *** 36,44 ****
>         // Placing it here, means that the driver is registered once only.
>         java.sql.DriverManager.registerDriver(new Driver());
>   
> -       // New in 7.1 - register ourselves with the JVM - JDK1.3+ only
> -       @JDK1(dot)3ONLY(at)org(dot)postgresql(dot)core(dot)ConnectionHook(dot)init();
> - 
>       } catch (SQLException e) {
>         e.printStackTrace();
>       }
> --- 36,41 ----

> 
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
>     (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman(at)candle(dot)pha(dot)pa(dot)us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

In response to

pgsql-patches by date

Next:From: Bruce MomjianDate: 2001-07-02 16:20:40
Subject: Re: Patch to set timezone once instead of every call
Previous:From: Marko KreenDate: 2001-07-02 09:04:24
Subject: encode in base code

pgsql-jdbc by date

Next:From: Bruce MomjianDate: 2001-07-02 16:20:40
Subject: Re: Patch to set timezone once instead of every call
Previous:From: Sergey B. ZalozhnikovDate: 2001-07-02 12:01:29
Subject: JDBC download problem

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group