On Writing Transitioning to Java, My First Book

My first book.

I decided to write a book. What academic has not thought about doing this. I spent 31 years teaching programming starting with Pascal and then through my career C, C++, Perl, PHP, and finally Java. There have been other languages I used before I became an instructor. The most lucrative contract I ever had involved writing in PL/1 on an IBM-PC running DOS 3.3. I don’t think there is a market for PL/1 books, and it was over 40 years ago that I used it. The logical choice for a book was Java.

Having taught students in the first year of their studies and then specializing in the final year project courses I decided to write a beginner’s book. I have strong opinions on learning to program and on the Java language. I even wrote a sample chapter that you will find two stories back in this blog. Time to speak to publishers.

I had met a representative from O’Reilly and had email contacts at Apress and Packt. The response from O’Reilly and echoed by Apress and Packt was that they had enough beginner’s books. Apress did come back after rejecting my book idea and asked if I could do a video tutorial for beginners. I said yes, I completed it in 6 weeks, and you can watch it, if you have a subscription, at https://link.springer.com/video/10.1007/978-1-4842-8614-2.

My meeting from Packt was a little different from O’Reilly and Apress. While the turned down my beginner’s book they encouraged me to come up with another proposal. During our discussions, I came up with the idea of a beginner’s book for experts. Developers today are typically fluent in several languages. If they found themselves needing to look after a Java code base or had a requirement for a solution to be written in Java, what resources could they turn to. I did not think they needed a book that explained what a compiler is, what a variable is, or what a loop is for.

Instead, I proposed, after our discussions, a book aimed at developers with experience with any imperative language. From what I could tell, based on admittedly very little research, such a category of book, expert new learner’s book, was near unique. Packt must have thought so too because they asked me to go ahead with an outline for the book.

The first outline consisted of 10 chapters and 200 pages. In moving from an informal to a formal proposal, the book grew to 13 chapters and 250 pages. Now that, as it felt, my bluff was called I was concerned I could not write that much. Despite my concerns about my ability to write the book, a deal was struck, an advance on royalties agreed to, and a contract was signed. The official start of writing was May 2022 with completion in December 2022.

As each chapter was written it was sent to the editorial team responsible for my book. I remember that after sending the first chapter I was worried they would cancel the contract. Instead, the feedback was positive with numerous minor grammar and style issues that I needed to resolve. As I progressed, I know that I was learning how to write a book as the number of editorial comments became fewer and fewer.

This is also when the next expansion of the book occurred. While writing about the structure and syntax of the language I realized I had more to say than I thought I did. This quickly added three more chapters. It was four but the last section of the book on packaging applications went from two to one chapter. This is when I discovered that writing the text was only half the work.

I learn by tinkering with and modifying existing code. Therefore, it was important that every chapter had code to work with. I discovered that preparing the code was far more time consuming than I imagined. I had to be certain that every line of code, no matter how simple, was professional. I also made the decision that while a reader could use any IDE they wanted, the book was presented with just a text editor, a JDK, and the Maven build tool. For an exploration of Jakarta server-side coding I just added the GlassFish server. The three main IDEs were presented but I did not want to fill the book with instructions on how to use NetBeans, Eclipse, or IntelliJ.

During the writing process chapters were also reviewed by a technical reviewer or TR. One was selected by Packt and one recommended by me. I asked Robert Scholte to be my TR after he kindly answered a question I posted on Twitter concerning Maven. He accepted my request. So now not only was I worried about the editorial review, but I was also now terrified of the technical review. I should not have been. Both Robert and the Packet TR, Massimiliano Dessì, made constructive suggestions that resulted in a better book. My concern that a TR comment might begin with “What the f#ck do you mean in this chapter” was unfounded.

I cannot say that I worked every day on the book. Hindsight suggests I should have. Still, the team at Packt were both supportive and patient with me. When grammar or style changes were requested, I always deferred to them. After all, they were the professionals while I was just an amateur writer. On the very few occasions when I was questioned by a TR about what I wrote, I found that I could either accept that a change was necessary, or I could explain why my presentation was indeed correct.

It is now a year from when I started. This means the book took more than the projected 8 months. It is done and as I write this on April 23, the official publication date is April 28. It was harder to write than I imagined. You may think an author knows everything on their topic but in my case, I learned a lot. I learned how to write for a book, how to code for a book, and learned the small details that an experienced programmer coming from another language needs to know.

To my team at Packt a big thank you for the support. They are:

Publishing Product Manager: Kunal Sawant

Senior Editor: Rohit Singh

Technical Editor: Pradeep Sahu

Copy Editor: Safis Editing

Project Coordinator: Prajakta Naik

Proofreader: Safis Editing

Indexer: Manju Arasan

Production Designer: Shyam Sundar Korumilli

Developer Relations Marketing Executives: Sonia Chauhan and Rayyan Khan

Business Development Executive: Kriti Sharma

And of course, my TRs, Massimiliano Dessì and Robert Scholte.

All that is left is to tell you that book, Transitioning to Java ISBN 978-1-80461-401-3 is available at Amazon, Barnes and Noble, Packt and possibly more book sellers. An E-book is also available. All the book’s source code can be found at https://github.com/PacktPublishing/Transitioning-to-Java. Please buy the book or recommend it to friends or co-workers should you or they need to learn Java in the time it takes to read the book.

Remember the 10 chapters and 200 pages? The finished book is 16 chapters and 330 pages. I could have written more.

Ken Fogel

April, 2023

About Ken Fogel

Java Champion, JCP Executive Committee Member, Vice-President of the Jakarta EE Ambassadors, NetBeans Dream Team Member, and conference speaker/organizer. Currently a Research Scholar in Residence at Dawson College after retiring from the classroom. Passionate about teaching and inspiring everyone to be better programmers.

1 thought on “On Writing Transitioning to Java, My First Book

  1. Alfred C Thompson II

    I could have used a book like that a couple of years ago. It is probably still a book I should think about.

    Congratulations on getting it done. More than a few would be authors have not gotten nearly to completion.

    Reply

Leave a Reply to Alfred C Thompson II Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.