Date Archives giugno 2015

Changin’ the Stack

Sometimes you have to take a break.

No matter how much you love what you do, but studying something new is always exciting and funny. As a developer, I know that is the best part of my job: when you are quite confident with a certain technology…  well, maybe it’s time to learn something new.

Obviously, I am not leaving Laravel and its fantastic community. However, I decided to dedicate a slice of my time to learn a totally different stack: from LAMP, to MEAN.

Probably you already know it. If not, MEAN is an acronym that stands for

  • MongoDB;
  • Express;
  • AngularJS;
  • NodeJS;

I don’t feel like someone can stumble upon serious issues while installing another PHP framework, so I decided to change the entire thing.

3285OS_MEAN Web Development_cover

I just bought “MEAN Web Development” by Amos Q. Haviv  from Packt Publishing. I will report here, on my blog, all my thoughts about this new path, eventually along with something else if I will find something interesting.

My learning path will be the following:

  • learn the NodeJS basics;
  • learn the Express basics;
  • learn the MongoDB basics;
  • learn the AngularJS basics;
  • learn how to create and configure a basic MEAN VM on Vagrant;
  • extra: learn something about Docker;

My primary focus will be on backend technologies and honestly, I can’t wait to reach the MongoDB part. We are in 2015 and I have never experienced the NoSQL paradigm. That sucks.

Let’s see what happens.


Update #1 : June 13th, 2015

Right now, I have just finished the second chapter. The first one is dedicated to the very basics: installing NodeJS and some first tests with MongoDB.

The book is awesomely clear: I love that writing style in IT books.

The second chapter is about NodeJS in a more “deeper” way. It deals with JS event-driven programming in detail, and then explains how to create some really basic server (and a little, little app) with Connect.

Can’t wait to start the 3rd chapter, about Express!


Update #2 : June 14th, 2015

Everything great with the Express chapter and the MongoDB one. A perfect introduction to both concepts.

Now I am a little stuck with Vagrant. I tried this suggested box, but got many issues and problems when using Yeoman. Maybe it’s too early. I will try a different approach: I will use the VM without Yeoman and other solutions (meanjs.org and mean.io). After all, right now I am working only with NodeJS, MongoDB and Express.

No frontend. Let’s see what happens.


Update #3 : June 15th, 2015

I found many issues, related to permissions and users, with arvindr21/mean-box. So, I decided to make a new Vagrant VM starting from the very basic (a classic hashicorp/precise64).

I solved many of these issues, but when trying to install meanjs.org or mean.io projects it failed. Sometimes on a specific package, sometimes for the tar tar.unpack untar error. Sometimes I can successfully scaffold the application using Yeoman, but then, during the npm install, something goes wrong.

Many people explain this with “vagrant vm related problems”. I don’t know: however, many problems related to the virtual machine utility are a real thing. In the next days I will try to use my VM with some basic setup. If it will work, I will publish it on github and here. 🙂

Time to learn something more about Docker!


Update #4: June 17th, 2015

Ok, quick update today.

Here’s my first contribution about MEAN and Vagrant. This is a very basic first proposal of a Vagrantfile with two separate provision files.

I will talk about it soon in more detail

Until then, you can find it here on Github.

Cheers!


Useful Resources

In the following list you will find some interesting article I found about MEAN (or about its single components) around the internet. Hope they will help you. They are not only “MEAN is cool m8” articles, I will hear the opinions from both sides.

Perché sono d’accordo con Jovanotti sul lavoro “gratis”.

Pochi minuti fa mi sono ritrovato sul sito di Repubblica, a guardare un video in cui Jovanotti spiega perché, in alcuni frangenti, lavorare “gratis” è bello. Il titolo dell’articolo ha suscitato (giustamente) la mia curiosità. Una conseguenza logica, ovvia, dato che da sviluppatore ho sempre vissuto sulla mia pelle il problema.

Jovanotti

Chiunque sia del mestiere lo sa: negli ultimi anni il nostro lavoro è stato sempre svalutato. Solo di recente le cose sono cambiate. Leggermente, ma sono cambiate ed in meglio.

Comunque sia, un passaggio in particolare del suo discorso mi ha colpito:

… Così mi sono ricordato che quando ero ragazzo anche io lavoravo gratis alle sagre e mi divertivo come un pazzo. Imparavo ad essere gentile con le persone, se mi avessero detto non lo fare, vai in colonia, sarebbe stato peggio. Ma per me quel volontariato lì era una festa anche se lavoravo alla sagra della ranocchia… Mi dava qualcosa …

Non solo mi ha colpito, ma lo ha fatto anche positivamente. Tuttavia, in giro su internet molti opinionisti hanno voluto dire la loro ed anche con una certa ferocia tipica dell’ignorante 3.0.

Insomma: fiato alle trombe come al solito. Nella maggior parte dei casi ho letto pareri assolutamente contrari e questo di seguito è uno dei tanti esempi.

Sono sincero: la cosa non mi ha stupito più di tanto. Un tweet del genere è proprio la quintessenza, e la dimostrazione perfetta, l’esempio per antonomasia, dell’abilità tutta italiana di fare di tutta l’erba un fascio.

Che il lavoro gratis sia deplorevole ci arrivano tutti. Non ci vuole l’arte. Tuttavia, in alcuni frangenti della propria vita, fare qualcosa “gratis” può dare benefici a lungo termine che, in tutta onestà, il denaro non può dare.

In questo discorso sono convinto c’entri anche il sistema dell’istruzione. Ne parlerò, tempo permettendo, più in là.

Tornando a noi, per capirci meglio, ecco qualche esempio puramente personale:

  • Da piccolo io stesso ho fatto qualche lavoretto, di vario genere. Dall’aiuto macellaio all’aiuto pescivendolo, passando per un bancone del bar e per la reception di un albergo. A volte pagato, a volte no, a volte meno del dovuto. Il risultato? Mi ricordo di essermi divertito come un pazzo anche io, e di aver imparato un sacco di cose;
  • Tante, tantissime volte ho offerto la mia consulenza gratuitamente quando ho visto un progetto interessante sulla mia strada. Sempre per lo stesso motivo: per divertimento. Senza contare le meravigliose amicizie che mi sono fatto per la strada. Quindi, “Collaborazione > Soldi”. Non scordiamolo;

Di contro, mi è capitato di vedere tante persone ossessionate così tanto dai soldi che non hanno fatto neanche un centesimo.

Insomma, riassumendo:

  • ragazzi (e non), fidatevi: a volte lavorare “gratis” non vuol dire lavorare gratis;
  • critici della domenica, è vero che su internet potete dire quello che volete, ma a volte è facile perdere un’ottima occasione per star zitti;

Meditiamo.

A Year of Books – 2015

This January, Mark Zuckerberg announced “A Year of Books, a very interesting initative. Something simple and cool: the symbolic target to read a book every month. So, a minimum of twelve books every year.

I really liked it, and made it mine. So, in january, I started my “Year of Books” too. I will use this post to take notes about my year books.

Note: the links you are going to see here are not referral links.

Last Update: September 18, 2015


6a0162fff12125970d017d401cd7e1970c-800wi

January – Flatland: A Romance of Many Dimensions by Edwin Abbott Abbott

My first book was this fantastic satirical novel by Edwin Abbott Abbott. At a glance it seems something nerd, but if you read it carefully things change.

It’s a fantastic work with a fantastic message about diversity and going beyond what we can see and perceive.

My year could not start in a better way.

This Book on Amazon


9780141187945

February – The Fall by Albert Camus

In february, I chosen “The Fall”. I liked Camus style, and I liked to hear (well, actually read is more appropriate) the stories of Jean-Baptiste. I am not going deep into the story, I don’t want to spoiler nothing. However, a very appreciated book.

Honestly, I think I will read it again in the future.

However, it was a very short book, so I finished my february book during the first days of the month. Obviously, I could not wait the end of the month to eat another book…

This Book on Amazon

 


cover

March – How Google Works by Eric Schmidt

And now, something more technical.

I really enjoyed this “full-of-good-advices” books from Eric Schmidt (Google CEO until 2011). It was cool because, you don’t need to be the CEO of a multi-billion company to follow his advices and improve yourself.

A teaching that I will not forget is really simple quote: “be a router”. Of course, it wasn’t the only one. This is one of those books that I would suggest to anyone, not only to IT people.

This Book on Amazon


appunti-di-un-venditore-di-donne-libro

April – Appunti di un Venditore di Donne by Giorgio Faletti

In April, I went back to novels. I chosen this one because I love Faletti’s writing style. Easy to read, fluid, with a special consideration for descriptions, without losing the focus on the story.

The book follows the story of Bravo, a man who sells women.

I also liked it for the historical setting: the Italian 70’s, the Aldo Moro’s kidnapping and the end of the Years of Lead.

This Book on Amazon


411YBdZVAPL._SY344_BO1,204,203,200_

May – Zero to One by Peter Thiel

I am serious when I say that I love this book. The startup world is literally full of commonplaces: this book deflates them one by one.

Starting from the 2000 dotcom bubble, this book analyses many aspects of the startup world and, in general, of the business world from a new perspective.

I really enjoyed Thiel’s visions about competition and monopolies, also related to the school system. A must read, imho.

This Book on Amazon


51sHGrbY9vL

 

June – Seven Brief Lessons in Physics by Carlo Rovelli

I seriously think that this one will easily enter in my top three.

Carlo Rovelli is a real divulger. His style is perfect, fluid, easy to understand and I think that everyone should read this little book.

I particularly love the lesson about the Einstein’s Theory of Relativity, the “most beautiful theory”. A specific sentence, in this chapter, will be impressed forever in my mind: “holidays are the moments when you can study in a better way, because you are not distracted by school“.

This Book on Amazon


71eB-r+HRAL

July – Submission by Michel Houellebecq

Time for another novel. The story of a professor, in a very different France from the one we know.

To be honest, the book tells two different stories. The “inner” story of Francois, the main character, about his thoughts, about his life in every aspect, and the “outer” story of Francois. A story about a whole country. It made me think about Islam and its culture. It’s a totally different world than the one we live everyday. And this was the most impressive thing in this book. The different culture, that slowly overcome everything else, every previous custom, or law.

I really appreciated it.

This Book on Amazon


41MGlhhZNIL

August – The Hard Thing About Hard Things by Ben Horowitz

On May, I dedicated my month to Peter Thiel’s “Zero To One”. When I bought it from Amazon I also took “Creativity Inc.” by Ed Catmull and this awesome piece by Ben Horowitz. If you don’t know Horowitz you probably know one or more company in which he invested. Just a couple of names: Facebook, Twitter, Github, AirBnb.

Quite impressive, huh? However, if it’s not enough, he’s one of the few people that was able to make an exit of $1.6 billion dollars with a company that survived the dotcom bubble.

In this book, he talks about “the hard thing about hard things”. The main concept is quite simple: everyone is able to study the “right way” of company organization design but… what to do when things go really wrong? How can you fire a loyal friend, or how you can understand if “that” guy is ok for an high management position?

It’s really difficult, because, as he says: “Everybody learns to be a CEO by being a CEO. No training as a manager, general manager, or in any other job prepares you to run a company. The only thing that prepares you to run a company is running a company“.

Another awesome choice for my “Year of Books”.

This Book on Amazon


718ujeSxgqL._SL1500_

September – Stammi Felice by Luciano de Crescenzo

The first time I saw a book by Luciano de Crescenzo was many, many years ago at my grandma house. Just like me, she was a very great book-eater. To be honest, I don’t remember what books it was, however I was captured by the writer style. Probably I was reading “Storia della Filosofia Greca” (“History of Greek Philosophy”).

However, I can say that I always loved Luciano de Crescenzo. For many reasons. For his writing style, his humour, and after many years I also learned that he was an IBMer (maybe one day I will talk about my love for IBM).

In this book, that I read some days ago, he speaks about happiness and how it could be conceived by many philosophers, picturing himself during a dinner with them. Starting from Socrates and finishing with Antonio de Curtis, also known as Totò.

Amazing.

This Book on Amazon (only in Italian this time… sorry guys)


61ksczei4HL._SL1035_

October – Ti Sembra il Caso? by Erri de Luca

 

Another relaxing lecture this month. A really short book, but I have a good excuse: it was a really hard month. I changed my entire life (again) as I have found a new job, so… hope you understand.

“Ti Sembra il Caso” is a dialogue between a writer and a biologist, and between two friends. Erri and Paolo. They speak about DNA (Paolo studies are related to some specific genes), about life, about feelings. A little bit of everything. Well, it’s not exactly a dialogue in the literal way: to be more precise, a correspondence.

A really enjoyable and “light” lecture.


Updates Coming Soon…