Leveraging Lambda for JDBC 4.2

Ulf Zibis Ulf.Zibis at CoSoCo.de
Thu Dec 6 12:47:20 PST 2012

Am 06.12.2012 19:50, schrieb Lance Andersen - Oracle:
> On Dec 6, 2012, at 1:37 PM, Mark Rotteveel wrote:
>> However for required methods I think it is a really bad idea. One of the nice things about interfaces is that having a required method not implemented will be immediately and forcefully signaled to the driver developer by a compile time error (both in the IDE and at building the driver). Introducing a default method that throws UnsupportedOperationException will remove those handy signals.
> The problem that  you have is for APIs such as JDBC to improve the API, you need to add methods where they naturally reside.  This causes problems for people that their code will no longer compile on the new version of Java

1. Is it really necessary, that people compile there code against a new version, shouldn't it 
suffice to compile against the older appropriate version?
(When new gasoline is invented, one can't expect old machines to accept that.)
2. Doesn't -target 1.7 help?
3. They could preload the old version of the interface via -bootclasspath.

So I really tend to agree with Mark.

And last, I still have doubts to welcome that new "default concept" at all, see:


More information about the jdbc-spec-discuss mailing list