ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matt Benson <gudnabr...@gmail.com>
Subject Re: NIO 2.0 == Ant 2.0? was Re: Java NIO support
Date Tue, 14 Feb 2012 17:29:02 GMT
On Tue, Feb 14, 2012 at 8:13 AM, Stefan Bodewig <bodewig@apache.org> wrote:
> On 2012-02-13, Bruce Atherton wrote:
>
>> I spent some time starting to implement a very simple (only a few
>> tasks) new version of Ant that started from Java 7. Personal issues
>> have taken me out of the game for a while, but I've still been
>> wondering, could Java 7 and NIO 2.0 be a good reason to create Ant
>> 2.0?
>
> There are things in NIO2 that can be added via FileUtils one way or the
> other, but it could also make us rethink our concept of Resources
> (although nio2's Path looks too limited for that).
>
> If we really want to take the burden of redesigning Ant on us then it
> certainly wouldn't only be NIO2 but also revolutionary things like
> generics.  OTOH there will always be a reason to wait longer (lambdas,
> modules).
>
> I fully understand that throwing away the existing cruft can set free
> new energy.  Personally I enjoy working on the Commons Antlib way more
> than working on the built-in Zip/Tar tasks because I could design them
> from a fresh start while the later have accumulated features with big
> care for API backwards compatibility.
>
> To me the strength of Ant (as it is) is in its tasks.  The tasks are
> proven pieces of code that have been tested by an incredibly big amount
> of people.  And even if we have about 200 bug reports open, most tasks
> do what they are supposed to do and do so very well.  Any rewritten Ant
> would have a long way to reach the same level of stability.  The same is
> true for the Compress Antlib vs the core tasks, of course.
>
>> It could be a way to sweep away the kind of cruft that is holding up
>> the release and to redesign Ant to reflect all the lessons learned
>> about how to build software in the last 10 years.
>
> This will lead us to the discussion of what Ant2 would be.  A rewritten
> Ant that remains compatible (or mostly so) on the build file level or
> something quite different?
>

It would be very beneficial to have Ant 2 remain compatible at the
build file level if for no other reason than to facilitate testing of
v2 tasks:  AntUnit-based tests should continue to pass, and as we've
seen, the vast majority of Ant's unit tests are expressible in the
AntUnit style.

Agreed that a v2 could allow us to cast off accumulated baggage.  The
core of the redesign would be the most important thing to get right.
I suspect that the concept of a Resource would be closer to the core
(hindsight and all that) and would be interface-based.  TBH, I've
never looked closely at nio1, let alone 2, until just now, but after a
quick look at java.nio.file.Path I confess that I don't immediately
see what it lacks that we would need.

Matt

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

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


Mime
View raw message