Spicy Vegetable Soup

Ingredients:

(this recipe works also well as a vegetarian version)

  • Leek
  • Carrot
  • Red Onion
  • Zucchini
  • Chicken Breast Filet
  • Beef Stock (you can use a bouillon cube)
  • Soup Noodles
  • Butter
  • Chilli
  • Salt
  • Pepper

Instructions

Cut all the vegetables and the meat. You kind of have to guess the amounts to use since vegetables come in so many varying sizes. I have used 1 big zucchini, 4 really small carrots, 1/2 red onion and 3 regular leeks. I think the pictures show the amounts quite well.

Leek

Carrot

Zucchini

Red Onion

Now put a big chunk of butter in the pot and let it melt for a few moments

Butter

Then add all the vegetables, use medium heat and a lid and let the vegetable get acquainted with the butter for about 10 minutes. In the meantime get some water (I suggest 1.5l) boiling.

After 10 minutes remove the lid and add the water. Use a little more water than it would need to just cover the vegetables with it. Now add some noodles. In the first attempt use half of a coffee or teacup with soup noodles. Also add salt, pepper, the bouillon cube / beef stock and chili to spice it up.

If you not use enough water, the soup is not really a soup but a pile of steaming vegetables, if you use too much water it will not taste so awesome. Take care, I know that things like these are whats hard about cooking but add enough to cover the vegetables and then some more to make it look like a soup. Usually thats less water than was needed to cover the vegetables.

All in the Pot

Now this will take another 10 minutes to be ready. In the meantime put the meat in a pan and use medium heat, salt, pepper, a little bit of chili to prepare it.

Soup and Meat

Soup and Meat Done

The soup is ready whenever the noodles in the soup are ready. The meat you can prepare as you like. Now put everything together on a plate and it should look like this:

Final Image of the Soup

Buon appetito!

Guitar equipment and learning to play

Preface

I like guitar music a lot and for a long time I wanted to be able to play the guitar myself. Way too late I finally decided to just buy one and try it. A friend of mine who is an super experienced guitar player helped me to get started and so I bought a cheap Jack & Danny’s Les Paul replica which was about 150 Euros. My friend gave me a small amp as well and I was ready to go.

Guitar with new pickups and new amp

First Steps

My friend also agreed to give me guitar lessons and so we met once a week and I made some good progress but in the end we couldn’t continue to do it on a regular basis. Then I got a new job and soon I would forget about this whole guitar business. The books I had were way too boring and the supplementary CDs were too annoying. Long story short, my guitar caught a lot of dust.

New Pickups

Many months later I picked up some motivation again after listening to someone playing the ukulele. What caught me in this moment was the realization that it was possible to play songs and have fun without being super skilled. I totally forgot about that.

A day later I dusted off my guitar, ordered new strings and browsed though some music store websites. Along the way I stumbled upon tuning parts where the music stores would sell pickups, bridges and all kinds of original and third party accessories. Inspired by the vast amount of available parts the nerd in me was thinking about buying original Gibson pickups to improve my cheap guitar and so, after two days of reading blog posts and watching youtube videos about changing pickups and its potential benefits, I just ordered them. I got the Gibson 490R and a 498T which can be found in this combination on a lot of expensive Gibson guitars.

When they arrived I started to disassemble my guitar – and it didn’t look pretty. The guitar was made of the cheapest of woods and the soldering was so sloppy that I would have loved to rip everything apart and start from scratch.

Open Guitar

In the end I focussed on the pickups since it was not clear whether it would work at all. The old pickups just had two wires while the new ones had four. This was expected though after studying plenty of blog posts on that topic. Luckily not only the music store where I bought them had a guide on replacing the pickups but there are many other resources available online as well. One popular producer of third party pickups is Seymour Duncan and on their website they have example circuits for almost any guitar configuration you could think of. The wire color is different from vendor to vendor but in principle the wiring is the same and the one from Seymour Duncan was the best one I found. Here is the wiring schema for typical Les Paul models.

After fighting with removing the old cables and attaching the new ones for a while I hooked it up to my amp and was more than happy to find out that it actually worked.

Now before taking my guitar apart I have also recorded some simple chord progressions to be able to compare the result afterwards and so I recorded the same chords with the new pickups.

The result? Well, immediately the sound appeared lot richer, more saturated and bold. That was my first impression. When I compared the recordings I saw that the output level of the new pickups was much higher – almost twice as high. Usually I had the volume controls of my guitar all the way up to 10, with the new pickups I had to set them to 6 or 7 to get to a similar output level.

When I checked again the pickup descriptions the for the 498T said that it was actually a high output version »for hard rock applications which easily overdrives your amplifier with a beefy, sizzling output that will give your guitar new power and presence«. The 490R one says: »… these pickups give a full, rich tonal response with a thick, biting rock tone with excellent definition and harmonics«. Marketing language aside, since I first listened how they sound and afterwards read the description, I was recognizing some of those attributes in the sound I heard.

After adjusting the volume it was still a different sound. The old ones sounded really bright which gave a nice clean sound but the new ones sound more balanced more powerful. The recording from my computer can’t really show that. You can see the different output levels but the sound difference becomes more obvious when hooked up to a real amp instead of software.

If you have a cheap guitar that sounds crappy you might be gaining something from changing the pickups as well.

Anyway, after this success my motivation levels increased even more.

The new Amp

In fact this gadget driven motivation approach also made me buy a new amp. The old one I had from my friend was an old Squier 15W without any fancy features. When I was looking for a new and not super expensive practice amp the decision boiled down to a Fender Mustang I and a Vox VT20+ which are both so called modeling amps. That means that a lot of different amp models and effects are built into the amp and you get to play a lot of different styles with them. The Fender Mustang can be even hooked up to your computer via USB to model your individual sound with virtual effect pedals etc which can then be uploaded back onto the amp. The Vox has a fixed set of amp models and effects which you can combine at your will with the amp controls. The cool feature of the Vox amp is that they have build a real tube into the power section to make it sound more like a tube amp than a pure transistor based amp like the Fender.

After a lot more blog posts, youtube reviews and comparisons I decided to buy the Vox. Mostly because I liked the sound a lot better but this is really dependent on your personal taste. Both are really great practice amps that you can have a lot of fun with.

The tuner

The last piece of equipment I got was a new tuner. Before I tuned my guitar with my iPhone or the computer but somehow I always had the impression it was not tuned properly. The new amp has a tuner built in but the experience is kind of binary as it only as three LEDs for indicating the tuning. Well it also lights up LEDs for each string but I wanted something more precise. The tuner I bought is the Korg Aw-2G Bk which has a piezo sensor that picks up the vibrations of the instrument. With this I do not need to connect the guitar to any device for tuning and it works great for the cheap acoustic guitar I have sitting around as well.

Learning to play the guitar in the 21st century

Now that I had this awesome new gear the question remained how I would actually improve my skills. I knew that the teacher concept did not really work for me because of my schedule and because sometimes one hour was too less and sometimes I didn’t want to drive around the city with my guitar. My pace of learning is highly varying and a fixed teacher schedule just didn’t feel right for me. The books, as I have mentioned were to boring and uninspiring and so I thought:

»Hey its the 21st century! Aren’t there any cool website by now with lots of videos and online lessons?«

A quick round of searching the web revealed a couple of those services of which I choses jamplay.com. They have videos in great quality, a lot of teachers and a lot of lessons varying from basics, specific style lessons, technique and lessons about recording, song writing etc. The great part about the multiple teachers is that if you don’t like one particular teacher, there are still 10 other ones having lessons for the same skill set or style. Its about 15 dollars a month and you get to watch as many videos as you want and they also work on an iPad.

Now almost every evening I spend 1-2 hours watching videos and practicing. For me it is the perfect setup and I have the feeling that I learn a lot of stuff quickly.

Sooner or later I will also buy a better guitar, that is more pleasant to play and which uses more quality parts but for now I’m good. I’m already saving up my flattr money but it will take a while until I get there.

Finally I want to highlight thomann.de as a good example for online music equipment stores. They have extensive guides about exchanging pickups, choosing a proper amp, recording equipment and a lot of other topics. They have sound examples for guitars and amps! So if you consider new gear go to their site to get advice and sound examples.

Why Erlang?

The chance that you are reading this blog post on a device with a multicore cpu is increasing on a daily basis which is why everybody is talking about concurrency now. Concurrency for our web applications and API backends means that we’d like our htop to look like this:

htop screenshot

I’ve recently been to a really awesome ruby conference and three or four talks out of 21 were about concurrency. The ruby community is quite open and so many possibilities were discussed: Using threads, using different ruby runtimes to circumvent the GIL, using more processes, using the actor model via libraries like Celluloid or even using Akka through JRuby.

While the actor model seems to be a good fit for building concurrent network applications it often suffers from problems if the runtime it is implemented in has no “native” support for it. There are implementations for Ruby, Python and Java but they all have to jump through several hoops to get the job done and are not necessarily yielding the best performance. This is one of many reasons why Erlang would be a much better choice but first, lets talk about this actor model for a bit to understand why it is such a good fit.

The Actor Model

There is this nice quote from wikipedia which offers a first glimpse:

»The Actor model adopts the philosophy that everything is an actor. This is similar to the everything is an object philosophy used by some object-oriented programming languages, but differs in that object-oriented software is typically executed sequentially, while the Actor model is inherently concurrent.«

While there are some resemblances between actors and objects, like modularity, encapsulation and message passing, the main feature of actors is that they are being run at the same time.

Strictly using message passing for sharing state with other actors which run in parallel enables asynchronous communication, meaning that the sender does not have to wait for a response from the receiver.

Another big difference to the OOP world is that in the actor model there is no global state and therefore also no shared memory between actors. In languages like Java, Ruby and Python there is always global state and threads have access to shared memory. This is often a cause for trouble in the form of deadlocks or race conditions and is maybe the biggest pain of using threads.

In the actor model each actor has its own internal state and is only sharing it via messages. Thereby it is acting as a serializer for access to its state and effectively preventing deadlocks and race conditions.

It might be also worth noting that the actor model especially makes sense for functional languages as they embrace the concept of immutable data.

There is a lot more to read about actors but I would say these are the most important bits to know. In general the actor model makes designing and implementing concurrent applications a lot easier. Compared to threads there is no need of managing the access to information with mutexes, locks or semaphores or other complex abstractions.

Ok, so what about Erlang?

First let me tell you that for years I have been a passionate Ruby developer. I really like the language and community a lot. From time to time though I felt I was hitting some invisible walls when it came to network applications like web apps, web servers, proxies etc. Basically everything that had to handle a lot of requests and/or did non trivial tasks.

I had Erlang on my radar for quite some time but coming from my ivory tower with a ruby rooftop it took several attempts to convince me that it was worth a try. Conceptually it already made a lot of sense to me and I’m sure that most people who read about Erlang will agree. I have to admit that I was mostly appalled by the weird syntax so much that it stopped me from trying. This was a big mistake though and a large part of my motivation to write this blog post is about telling you that you should try out Erlang as soon as possible.

Anyway, first lets describe Erlang in one line:

»Erlang is a functional language, implementing the actor model for concurrency.«

Its a language which was developed by Ericsson for their carrier grade telecom switches and the design goals were to create a language that would allow to design fault tolerant, highly available and concurrently running systems.

You can read all about it on wikipedia or this awesome website: http://learnyousomeerlang.com/ – They do a much better job describing the language.

Case study for Erlang at Wooga

This post is about getting you to try it and I will do that by telling a story about Erlang at Wooga.

Wooga makes social games with millions of daily active users. The games constantly talk to the servers to transform and persist the users game state. Some of our game backends are developed in Ruby and that worked really well so far. Ruby, like I said, is a really nice programming language and although it is certainly not the fastest, you can squeeze a lot of performance out of it when you know what you are doing.

Our biggest game in terms of users, revenue and backend complexity runs on about 80 to 200 application servers though. It handles about 5000-7000 requests per second and almost all of them are changing the game state of the user. I’d say the amount of application servers is still reasonable for the amount of load but its certainly not the most impressive number.

Then some day a new backend had to be built for a game with similar complexity and my colleague Paolo suggested to use Erlang this time as he thought it would be a really great fit for us. We hired an experienced Erlang developer (Knut) and together they implemented the backend. By now this game has approximately 50% of the users of the other game and the number of application servers they need is: 1!

They run the backend on two or three servers for redundancy purposes but it could perfectly run on one. Even if it would actually need four it would still be drastically more efficient and performant that the other backend(s).

Now of course they also knew about all the mistakes we have made in previous games and its not Erlang alone that gave them so much better performance but rather they could implement the backend in a unique way which is really easy with the actor model and rather hard everywhere else.

Basically they’ve build a stateful web server which means that each user who is playing the game is represented by an actor inside of the Erlang VM. The user starts playing and an actor with the users game state is spawned. All subsequent requests for the time the user is playing are going directly to this actor. Since the game state is held in the actors own memory all requests, which would otherwise hit the database, can be processed and answered extremely quickly.

If the actor crashes, all the other actors are not being harmed since there is no shared / global state. When the user stops playing, the actor will save the game state to a persistent data store and terminate making it easy for the garbage collection. Since the data is immutable it is always possible to revert to the game state before the transformation started in case something goes wrong.

It is really awesome and there is a lot more to tell about it. Fortunately Knut and Paolo have spoken on a couple of conferences about it and shared their slides so you can get some more insights:

* http://www.slideshare.net/wooga/erlang-factory-sanfran
* http://www.slideshare.net/hungryblank/getting-real-with-erlang

More Erlang at Wooga

After Paolo’s and Knut’s success the Erlang virus spread inside of the company. We have started new game backends in Erlang and built smaller additional services with it. Personally I can confirm that the more you learn about Erlang the more it makes sense and feels right. It made me even feel a little bit sorry for those at the Ruby conference who were struggling with different runtimes and libraries to introduce the level of concurrency and ease of development that Erlang delivers in one package. A package that has been in production use for more than 20 years.

The hard part of learning new languages is to find a reasonably sized project to start with. Learning just by reading books is always slow as you forget most of what you read when you don’t play around with it. Apart from the weird syntax which I don’t find that weird anymore, not having an actual project to try Erlang was the biggest show stopper for me. So I encourage you to pick a small little project and play around with Erlang. I think you will not regret it.

I hope I will find the time for a follow up blog post about how I learned Erlang and about getting started in it soon. In the meantime go to learnyousomeerlang.com and get started on your own. Trust me – this site is better than any book about Erlang which you can buy right now.

PS: Thanks to Elise Huard for proof reading! If you have feedback, drawings of an ivory tower with a ruby rooftop to make this blog post more colorful or any other contributions send it right away!

Text Editors for Programmers on the Mac

Preface

In the last 10 years many new text editors became available for Mac OS X. Since I have tried most of them I wanted to give an overview and a brief description about each one of them. This is for developers that are looking for decent editors on the mac to get their job done.

Lets get straight to it then.

The Editors

Emacs / Vim

Emacs and Vim are really the dinosaurs of text editors for programmers. Both have a immensely rich feature set and can be extended to a degree where you can forget about the OS they are running on. Although there is and always was a strong debate about which one of the two is superior, it is mostly a matter of personal taste in the end. Both have a steep learning curve and both are probably not something you want to give your web development intern on the first day at the office. However they are really powerful and they have one big advantage in common which is that they are available on a lot of operating systems and are installed by default on most of them. Whenever you log into a linux, bsd, osx or other unix machine you can be sure that vi or emacs or both are already there. On some shared web hosts you can’t even install your own packages so you are stuck with one of them. The cool thing is that you have to learn only one editor and all its specialities and you can work with it on almost any platform and on any remote machine. Since they are both really old they are known to work. They can handle big text files without crashing and for every problem you encounter there is already an extension to solve it. This is why many experienced programmers which started with more modern editors come back to them.

Some of the features that very few other editors offer are: horizontal and vertical split views, whole project tab completion ( most other editors only complete words from the same file ), fundamental customization of almost every behavior of the editor.

Besides the features related to programming they are also powerful text editors.

Both editors have OS X versions with a nice GUI wrapper to make them better integrated citizens, AquaEmacs and MacVim.

I really recommend reading the blog post by Yehuda Katz about switching to MacVim.

Both of them are open source and free of charge.

BBEdit / TextWrangler

Speaking of dinosaurs of course BBEdit and the light weight version called TextWrangler come to mind. They are not as old as Emacs and Vim but BBEdit is around for 20 years! It claims to be the editor »that doesn’t suck« and it is a strong contender. However it is really focussed on text rather than programming. It has a lot of features dealing with plain text manipulation, search and replace etc. but lacks some of the features I need in my daily programming job. It has syntax highlighting, auto completion, syntax checking for a few languages and much more but in the end it always feels a little dusty compared to other editors. For example it supports SVN, CVS and Perforce but not Git in its most recent version.

I’d recommend BBEdit more to markup authors than to programmers but its worth checking out the website and the trial version.

SubEthaEdit

I’m not sure how log SubEthaEdit exists but its at least 6 or 7 years I’d say. The wikipedia page does not say anything about it so if one of the readers has a more accurate number let me know.

SubEthaEdit shines in collaborative editing and most of the time that also applies more to plain text than to programming but still, its a cool feature which allows you to edit text documents via internet or local bonjour connection. Other than that it is also a decent editor for programming with support for a lot of different programming languages. It is simple and does not take a whole lot of time to learn. In the end though it is also limited compared to the other more powerful editors. Non the less I think it belongs on this list.

Smultron

When it comes to simple and basic text editors for programming activities you have to take a look at Smultron. It used to be free but now its around 5$ in the Mac App Store. Still quite cheap and it features an icon you can’t miss in your dock! But seriously – its probably one of the most straight forward and simple text editors for the mac. Possibly a good entry point when you are just starting with programming and only need syntax highlighting and other basic editing features.

Textmate

Textmate was and probably still is the default text editor for many ruby developers. When the web framework Ruby on Rails first came out, the screencasts that came with it demonstrated the editing powers of Textmate so that everybody else started to use it as well. Compared to the other editors that were available at the time it was superior in almost every discipline. It was a lot better integrated into the mac environment compared to emacs or vim, offering standard shortcuts, preferences and native text controls. It supported a lot of languages and so called bundles which are a mixture of snippets, macros and other useful language specific functions like syntax validation or build system integration. It offered more comfort and flexibility than SubEthaEdit or BBEdit. It felt more productive and faster and it was easy to learn.

Why am I using the past tense here? Most of this still applies but Textmate did not receive a major update in years. Textmate2 became what Duke Nukem Forever was already famous for: Vaporware. Just recently some Textmate developer claimed that there would be an alpha release by the end of the year but I won’t believe it until a download link shows up on their website.

The problem with Textmate is mostly its lack of performance with big files, the instability of some really useful extensions and the lack of some features I have learned to love in other text editors like split views for example.

I quit using Textmate because I used some extensions which made it crash to often and because it crashed and locked up when working with big files. Other than that it is still a great editor and its principles were copied to a lot of other editors on other platforms.

Even today I use it for html, xml and other markup languages because its just the fasted editor to work with in that discipline.

I highly recommend trying it. There is a 30-day trial version.

Kod

When the people realized that TextMate2 was vaporware and no new version to fix the issues described above was in sight, alternative editors slowly began to appear. One of them is Kod, although it is really in an early state it is a decent and simple to use editor for programming. Its not offering a lot of features, not like Textmate or the other more powerful editors, but still quite usable. If you don’t want to spend a few dollars for Smultron, this might be just the right editor for you. I mentioned Smultron before because it is more mature while Kod is at version 0.0.3. For additional hipness it is worth knowing that its build upon Googles V8 JS engine.

Readers pointed out that the development is stagnating and nothing really happens anymore but as a basic editor it still works I think.

Sublime Text 2

Like Kod, Sublime Text appeared as well received alternative to Textmate but compared to Kod it has the same kind of feature set as Textmate and more. It even supports Textmates color themes and language definitions which makes a migration to it quite easy.

It even has split views and its lighting fast. It has vertical / column selection (like Vim/Emacs/Textmate), multiple line / word select and different ways to expand the current scope of selection. Really, when I tried it the first time I was amazed how snappy it is. Like Textmate it features snippets, macros and build system integration. On the other side its highly configurable though you have to use simple config files instead of the standard OS X preference panes. I’d say its a perfect mixture of Vims configurability and Textmates editing comfort and speed. I highly recommend giving it a try if you are looking for a powerful, feature rich text editor for programming.

Also worth noting: Sublime Text 2 is a cross platform editor which runs on Windows, Linux and Mac OS X. That fact scares many mac users away without even trying it but I can assure you once more that it runs stable and snappy on OS X and feels as much as a cocoa app as I’d expect it to.

Its price tag is a bit higher than others, currently 59$, but I did not have to hesitate long to support the development of this editor after using it for a couple of days in trial mode.

Vico

If you like the concepts of Vim but MacVim is not wrapping enough of Vims “awkwardness” for you then Vico might be the right editor for you. Basically it uses the vim key bindings and therefore you hardly ever need a mouse to use it and it shows all the shortcuts in a native OS X menu bar. Other than split view support it is a very basic text editor for programming and features a custom scripting language to customize it.

Chocolat

This is yet another Textmate contender but it is currently in private beta phase and its too early to really judge it as many many features are missing in it. I have to say it has the most intuitive split view implementation of all the editors mentioned here but elementary things like vertical / column selection or parenthesis / scope highlighting are still missing.

If you want to give it a try nonetheless go to http://chocolatapp.com/ and sign up for the beta or go to their irc channel on the freenode network and ask for an invite. Took me 5 minutes to get one.

Coda/Espresso

These tools, although from different vendors, focus on the same group of people: web developers. They try to bring the entire development tool set together by bundling the functionality together that is otherwise only found in separate tools like file transfers, version control etc.

I tried them both but although they bundle together lots of features they are very limited at the same time to a certain flavor of web development.

Still on the list as I think they will appeal to some people.

CodeEspresso

skEdit

skEdit is the only editor I haven’t used personally yet so I can’t say much about it other that a colleague of mine is using it as his primary editor for quite some time now so I wanted to mention it for completeness sake. Like Coda and Espresso it is focused on web development but its not as limited to it.

Final words

My first editor was emacs although I only used it in a very basic way. After that I have used Textmate for a couple of years and switched briefly to MacVim for about half a year. Currently I’m using Sublime Text 2 on a daily basis for my programming work.

Personally, I don’t like IDE’s. There are programming languages or environments where an IDE is necessary and really superiour to text editors for programmers but I just don’t like these languages or environments either. So please don’t start a “but $IDE does all of that and more” discussion here. This is about text editors only and yes, I know … some text editors are almost like an IDE.

If I forgot to mention your favorite editor please let me know!

For a more elaborate list checkout wikipedias comparison of text editors

Online Backup Services Revisited

In my last post I compared several online backup services and decided that Crashplan was my personal winner when looking at the features and the price. In the following weeks a couple of people started to complain about the slow transfer rates to their backup servers. I also tested the upload speeds from several networks in germany on internet connections with up to 100 MBit in both directions and I could not get any transfer rate above 3 MBit/s.

I also contacted the support which confirmed that Crashplan is not limiting the bandwidth at all. Inside the Crashplan application settings there are a few options which potentially limit the transfer rate but changing those did not improve the situation for me. I’d be interested to know if US customers get better transfer rates.

Anyway, it is quite unusable like this and so I finally gave up on Crashplan for now. Instead I am now evaluating Arq. Since it uses Amazon S3 storage, you can choose the region in which the datacenter is in and that seems to make a huge difference. I was able to upload my backups with up to 4 MByte/s ( 32 Mbit/s ) on a 100 MBit network which is still not wire speed but much better than the transfer rates of Crashplan. The graphical user interface of Arq is also surprisingly simple and pleasant to use. But this is just a small update. More after I have used Arq for some time.

UPDATE

Arq 2 was just released: http://www.haystacksoftware.com/blog/2011/08/arq-2-is-out/