CTRLio : Tech around me premiere

Hi all,

It’s been a while I did not post here and I was pretty busy at Lodgeo to bring you a major update that will come within the next weeks, but today is not about my company but about something new I want to try. I’m creating this “Tech around me” category as there is a lot of tech oriented activities and startup around me that are not necessarily in the spotlight yet so I decided I would do sometimes a post about things that I saw and tested near to me.

This post is about CTRLio, a webapp that enables you to get the lowest rates on the market for your phone contract based on your current consumption. You can either use their interface to sign in your mobile provider account and get your actual consumption or you can enter estimations so their tool gets you the plan that fits you the best.

The user experience is straightforward you instantly know where to click and within a few seconds you get to know a cheaper plan. Another interesting feature is that you can also get reminders for when your plan will expire so you can fully enjoy this experience. You can find out more on their website: https://ctrlio.com .ctrlio1


Shapeshifting in progress

A couple month ago I told myself I would write my next blog about some personal project I was working on, but then life kinda got sucked into work and since then that project got stuck into development hell. So it will be in another blog, if I write today it’s about the acquisition of an elliptical trainer I made yesterday. I thought it would be nice to just be fit again as back in the days I was playing football. I’m only 24 and don’t feel out of shape in everyday’s life, but I can feel it when I play football with friends and collegues, like I run everywhere for 10-15 minutes and I’m toasted. So I went to get that so I can enjoy playing the trickster on sundays mornings again. By the way this thing was heavy as hell to transport, I was convinced I could easily lift a wide 50+ kilos and carry it over a double kilometer back to my apartment (which ultimately I did but that was excruciating, considering). So today I decided to start the official return of JD to sports by watching a Game of Thrones episode that I started watching yesterday (5th from 5th season, just because), so just trained 40mn with 10 kilometer traveled which is nice for a first (for those that want to try that, don’t forget to constantly hydrate or the stop will be painful). So quite proud of myself and it feels fresh, just feels fresh. Bringing back that kind of activity is quite a good thing not just to enhance as a person but also as an engineer as it will help me broaden my reflexion or even clear my head when I’m stuck on an issue. Video games are good for that but online games can be frustrating sometimes and I will not mention a certain MOBA that I left the Hellish tier a couple of days ago thanks to a friend and some epic games but I’m digressing here. Also, my company Lodgeo released a new version of our app so check it out on both Google Play and the App Store. And I promise next post will be more development related and won’t be in too long. Cheers!

Wondering what makes me an engineer

What makes us engineers, as I was witnessing a lot of changes in my life recently I was wondering who I am, my diplomas and work say I am an engineer, my paycheck says I am an engineer, what do I do to prove I am an engineer and not just a mere developer ? I needed to take a step back and look at what I was and what made me an engineer in the first place. Back when I was a kid I loved drawing, I was drawing at every time of the day, all kind of things, people, animals, fantasy creations, imaginary buildings and so on. Some people saw me as an artist but those were my first attempts at creation.

Around 10, I was writing comics to tell stories but I was never happy with the result and always wanted to do better before I show it to anyone, in the end I just burnt those and nobody ever knew. I was starting to become a perfectionist without even realising what it meant. Then I started creating games on paper, that involved more thinking, I was playing those alone to make sure those would make sense before showing them to my siblings and friends. Same thing happened than with my comics creation attempt, all thrown away.

Then we had a second home computer with Windows 2000 on it, with few games, and it opened a lot of possibilities to me; I wanted to play video games for living, at the time I didn’t know it was actually a thing but the closest thing I could do was video game creator (didn’t know it was called programer or developer back then). I believed that at some point in the process I would get to test some of those creations.

Years later during high school I had to make a choice, at the time my mom wanted me to follow my grandfather footsteps so I become a surgeon, as I wasn’t about what I would do I followed that path during high school that matches the one that would lead me to IT. After I got my A levels, I didn’t really know what to do and I thought that 5 years to become an engineer was a lot. At that time I decided to go to the university in order to get a Higher national diploma of IT which would and actually did take me two years to obtain so I could secure something to be directly employed, but after I achieved that I thought “Ok, I’m 19, what’s next ?”. I didn’t hesitate long I went to an engineering school where I had the possibility to be graduated in three years. That still seemed long to me but I was just taking a year after the other. Lots of bloodshed eyes, allnighters, drinking, partying, exams and three years later that was it, I was an engineer. A few days later I had that discussion that triggered my move to London in a tech oriented startup (Lodgeo) which was the next logical step of my evolution.

Now, it’s been a year and a half I have been here, I have progressed, much more than people can imagine, a lot changed. During my second engineer school year I created a windows phone app called G-Series, quite a decent app that I released as soon as I developed it because I was so proud of it. Once released to the Windows store I got crushed by most of the users that didn’t get the app to work. Not enough testing, I had unit tests but nothing at the UI level. When I saw those critics I was pissed, all those hours spent developing, running it and bragging about how much of a computing god I am were all a waste. After a few days I decided to get back at it, I got it fixed and enhanced it, I wanted it to be perfect so nobody can criticise it. In the end, I never released that enhanced version, last month (a couple of years since I last took a look at that code) I decided to open that project and I ran it on my phone, it seemed ready to be public. I did not do any change to it, but I had a different vision, it was good enough to do what it’s supposed to do without any issues even though there was a few obscure scenarios that may never occur to an actual user that stopped me a few years back.

The reason I do not release this app then is that the market is more than crowded now with additional stuff that did not exist two years ago. At that time I realised that the perfection I was running after is not a fixed state, it’s keep on moving, failing again and again until I have something that people can use, and then make it better, more resilient to wild users. It looks like I finally tempered my vision to deliver something that works, something that people can get into their lives. That’s what I learned over the past couple of years, that continuous learning is what makes me an engineer. I am not changing into something else, I am something that needs to keep changing, evolving in order to not become stale. I am an engineer.

How to install the CLI Amazon tools on a Mac

Recently I had to connect to an amazon EC2 instance using SSH to do some stuff and realized that there is no manual for the Mac setup, but for Unix-like OS. However, since OS X is Unix based the instructions kinda work but if you’re unaware of some specifics you may get stuck at some point, plus even googling did not help me there. As I managed to make it quite easily, I thought it is my duty to share it with the world. That somewhere on the internet there is a reference allowing you to just copy-paste commands to gain time. Yes, the good engineer is lazy (work for devs too). Not the lazy laziness of not doing anything, but the one that forces you to think something long and well enough so you don’t have to restart it or to do it again and again.


This guide is partially inspired from Amazon’s documentation on the subject

A. Download and Install the CLI Tools

First of all you will need the Amazon CLI tools. Download the tools. The CLI tools are available as a .zip file on this site: Amazon EC2 CLI Tools (aws.amazon.com/developertools/351). You can also download them with the curl utility.

curl http://s3.amazonaws.com/ec2-downloads/ec2-api-tools.zip -o ec2-api-tools.zip

You can, optionnal, verify that the CLI tools package has not been altered or corrupted after publication. For more information about authenticating the download before unzipping the file, see Verify the Signature of the Tools Download.

Unzip the files into a suitable installation directory, such as /usr/local/ec2. Notice that the .zip file contains a folder ec2-api-tools-x.x.x.x, where x.x.x.x is the version number of the tools (for example, ec2-api-tools-

sudo mkdir /usr/local/ec2
sudo unzip ec2-api-tools.zip -d /usr/local/ec2

B. Tell the Tools Where Java Lives

You can verify whether you have Java installed and where it is located using the following command:

which java

You should see the following is example output.


If the previous command does not return a location for the Java binary, you need to install Java. For help installing Java on your platform, go here.

Find the Java home directory on your system. The which java command executed earlier returns Java’s location in the $PATH environment variable, but in most cases this is a symbolic link to the actual program; symbolic links do not work for the JAVA_HOME environment variable, so you need to locate the actual binary. The /usr/libexec/java_home command returns a path suitable for setting the JAVA_HOME variable.


Set JAVA_HOME to the full path of the Java home directory. Set the JAVA_HOME variable to $(/usr/libexec/java_home). The following command sets this variable to the output of the java_home command; the benefit of setting the variable this way is that it updates to the correct value if you change the location of your Java installation later.

export JAVA_HOME=$(/usr/libexec/java_home)

You can verify your JAVA_HOME setting using this command.

$JAVA_HOME/bin/java -version

If you’ve set the environment variable correctly, the output looks something like this.

java version "1.6.0_27"
OpenJDK Runtime Environment (IcedTea6 1.12.6) (6b27-1.12.6-1ubuntu0.12.04.2)
OpenJDK 64-Bit Server VM (build 20.0-b12, mixed mode)

Add this environment variable definition ($JAVA_HOME) to your shell start up scripts so that it is set every time you log in or spawn a new shell. The name of this startup file differs across platforms (in Mac OS X, this file is commonly called ~/.bash_profile and in Linux, it is commonly called ~/.profile), but you can find it with the following command:

ls -al ~ | grep profile

If the file does not exist, you can create it. Use your favorite text editor to open the file that is listed by the previous command, or to create a new file with that name. Then edit it to add the variable definition you set in Step 3.

If the file exist set rights so you can edit it, then edit it using textedit, and change permissions again

sudo chmod 777 ~/.profile
sudo open -a TextEdit ~/.profile
sudo chmod 400 ~/.profile

Verify that the variable is set properly for new shells by opening a new terminal window and testing that the variable is set with the following command.

Note: If the following command does not correctly display the Java version, try logging out, logging back in again, and then retrying the command.

$JAVA_HOME/bin/java -version

C. Tell the CLI Tools Where They Live

The Amazon EC2 CLI tools read the EC2_HOME environment variable to locate supporting libraries. Before using these tools, set EC2_HOME to the directory path where you unzipped them. This directory is named ec2-api-tools-w.x.y.z (where w, x, y, and z are components of the version number). It contains sub-directories named bin and lib.

In addition, to make things a little easier, you can add the bin directory for the CLI tools to your system path. The examples in the Amazon Elastic Compute Cloud User Guide assume that you have done so.

You can set the EC2_HOME and PATH environment variables as follows. Add them to your shell start up scripts so that they’re set every time you log in or spawn a new shell.

To set the EC2_HOME and PATH environment variables on Linux/Unix

Use this command to set the EC2_HOME environment variable. For example, if you unzipped the tools into the /usr/local/ec2 directory created earlier, execute the following command, substituting the correct version number of the tools.

export EC2_HOME=/usr/local/ec2/ec2-api-tools-


If you are using Cygwin, EC2_HOME must use Linux/Unix paths (for example, /usr/bin instead of C:\usr\bin). Additionally, the value of EC2_HOME cannot contain any spaces, even if the value is quoted or the spaces are escaped.

You can update your PATH as follows.

export PATH=$PATH:$EC2_HOME/bin

D. Tell the CLI Tools Who You Are

Your access keys identify you to the Amazon EC2 CLI tools. There are two types of access keys: access key IDs and secret access keys. You should have stored your access keys in a safe place when you created them. Although you can retrieve your access key ID from the Your Security Credentials page, you can’t retrieve your secret access key. Therefore, if you can’t find your secret access key, you’ll need to create new access keys before you can use the CLI tools.

Every time you issue a command, you must specify your access keys using the –aws-access-key and –aws-secret-key (or -O and -W) options. Alternatively, you might find it easier to store your access keys using the following environment variables:

AWS_ACCESS_KEY—Your access key ID
AWS_SECRET_KEY—Your secret access key

If these environment variables are set properly, their values serve as the default values for these required options, so you can omit them from the commands. You can add them to your shell startup scripts so that they’re set every time you log in or spawn a new shell.

You can set these environment variables as follows.

export AWS_ACCESS_KEY=your-aws-access-key-id
export AWS_SECRET_KEY=your-aws-secret-key

E. (Optional) Set the Region

By default, the Amazon EC2 CLI tools use the US East (Northern Virginia) region (us-east-1) with the ec2.us-east-1.amazonaws.com service endpoint URL. To access a different region with the CLI tools, you must set the EC2_URL environment variable to the proper service endpoint URL.

To set the service endpoint URL

To list your available service endpoint URLs, call the ec2-describe-regions command, as shown in the previous section.

Set the EC2_URL environment variable using the service endpoint URL returned from the ec2-describe-regions command as follows.

export EC2_URL=https://<service_endpoint>

If you’ve already launched an instance using the console and wish to work with the instance using the CLI, you must specify the endpoint URL for the instance’s region. You can verify the region for the instance by checking the region selector in the console navigation bar.

For more information about the regions and endpoints for Amazon EC2, see Regions and Endpoints in the Amazon Web Services General Reference.

Manipulate HTML entities in Java


Since my previous website is not available anymore, here is an article I wrote a few months ago about manipulating html entities in Java. I wrote this while working on some webserver providing a newsfeed for League of Legends. So, while i was working on this app I found myself facing those html entities that cannot be processed using the JRE.

So after a couple of hours of binging (Yes I happen to use Bing, deal with it Tongue out), I finally found something, an opensource code providing the HTMLEntities class. A class that allows to manipulate HTML entities in many more ways that i could imagine, and that is really something that helps gaining time when working on complex problematics.

You can find this class here . And do not forget, the good developer is the lazy developer.