JCastaneyra blog

My ideas repo

Si la única herramienta que tienes es un martillo ...

| Comments

Hace unos días vi que el Efren tenía en su nick del msn algo así: “si la única herramienta que tienes es un martillo, entonces los problemas empezarán a verse como clavos” (clásico verdad, todo mundo se siente filosofo con su nick, en fin…) , en ese momento no hice mucho caso del mensaje, pero después me llegó un mail de news de javalobby, donde Rick Ross comentaba algo al respecto, con el título del post “I’m a traitor”, él se define a si mismo como un amante de Java, pero reconoce y acepta que no para todos los problemas hay una solución en java, mejor pongo todo el post (ya está aquí el link), he aquí:

I’m a traitor. It’s that simple. It used to be the case that people could automatically assume that anything we built here would be built in Java, and the assumption would be correct. More recently, however, the array of tools and platforms we use to power our network of online developer resources has broadened. Where it used to be an all-Java infrastructure we know have a mix of Java, Ruby, PHP, C++, and a touch of perl and python. It really runs the gamut.

An old adage says that if the only tool you have is a hammer, then all problems start looking like nails. Mustn’t that concept apply to how some of us (me included) have looked at Java over the years? If I am willing to be really truthful, then I have to admit it has. I’ve known this for a while, which is one of the reasons Matt and I made a deliberate choice to evaluate a wider range of possible options for each of the systems we have built during the past couple of years. In situations where we used to automatically begin identifying the best Java solution for every problem we encountered, we now look at the problem and more rigorously assess which tools and platforms provide the best solution.

I love Java, you know it is true. I will have a deep fondness for the Java community until the day I die. In fact, I actually feel uncomfortable when we don’t automatically bias towards a Java-based solution, but it is my responsibility to get over that discomfort and make the right choices for my team and for our communities. Java is simply not the right solution for all problems, even if you’re the most experienced and productive Java shop in the world. Nor are developers faced with a “black & white” polarity where we must choose between Java and .NET. We’re not talking about U.S. presidential elections where it’s a foregone conclusion that either the Republican or the Democrat candidate will win. There is no two-party system in the developer tools and platforms world. We enjoy an amazing diversity in the range of tools and platforms today, and most of them have strengths worth being aware of (and possibly using!) When we decided to write a jobs system we chose to use RubyOnRails. Even though there was much grumbling when things weren’t going smoothly, my overall conclusion is that we got the job done quickly and the solution works as expected. People have asked me whether we will pick RubyOnRails for our next project, and I certainly can’t say no, but I can’t say yes either. I don’t know what tools we’ll use for the next challenge we face. How can I? I don’t know what the challenge is yet! That’s my point, I simply cannot choose the preferred solution before I adequately understand the problem. None of us can.

But back to the “traitor” thing. There are some people who treat me as if I am obligated to wave a Java flag everywhere I go, no matter whether Java is actually the right tool. It’s true that I am the guy CNet once labeled something like the “Johnny Appleseed of Java” (a description which always made me cringe) and I am proud to have been one of the voices of Java advocacy. I believe deeply in the solid values and principles that are expressed in the very heart of the Java platform’s design. If that means, however, that I am obligated to recommend Java as the right solution for every problem, then count me out. I’m sure we can find cheerleaders for Java who are a lot cuter than me!

Después de haber leído me he puesto a pensar (¡si! a veces me pongo a pensar, hasta por cuestiones como ¿Porqué los cangrejos caminan de lado?), ¿Porqué a veces nos enfrascamos en un sólo lenguaje de programación?, en teoría si conocemos o dominamos un lenguaje nos sería mucho más facil aprender lenguajes nuevos, así al momento de encontrarnos con problemas nuevos podríamos llegar a encontrar la herramienta más adecuada para esa solución.

Esto me recuerda también otro artículo que leí, escrito por Peter Norvig y cuyo título es ”Teach Yourself Programming in Ten Years”, aquí en este artículo mencionan que llegar a dominar el arte de la programación nos podría llevar unos 10 años, por todo lo que implica desarrollar la mente lógica de un programador, y de las recomendaciones que hace para lograrlo es que se aprendan varios lenguajes de programación, así nuestra perspectiva al momento de resolver los problemas será más amplia, por eso creo que voy por buen camino, aunque en mi caso será en unos 20 años, digo, porque ya me excedí los 10 años, voy lento pero seguro :D