You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Gary Gregory <ga...@gmail.com> on 2016/04/25 23:53:03 UTC

[io] Make requirement Java 7?

Does anyone object updating [io] to Java 7?

I have a coupe of utils that sit on top of Java 7 IO classes I'd like to
include.

Gary

-- 
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Re: [io] Make requirement Java 7?

Posted by Stian Soiland-Reyes <st...@apache.org>.
+1 - now is the time.

Also I love the java.nio.file APIs. :)



On 25 April 2016 at 22:53, Gary Gregory <ga...@gmail.com> wrote:
> Does anyone object updating [io] to Java 7?
>
> I have a coupe of utils that sit on top of Java 7 IO classes I'd like to
> include.
>
> Gary
>
> --
> E-Mail: garydgregory@gmail.com | ggregory@apache.org
> Java Persistence with Hibernate, Second Edition
> <http://www.manning.com/bauer3/>
> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
> Spring Batch in Action <http://www.manning.com/templier/>
> Blog: http://garygregory.wordpress.com
> Home: http://garygregory.com/
> Tweet! http://twitter.com/GaryGregory



-- 
Stian Soiland-Reyes
Apache Taverna (incubating), Apache Commons RDF (incubating)
http://orcid.org/0000-0001-9842-9718

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Sergio Fernández <wi...@apache.org>.
+1
On Apr 25, 2016 11:53 PM, "Gary Gregory" <ga...@gmail.com> wrote:

> Does anyone object updating [io] to Java 7?
>
> I have a coupe of utils that sit on top of Java 7 IO classes I'd like to
> include.
>
> Gary
>
> --
> E-Mail: garydgregory@gmail.com | ggregory@apache.org
> Java Persistence with Hibernate, Second Edition
> <http://www.manning.com/bauer3/>
> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
> Spring Batch in Action <http://www.manning.com/templier/>
> Blog: http://garygregory.wordpress.com
> Home: http://garygregory.com/
> Tweet! http://twitter.com/GaryGregory
>

Re: [io] Make requirement Java 7?

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 26/04/2016 14:47, Jochen Wiedmann a écrit :

> I second that, Seems appropriate, given the extremely widespread use of io.

I agree, but only if we bump the target level to 1.7. If we keep the
target level at 1.6 we can continue with the 2.x versions.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Jochen Wiedmann <jo...@gmail.com>.
On Tue, Apr 26, 2016 at 12:34 PM, Uwe Barthel <ba...@x-reizend.de> wrote:
> +1 BUT only with a MAJOR version change.

I second that, Seems appropriate, given the extremely widespread use of io.


-- 
The next time you hear: "Don't reinvent the wheel!"

http://www.keystonedevelopment.co.uk/wp-content/uploads/2014/10/evolution-of-the-wheel-300x85.jpg

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Uwe Barthel <ba...@x-reizend.de>.
+1 BUT only with a MAJOR version change.

-- barthel



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Gary Gregory <ga...@gmail.com>.
On Apr 26, 2016 5:57 AM, "Dave Brosius" <db...@mebigfatguy.com> wrote:
>
> People stuck on Java 6, for whatever inane reason, are in a very
restrictive use case, and as such are not likely doing 'progressive' things
like upgrading 3rdparty jars. I just don't see the point of trying to
support some of the new release's code base on java 6, and others on java
7. The extra management that's required is not worth the 2 people who want
a new version of commons-io for java 6. We are talking about an end of life
date coming up on 4 years.

Yes!

>
>
> Just upgrade the whole thing to 7.

Yes!

Gary

>
> -dave
>
>
> On 04/26/2016 08:41 AM, Emmanuel Bourg wrote:
>>
>> Le 26/04/2016 14:29, sebb a écrit :
>>
>>> How can we say that the source code is Java 6 compatible if it cannot
>>> be compiled with Java 6?
>>
>> It's Java 6 compatible at runtime, not at build time. We can say that
>> because:
>> - the project is configured to generate Java 6 compatible bytecode
>> - 99% of the code doesn't use Java 7 APIs
>>
>> The Java 6 compatibility stops if the new utils classes are used.
>>
>>
>>> The ASF releases source.
>>
>> Yes, and we release source that builds with Java 7 and runs with Java 6.
>>
>> Emmanuel Bourg
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
>> For additional commands, e-mail: dev-help@commons.apache.org
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>

Re: [io] Make requirement Java 7?

Posted by Hank Grabowski <ha...@applieddefense.com>.
Piggybacking on what Dave said, Plumbr's latest stats on JDK usage as their
stats collection measure it:

https://plumbr.eu/blog/java/java-version-and-vendor-data-analyzed-2016-edition

Hank

On Tue, Apr 26, 2016 at 8:57 AM, Dave Brosius <db...@mebigfatguy.com>
wrote:

> People stuck on Java 6, for whatever inane reason, are in a very
> restrictive use case, and as such are not likely doing 'progressive' things
> like upgrading 3rdparty jars. I just don't see the point of trying to
> support some of the new release's code base on java 6, and others on java
> 7. The extra management that's required is not worth the 2 people who want
> a new version of commons-io for java 6. We are talking about an end of life
> date coming up on 4 years.
>
>
> Just upgrade the whole thing to 7.
>
> -dave
>
>
> On 04/26/2016 08:41 AM, Emmanuel Bourg wrote:
>
>> Le 26/04/2016 14:29, sebb a écrit :
>>
>> How can we say that the source code is Java 6 compatible if it cannot
>>> be compiled with Java 6?
>>>
>> It's Java 6 compatible at runtime, not at build time. We can say that
>> because:
>> - the project is configured to generate Java 6 compatible bytecode
>> - 99% of the code doesn't use Java 7 APIs
>>
>> The Java 6 compatibility stops if the new utils classes are used.
>>
>>
>> The ASF releases source.
>>>
>> Yes, and we release source that builds with Java 7 and runs with Java 6.
>>
>> Emmanuel Bourg
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
>> For additional commands, e-mail: dev-help@commons.apache.org
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>
>

Re: [io] Make requirement Java 7?

Posted by Gary Gregory <ga...@gmail.com>.
trunk is now Java 7 in the POM.

Gary

On Thu, Apr 28, 2016 at 5:44 AM, Benedikt Ritter <br...@apache.org> wrote:

> Kristian Rosenvold <kr...@gmail.com> schrieb am Do., 28. Apr.
> 2016 um 11:59 Uhr:
>
> > 2016-04-26 15:39 GMT+02:00 Emmanuel Bourg <eb...@apache.org>:
> >
> > > We are not alone :) RedHat is still maintaining OpenJDK 6 and providing
> > > security fixes for things like critical production systems not meant to
> > > be changed every two years.
> > >
> > >
> > Yes, and they are getting paid for it. If they need extended maintenance
> of
> > an old version they can do it themselves. We really do not need to be
> > backing anyones business model on our volunteer time.
> >
>
> Big +1
>
>
> >
> > I say just move the whole thing forward to jdk7 for the 2.6 release. This
> > is entirely undramatical. And I've been a proponent for relasing 2.5 on
> 1.6
> > :)
> >
> >
> > Kristian
> >
>



-- 
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Re: [io] Make requirement Java 7?

Posted by Benedikt Ritter <br...@apache.org>.
Kristian Rosenvold <kr...@gmail.com> schrieb am Do., 28. Apr.
2016 um 11:59 Uhr:

> 2016-04-26 15:39 GMT+02:00 Emmanuel Bourg <eb...@apache.org>:
>
> > We are not alone :) RedHat is still maintaining OpenJDK 6 and providing
> > security fixes for things like critical production systems not meant to
> > be changed every two years.
> >
> >
> Yes, and they are getting paid for it. If they need extended maintenance of
> an old version they can do it themselves. We really do not need to be
> backing anyones business model on our volunteer time.
>

Big +1


>
> I say just move the whole thing forward to jdk7 for the 2.6 release. This
> is entirely undramatical. And I've been a proponent for relasing 2.5 on 1.6
> :)
>
>
> Kristian
>

Re: [io] Make requirement Java 7?

Posted by Kristian Rosenvold <kr...@gmail.com>.
2016-04-26 15:39 GMT+02:00 Emmanuel Bourg <eb...@apache.org>:

> We are not alone :) RedHat is still maintaining OpenJDK 6 and providing
> security fixes for things like critical production systems not meant to
> be changed every two years.
>
>
Yes, and they are getting paid for it. If they need extended maintenance of
an old version they can do it themselves. We really do not need to be
backing anyones business model on our volunteer time.

I say just move the whole thing forward to jdk7 for the 2.6 release. This
is entirely undramatical. And I've been a proponent for relasing 2.5 on 1.6
:)


Kristian

Re: [io] Make requirement Java 7?

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 26/04/2016 15:35, Dave Brosius a écrit :
> The other side would say we are enabling crap code on unsupported,
> unprotected jvms. New Java 6 development will die (more quickly) when
> big libraries like commons-io stop supporting it. As it is, we are the
> Java 6 drug dealers.

We are not alone :) RedHat is still maintaining OpenJDK 6 and providing
security fixes for things like critical production systems not meant to
be changed every two years.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Dave Brosius <db...@mebigfatguy.com>.
The other side would say we are enabling crap code on unsupported, 
unprotected jvms. New Java 6 development will die (more quickly) when 
big libraries like commons-io stop supporting it. As it is, we are the 
Java 6 drug dealers.

On 04/26/2016 09:28 AM, Emmanuel Bourg wrote:
> Le 26/04/2016 14:57, Dave Brosius a écrit :
>
>> The extra management that's required is not worth the
>> 2 people who want a new version of commons-io for java 6. We are talking
>> about an end of life date coming up on 4 years.
> There is no extra management besides configuring the Maven compiler
> plugin to generate Java 6 bytecode and refraining from using Java 7 APIs
> unless absolutely required (and preferably in dedicated classes).
>
> commons-io is our most used component, we have to be conservative as it
> impacts many projects.
>
> Emmanuel Bourg
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 26/04/2016 15:30, Jochen Wiedmann a écrit :

> Besides, what is the problem with creating a 2.x branch new and
> changing trunk to version 3? If there is further development in the
> 2.x (aka Java 6) branch: Very well. If not, what is the problem?

There is no problem, just more maintenance work. Changes have to be
backported, and more releases have to be prepared.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Jochen Wiedmann <jo...@gmail.com>.
On Tue, Apr 26, 2016 at 3:28 PM, Emmanuel Bourg <eb...@apache.org> wrote:
> Le 26/04/2016 14:57, Dave Brosius a écrit :
>
>> The extra management that's required is not worth the
>> 2 people who want a new version of commons-io for java 6. We are talking
>> about an end of life date coming up on 4 years.
>
> There is no extra management besides configuring the Maven compiler
> plugin to generate Java 6 bytecode and refraining from using Java 7 APIs
> unless absolutely required (and preferably in dedicated classes).
>
> commons-io is our most used component, we have to be conservative as it
> impacts many projects.

Besides, what is the problem with creating a 2.x branch new and
changing trunk to version 3? If there is further development in the
2.x (aka Java 6) branch: Very well. If not, what is the problem?

Jochen



-- 
The next time you hear: "Don't reinvent the wheel!"

http://www.keystonedevelopment.co.uk/wp-content/uploads/2014/10/evolution-of-the-wheel-300x85.jpg

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 26/04/2016 14:57, Dave Brosius a écrit :

> The extra management that's required is not worth the
> 2 people who want a new version of commons-io for java 6. We are talking
> about an end of life date coming up on 4 years.

There is no extra management besides configuring the Maven compiler
plugin to generate Java 6 bytecode and refraining from using Java 7 APIs
unless absolutely required (and preferably in dedicated classes).

commons-io is our most used component, we have to be conservative as it
impacts many projects.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Dave Brosius <db...@mebigfatguy.com>.
People stuck on Java 6, for whatever inane reason, are in a very 
restrictive use case, and as such are not likely doing 'progressive' 
things like upgrading 3rdparty jars. I just don't see the point of 
trying to support some of the new release's code base on java 6, and 
others on java 7. The extra management that's required is not worth the 
2 people who want a new version of commons-io for java 6. We are talking 
about an end of life date coming up on 4 years.


Just upgrade the whole thing to 7.

-dave

On 04/26/2016 08:41 AM, Emmanuel Bourg wrote:
> Le 26/04/2016 14:29, sebb a écrit :
>
>> How can we say that the source code is Java 6 compatible if it cannot
>> be compiled with Java 6?
> It's Java 6 compatible at runtime, not at build time. We can say that
> because:
> - the project is configured to generate Java 6 compatible bytecode
> - 99% of the code doesn't use Java 7 APIs
>
> The Java 6 compatibility stops if the new utils classes are used.
>
>
>> The ASF releases source.
> Yes, and we release source that builds with Java 7 and runs with Java 6.
>
> Emmanuel Bourg
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 26/04/2016 14:29, sebb a écrit :

> How can we say that the source code is Java 6 compatible if it cannot
> be compiled with Java 6?

It's Java 6 compatible at runtime, not at build time. We can say that
because:
- the project is configured to generate Java 6 compatible bytecode
- 99% of the code doesn't use Java 7 APIs

The Java 6 compatibility stops if the new utils classes are used.


> The ASF releases source.

Yes, and we release source that builds with Java 7 and runs with Java 6.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by sebb <se...@gmail.com>.
On 26 April 2016 at 13:01, Emmanuel Bourg <eb...@apache.org> wrote:
> Le 26/04/2016 13:47, sebb a écrit :
>
>> Since the ASF primarily releases source, I think we would need to
>> ensure that the code could still be compiled using Java 6.
>
> I don't think that's necessary. We just have to document that Java 7 is
> required to build the project. And we can use the enforcer plugin to
> ensure Java 7 is used, even if the compiler plugin targets Java 6.

How can we say that the source code is Java 6 compatible if it cannot
be compiled with Java 6?

The ASF releases source.

> Emmanuel Bourg
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 26/04/2016 13:47, sebb a écrit :

> Since the ASF primarily releases source, I think we would need to
> ensure that the code could still be compiled using Java 6.

I don't think that's necessary. We just have to document that Java 7 is
required to build the project. And we can use the enforcer plugin to
ensure Java 7 is used, even if the compiler plugin targets Java 6.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by sebb <se...@gmail.com>.
On 26 April 2016 at 12:31, Emmanuel Bourg <eb...@apache.org> wrote:
> Le 26/04/2016 13:18, sebb a écrit :
>
>> But how does one compile the new utils which require Java 7?
>>
>> Would these be released as separately compiled jar?
>
> You don't need a separate jar. You just have to build with Java 7 but
> set the source/target of the compiler plugin to 1.6. This will produce a
> jar usable with Java 6, except for the new utils classes using the Java
> 7 APIs.

Doh, of course.

However that might need a fix to the pom.
IIRC there is a check that the code only uses APIs from the target
Java version, precisely to guard against accidental use of
non-existent APIs.

Since the ASF primarily releases source, I think we would need to
ensure that the code could still be compiled using Java 6.
That would mean excluding the new classes if the compiler is Java 6.
And not using Java 7 syntax in the original code.

Otherwise we would be producing source code that is (mainly) Java
6-compatible but which cannot be compiled using Java 6.

> Emmanuel Bourg
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 26/04/2016 13:18, sebb a écrit :

> But how does one compile the new utils which require Java 7?
> 
> Would these be released as separately compiled jar?

You don't need a separate jar. You just have to build with Java 7 but
set the source/target of the compiler plugin to 1.6. This will produce a
jar usable with Java 6, except for the new utils classes using the Java
7 APIs.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by sebb <se...@gmail.com>.
On 26 April 2016 at 11:23, Emmanuel Bourg <eb...@apache.org> wrote:
> Le 26/04/2016 12:08, sebb a écrit :
>
>> That would be good, but is it possible to build the code so it
>> (mostly) still runs under Java 6?
>
> Yes if we stick to Java 6 APIs and compile with source/target level 1.6.
> We don't have to switch to source/target 1.7 to use the java.nio.file API.

But how does one compile the new utils which require Java 7?

Would these be released as separately compiled jar?

> Emmanuel Bourg
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 26/04/2016 12:08, sebb a écrit :

> That would be good, but is it possible to build the code so it
> (mostly) still runs under Java 6?

Yes if we stick to Java 6 APIs and compile with source/target level 1.6.
We don't have to switch to source/target 1.7 to use the java.nio.file API.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by sebb <se...@gmail.com>.
On 26 April 2016 at 09:18, Emmanuel Bourg <eb...@apache.org> wrote:
> Le 25/04/2016 23:53, Gary Gregory a écrit :
>> Does anyone object updating [io] to Java 7?
>>
>> I have a coupe of utils that sit on top of Java 7 IO classes I'd like to
>> include.
>
> +1
>
> I'd suggest using the Java 7 API for the new utils, but preserving the
> Java 6 compatibility for the existing code.

That would be good, but is it possible to build the code so it
(mostly) still runs under Java 6?

> Emmanuel Bourg
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [io] Make requirement Java 7?

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 25/04/2016 23:53, Gary Gregory a écrit :
> Does anyone object updating [io] to Java 7?
> 
> I have a coupe of utils that sit on top of Java 7 IO classes I'd like to
> include.

+1

I'd suggest using the Java 7 API for the new utils, but preserving the
Java 6 compatibility for the existing code.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org