Re: Pre-processing during build - Mailing list pgsql-jdbc

From Dave Cramer
Subject Re: Pre-processing during build
Date
Msg-id CADK3HHK9TUug9amtabv1a+27u_bb31FCsLBarWsPv_PD12JCcw@mail.gmail.com
Whole thread Raw
In response to Re: Pre-processing during build  ("Markus KARG" <markus@headcrashing.eu>)
Responses Re: Pre-processing during build  (Sehrope Sarkuni <sehrope@jackdb.com>)
Re: Pre-processing during build  (Vladimir Sitnikov <sitnikov.vladimir@gmail.com>)
Re: Pre-processing during build  ("Markus KARG" <markus@headcrashing.eu>)
List pgsql-jdbc
How can you use the same name and different bytecode versions ?

Dave Cramer

dave.cramer(at)credativ(dot)ca
http://www.credativ.ca

On 15 June 2015 at 17:59, Markus KARG <markus@headcrashing.eu> wrote:

Stephen,

 

thank you for starting this thread.

 

If it would be up to me, I would try to get rid of pre-processing if any possible, since it is a real p.i.t.a., as long as we can find a different solution to provide the same number of supported JDKs and JDBC versions.

 

The question is: How? Possibly by simply using "JRE8-JDBC42.jar" ALWAYS?

 

Has anybody tried whether it is possible to simply load a JRE8-JDBC42.jar on JRE6? I mean, not to actually invoke the new JDBC42 APIs, just to load the JAR and invoke the JDBC3 APIs only for example. The APIs themselved are backwards compatible, and as long as we don't invoke the new APIs, no ClassNotFound should happen (AFAIK the JRE loads classes only at first actual instantiation, but not simply because it is contained in a loaded .class file as a parameter). I mean, as long as we do not use JRE8-only APIs inside the Driver, and as long as we don't write the .class files in JRE8 byte code, certainly.

 

Or did I miss something in this theoretical approach?

 

Regards

-Markus


pgsql-jdbc by date:

Previous
From: "Markus KARG"
Date:
Subject: Re: Pre-processing during build
Next
From: Sehrope Sarkuni
Date:
Subject: Re: Pre-processing during build