Agile Java Rewrite?

by Jeff Langr

April 25, 2017

I’ve had the idea to write a book on refactoring for some time, and even produced a proposal a couple months ago. The focus would be “refactoring in the context of TDD,” aka continual design. I only got halfway through a sample chapter, which the publisher requests. (Writing the sample also reassures me it’s the book I want to and can write.) This past week I heard that a Big Name is currently working on a refactoring book rewrite. Hmm, maybe this project is not something that I should be doing.

Agile Java has been in print since 2005. It still sells copies–not a lot–and I also still receive thanks for the book from many folks who found it a great way to learn (TDD + OO + Java from the ground up). I feel a bit guilty that people still use a 12+year-old-book featuring a version of Java end-of-lifed for about 8 years! Time for a rewrite, as some have requested?

A dozen years later, what would change?

  • New approach based on new versions of Java: The book was written to coincide with Java 5 and its dramatic language changes, which also made it easier for a simpler, more-OO focus than previously would have been possible. With Java 9 on the horizon (July 2017, maybe?), a new version would find lambdas being introduced fairly early to allow new developers to focus on the value of more-functional approaches to solving problems.

  • Potential new “Additional Lesson” chapters focusing on full-stack considerations (HTTP and JPA, for example)… or maybe this whole notion of covering peripheral technologies gets dropped. Yeah, let’s do that, and keep this to a somewhat-reasonable length.

  • Updated for the latest version of JUnit (5).

  • Use of fluent assertions (probably Hamcrest with mention of other frameworks).

  • Emphasis on one behavior per test, as well as the value of tests-as-documentation.

Otherwise, the tone and general flow would remain the same. Hopefully not the page length: Few folks want to read 750-page books anymore.

I’m the sort to find the stuff I wrote a while back to be lacking, so I might be tempted to rewrite a few things…

Comments

Dale Keener April 26, 2017 at 1:53 pm

Interesting idea. I really enjoyed the original Agile Java. I liked the idea of learning TDD along with new language. TDD provides a good framework for trying out new stuff.

My only concern about new edition would be overlap with Pragmatic Unit Testing in Java 8 with JUnit. One of my favorite authors, Herb Schildt, used to have so much overlap in his C/C++ books every time I bought his latest book I would swear never again, but I’d always find some little gem in the next one that I had to have.


Jeff Langr April 26, 2017 at 3:27 pm

Thanks for the feedback, Dale!

I’ve heard that many folks have one idea and they write the same article/book around it many times.

I always thought Schildt was a very good tech writer! I only had 3 of his books, so I don’t think I saw as much overlap.

While the Prag Unit Testing book assumes you know Java, Agile Java was geared toward new Java programmers–to teach them the language via TDD. It’d still be the case, so folks like you might get a few nuggets, but new programmers would benefit most.


May 26, 2017 at 4:07 pm

My only concern about new edition would be overlap with Pragmatic Unit Testing in Java 8 with JUnit


software development May 26, 2017 at 4:11 pm

Motivating idea. I truly loved the innovative Agile Java. I liked the knowledge of learning TDD along with different language. TDD offers a good background for trying out fresh stuff.


Jeff Langr May 26, 2017 at 4:29 pm

There would indeed be overlap with Pragmatic Unit Testing in Java. The audiences are different, though–Agile Java teaches primarily Java to new programmers by using TDD; Pragmatic Unit Testing teaches unit testing for people who are already Java programmers.


Share your comment

Jeff Langr

About the Author

Jeff Langr has been building software for 40 years and writing about it heavily for 20. You can find out more about Jeff, learn from the many helpful articles and books he's written, or read one of his 1000+ combined blog (including Agile in a Flash) and public posts.