Showing posts with label review. Show all posts
Showing posts with label review. Show all posts

Monday, February 4, 2013

PHP Application Development with NetBeans: a review

After too much time I've been able to review "PHP Application Development with NetBeans: Beginner's Guide" by M.A. Hossain Tonu, published bky Packt. The official description of the book says that it's "aimed at PHP developers who wish to develop PHP applications while taking advantage of NetBeans functionality to ease their software development efforts and utilize the powerful features of the IDE. Familiarity with NetBeans is not assumed. However, a little familiarity with PHP development is expected.".

TLDR? You can skip the review and jump to the rating. Of course that would kill my ego, but if you still want to stab me in the back here's your knife. Et tu, Brute?

A small disclaimer

I do have a little familiarity with PHP development, and I have a strong familiarity with NetBeans, being a NetBeans Certified Professional, so while on the one hand I belong to the right target, on the other hand I might get extra-critical. Well, the book has been reviewed by no less than six professionals, so I guess my rants can happily and safely be ignored.

I must also note that I have received a free copy of the book in exchange for the review.

Here we go

As every Packt book I've seen (and I've not seen a few) the fonts are easy on the eye and there are many clear pictures. A bit of critic on the code sections, sometimes too long and with a lot of boilerplate that could be found in a downloadable file (it actually is) or confined in an appendix dedicated to the complete code.

Every now and then there are some "Pop quiz" sections, short multiple choice questions. As a rule of thumb I am not very impressed, because they remind me too much of a braindump. I'm OK with the ones on concepts, but not so much with the ones regarding actions, for which I'd rather have more hands-on. Speaking of which, we have the "have a go hero" sections, that often asks us to do completely new things rather than insisting on variations of what has already been done: that can be seen as a plus or a minus, depending on the eyes of the reader.

The first chapter guides the reader through the installation of the IDE and the whole stack environment. Having everything already installed (see initial disclaimer) I didn't check each and every passage, but everything seems very well explained and pretty much the way I remembered it.

The second chapter introduces the editor, yet I'm afraid it doesn't effectively convey all its power and potential, many things have been left unsaid or have not been deepened enough, like the possibility to customize the code templates and the folding criteria, not to mention specific editors for other languages.

One thing I didn't like is the position of the shortcuts, which are often presented out of context and way after the corresponding feature has been described. I think that an approach like "this is your action, and this is its shortcut" would be much better, as the proximity helps to sink the concept in.

The chapter follows the "here's the theory, try it in practice" pattern, yet I find the loop between the two to be too long. This is an issue throughout all the book (at least, it is in my opinion). A little less conversation, a little more action.

The third chapter introduces us to project in which we complete a whole user story. It starts with a description of the technologies used, then slowly presents all the code. The chapter is very similar in concept and structure to the seventh one, in which the skeleton for an enterprise feature (user registration, login and logout) is presented. In both cases there is a lot (trust me, when I say a lot I mean it, particularly in chapter 7) of code before we can actually see something working. Forgive me for the politically uncorrect comparison to another publisher, but from this point of view the "Head First" series are much better, as they start with something working, then they slowly build things up.

Moreover, the chapters are more about the technologies used in the application rather than NetBeans. Chapter 7 in my opinion is even worse, because it deals with more advanced subjects that a beginner probably doesn't know. OK, take the probably away. Yet, ironically, after several patterns and abstractions, and almost at the end of the book, the author says "it is recommended that you are familiar with PHP sessions and cookies in this tutorial", a subject simpler than many others that are taken for granted.

Chapter 4 is on testing and debugging, it's quite good (I must admit I had some problems with my instance of PEAR but that has nothing to do with the book). Some more details on Selenium would do no harm, at least a screenshot of the results should be inserted.

Chapter 5 deals with documenting your code and it's quite good. It also happens to be the chapter that you can download to evaluate the book.

Chapter 6 is about versioning with git and NetBeans. It's not bad, yet it does not show how to unstage a file (why not a have a go hero here?). Another feature that's dealt with too lightly is merging, and the resolution of conflicts is only briefly cited. And, talking about versioning, chapter 2 ends with a warning about the position of NetBeans metadata directory with respect to versioning, but it does not explain the consequences of the choice; some hints or advice would be nice.

TLDR

Now, here we are with the conclusions. If you skipped all the article to jump to this section, please feel a little guilty.

The book should be an introduction, yet some PHP concept are quite advanced for a beginner. It helps you to get up and running with a complete environment and introduces you to many features of NetBeans, yet some important things are left out. All in all, in my very personal scale the books rates 3.5 our of 5.

Tuesday, August 16, 2011

NetBeans IDE 7 Cookbok: a review

After three intense weeks, the last one of which spent tiling floors (I definitely need to improve my speed as a tiler), I've finally been able to complete the review of the "NetBeans IDE 7 Cookbook" by Rhawi Dantas published by Packt.

The book is a collection of recipes (quoting from the text)

...for everyone that wants to try NetBeans or is beginning with a new technology and would like an uncomplicated way to setup and start coding.

Each recipe consists of four different sections:
  1. Getting ready: it tells you what you will need to follow the recipe (a sort of ingredients list)
  2. How to do it: the recipe itself
  3. How it works: an explanation of what is going on behind the curtains (or should I say in the larder?)
  4. There's more: slight variations or new insights (try adding more red hot chili pepper)
Before delving into the actual review, a disclaimer is due. I am a NetBeans Certified Specialist, and I have used it since it was not NetBeans yet, so I'm not exactly the intended target for the book and I might get extra critic (did I say "might"? I surely will). That said... let's tuck in (we're talking about recipes, so the bad pun is intended).

As I said, the book uses a very clear font and has very good and detailed pictures that help you follow the recipes. Sometimes they are a little different from the actual ones, but that is probably due to the fast pacing changes of the software, and this is never a real problem.

All explanations are clear and easy to follow, even if some are too simplistic, of the kind that makes you say "so what?". The most annoying thing are the uncountable typos, which are in no way accountable to the author, whose main job is to focus on the content.

I didn't like the recipes structure for different reasons. One of them is that sometimes one or more sections are useless: I really don't expect to find sentences like "...if NetBeans is not currently installed...", what's more I don't expect to see them more than once. Another one is that this structure gives way to a lot of repetitions, which as a (good lazy) developer I try to avoid whenever I can. This is particularly obvious in recipes strictly based on the previous ones. A simple organization in linear chapters would have been much better.

Another thing I didn't like is the organization of chapters: why wait until chapter 9 for refactoring and until chapter 11 to write about tests, moreover mixed with profiling? In chapter 9 it is said "..refactoring could break code...", and where can you find a better place to introduce tests? (this is a rhetoric question, so if you're answering "chapter 11" either you're wrong or I badly am).

The old but still good NetBeans IDE Field Guide had a very different first chapter, which I really appreciated: this is where you get NetBeans, this is how you install it, this is how you create a project, this is how you run it. New class, new method, new test class, debugging. A few pages and you've covered most of what you'll ever need. And you never have to get back on it.

On the other hand, here I have to wait 200 pages to find that CTRL+R renames almost everything, and a lot of refactoring are forgotten. And the preview option is discussed only ahead in the chapter instead of with the first refactoring.

Another thing I didn't like is a chapter that requires version 6.9: if this is a cookbook based on version 7 you should stick with it, at the most mentioning the fact that the previous version also supported JavaFX. There are so many things that are not supported anymore that could fill another book. By the way, when will we have Struts2 natively integrated instead of Struts1?

Leaving aside the fact that the chapter on version control does not deal with cvs (ops... did I write it aloud?) I was a little disappointed by the fact that most of the interesting things about the IDE are never mentioned: how do I start it with a different JVM? how can I configure projects for each developer's unique environment? (I know it is an antipattern, but it happens even in the best families). What are libraries in the NetBeans vocabulary (a hint: they are not jars) and how do you manually edit them? Shall we talk about the very powerful editor? where are code templates, except for the python example in chapter 10 in which is never said how to distribute your plugin or what the NetBeans Platform is? Can I only generate a web service from an EJB? (another rhetoric question). And many, many more.

All in all, the book is not that bad, but in my grumpy-old-man biased opinion it does not get past a 3 out of 5. Obviously you don't have to entirely rely on my words, as you can download the free chapter on EJB which you can use as a means to get a general impression.

Thursday, July 28, 2011

Coming soon: a review on NetBeans IDE 7 Cookbook

NetBeans users (and curious) stay tuned, I'll be soon reviewing the "NetBeans IDE 7 Cookbook" by Rhawi Dantas published by Packt.

I received it yesterday and the first impression is good, there are many clear images and it seems very easily readable, with nice and untiring fonts - as you can easily verify taking a peek at the free chapter on EJB (which only has the little annoyance of being distributed in black and white while my e-book comes in full color). Yet, it's a little bit too early to say something about the content :-)

This is the first book on the subject I read since NetBeans IDE Field Guide was published in far 2006, so a comparison seems due. You may freely skip the rest of my rants and check for updates in about three weeks.