Sunday, October 1, 2017

39. PZU Warsaw Marathon

Somehow 3 years had to pass since my last marathon in Lodz in 2014.

This time I registered in the marathon very spontaneously for several reasons:

1. I wanted to remind myself how is it to attend a marathon, feel the atmosphere and cheer of viewers and to race with others

2. Last 3 months I had off work and sedentary lifestyle and I wanted to verify if it brought any positive effects on me and how it would affect my score in a marathon. During these months I have run a lot and long distances (20-30km) so the effect should be visible.

Indeed, this brought positive results and I've beaten my last record by 20min and finished with net time of 04:05:36

The weather also helped a bit. It was perfect for running: not too cold, not too hot, cloudy and a bit pluvial.

Of course, I have tracked it.

My condition was so good that on the last meters I could push more. I remember the previous marathon when my legs failed more after 35km and I have almost crawled to the finish.

Below are some photos to commemorate that day.

Sunday, June 18, 2017

Confessions of a young father programmer

This is a first blog entry after a long absence.
A lot of stuff was happening recently. Let me explain a bit why it was difficult to force myself to write.

Mostly, this is due to my son who was born in June 2016.
Before my sun was born I heard from many other young fathers that this will completely turn my life upside down and i have to admit - nothing is as it used to be anymore, but that's completely fine. Having a child is as much rewarding as exhausting sometimes :)

Anyway, I'm trying to get myself together and keep up with all the new techs that came to my ear since then but I did not have time to learn more, such as non-blocking, async servers ( e.g. ratpack), JavaRX, JavaScript frameworks (like React), Big Data ( Spark, Flink, Flume, .. do we have any more "F"-like fancy names here?) and Spring ecosystem (Spring Boot and latest Spring 4 new features).

This is an instant fight with self-discipline, planning and.. changing plans when all depends on our "Little Chief".

I know if I wanted to do them all I would do none, so I just thought to concentrate on a single thing first. Just by chance I heard about a contest called "Get Noticed!" (explanation in Polish:
The rule is simple. Each participant has to blog at least twice a week during 3 moths. Every week at least one post should be about the progress in open source project which author should contribute to on Github.
I decided to give it a try and started a brand new blog: where I'm going to write about Cloud related topics and describe my pet project - Servlerless Reservation System.

As I am working from home for over 1.5 year already, it is sometimes hard to sit down and concentrate when all the attention is dragged by a baby screaming in the second room or my wife dragged to tears by him and seeking help from me. What makes it ever worse is the kind of remote work I do which is very demanding (in CrossOver with a very special model of work, more about it in separate blogpost)
The new remote job is also another reason of why I can hardly find some spare time off-work to write anything.
In addition other non-programming projects has taken all my free time. That's it, enough of excuses :)

I wonder how other young fathers programmers went through this first period and keep on going, self-organize and stay productive.
I'm working on the best model now. When I find the silver bullet I will definitely write about it. Hopefully it would help other fathers like me.
I would also read with pleasure experiences and tips from others.
So far I came into the following things that seem to work, but I have problems to turn them into habits:

1. Get up at 6-7 am yet before the kid gets up and starts "catching in the rye". My kid usually wakes up around 9-10. That gives me 2-3h of undisturbed working. After that we usually play and go for a walk until 12.00 and then eat lunch.

2. Listen to podcasts
When we walk I usually listen to some podcasts on my mobile when my boy usually takes a nap, the same when I run.

3. I get back to work at about 1pm (after lunch) or sometimes I run before lunch, then eat a bit later and get back to work at about 2-3pm

4. I try to split my 40h work into 6h * 6 + 4h. It means I have to work on Saturdays and sometimes Sundays, but I noticed that working over 8h a day influences my motivation and clear thinking very much.

* 8h means real hours of work, no coffee, chats, lunch, playing ping-pong, etc.

5. Do sport
As I already mentioned, I run 5-6km twice a week + 1h swimming once a week.
Spreading it every second day in a week looks like a good proportion to cure myself from back and arm pains. It may be first symptoms of RSI but I need to find time to visit a doctor finally to look at it.
I found keeping to this plan very important. I used to have weeks without any move at all, but this only resulted in bad mood, nervousness, pains in body, deprived sleep.

6. Sleep
At least 6-7h of sleep is a minimum to sustain for me. Without it I'm depressed, slow-thinking and physically exhausted.
I've noticed that it is important to go to sleep and get  up in regular hours.
Before I was a night-awl. Recently I have an impression that I'm more productive if I go to bed earlier and wake up earlier.

However, I will repeat again, this plan is extremely hard to make it a habit so far. Sometimes it's enough to stay overnight on an important task to ruin whole week plan.
If I stay late, I cannot wake up early, then I start work later and stay late again (because there are always so many urgent tasks to complete that day) and go to bad late again.. and the circle goes on.

I know everyone has own tricks to stay productive and keep the right work-life balance. Please share yours in comments if you like.

Monday, June 1, 2015

Devoxx4Kids PL

Another edition of devoxx4kids has just passed in Warsaw and again great thanks to organizers. I was just a volunteer and felt some exhaustion but the effort of organizers must have been amazing.

Last year i was taking care of 8-years-old group but this year i wanted a difference and became a teacher of blockly (similar to scratch) for 10-years-old group.

It was quite fun to see the difference of approaches and progress among children. When the rest of the group was in the beginning of exercise, 2 girls were clearly ahead and finishing it. As they confessed later, they already learned scratch before and this clearly shows a need for events like this. Not every school reserves sufficient amount of time for IT education and programming so important in the times we live, even less interest i observe among girls. This results later on in how many women land in IT jobs (very little).

My lecture took only 2 hours so i had rest of the day to see around the other groups and workshops and i come to the conclussion that the most hard groups are the youngest. They very easily loose patience, get tired and run they own path of doing things far away from what the teachers wanted them to learn. But this is not always bad. After all they came here to have some fun and as long as they try some programming, even not according to the teacher‘s plan, i think it‘s good.

The 12-years-old were the most quite and concentrated on what teacher told them to do. Isn‘t it the effect of education system over years that teaches this passiveness and taking what teacher says for granted and staying away from self-exploratory? I hope this is not the case. Thanks to such events children have chance to try their own ideas and noone shold tell them to wander away from the plan.

Seeing a few different lectures like Lego Mindstorms, 3D printers, Scratch, App Inventory  i must say the teachers did realy good job, even if some have mostly technical background and luck experience in working witch children (me included) the way they leaded was very professional.

I know from a back-stage conversations with ordanizers that the whole project of devoxx4kids started as a group of friends who wanted to make a workshop for their own kids last year but since then the event got so much interest that people from other cities than warsaw came in touch with them to organize an event in their town.

I though myself to start it in Lodz. Afer some observations this year and with some help from organizers in Warsaw i think the project has chance to succeed.
Stay tuned..

And some movies:

Wednesday, May 20, 2015

Atmosphere Conference, Cracow 18-19 May 2015

This is my brain dump from Atmosphere Conference in Cracow 18-19 May 2015
Only most important terms to memorize and google about.

JAMIE WINSORBuilding And Releasing A Massively Multiplayer Online Game A nice talk about caveats of game server internals and road of choosing right technology for online platform which is Erlang (elixir to be  precise), a video of the presentation is online

DUNCAN DAVIDSONWhat we've learned from writing dozens of polyglot micro services
Wunderlist jungle of polyglot micro services
Json over Http2
Json over amqp
Spot instances aws

MILEN DYANKOVMicroservices and Modularity or the difference between treatment and cure!
Great presentation of refactoring Oracle demo EJB application into modular according to Uncle Bob`s "clean architecture" principles


PIOTR STAPP, MARCIN PRZEKOPDevOps in mBank - lesson learned 
Wcf connection (client-server)
Nuget CI
Splunk for log mgmt.


LEV POPOVService Operations Evolution at Spotify

KONRAD MALAWSKINeed for Async: In pursuit of scalable internet-scale applications
Concurrent 《 lock free 《 block free
CAS compare and set Blocked Queue lock free
ConcurrentLinkedQueue wait free

C10k 10000 concurrent connection problem of scalability - epool function in linux

Distributed systems:
- latency enhancement by backup requests
- avoided duplicate load by combined requests

 ANDRZEJ GRZESIKThe path to repeatable builds


TOMASZ NURKIEWICZHystrix – managing failures in distributed systems

Hystrix dashboard
Turbine for multiple instances monitoring and aggregating to single stream

KASZ SZYDLOEnabling Continuous Delivery    Book worth reading:

MARCIN BAZYDLOStrongly Typed Logs - Journeyman's story 

Kafka, Redis + ELS stack
Semantic logs
Elastic search depends on Lucene schema, version is important in the logs cause db supports many versions of the app throught lifespan
Zipco for distributed request tracing
Emaze - presentation editor

SETH VARGOThe 10 Myths of DevOps 
Google's April Fool's Day spot: Google Actual Cloud


Monday, July 14, 2014

Copy Android Kindle books to PC

In my previous post I explained how to use ADB utility to copy files from Android phone to PC.
If you happened to use Kindle eBook reader on Android and wondered where it stores books bought in Amazon, then it's here:


File extension used by Amazon books is .prc
You can copy the file to PC using command like:

adb pull /sdcard/Android/data/ /tmp/

You can also push .prc books to Android similar way:

adb push /tmp/mybook.prc /sdcard/Android/data/

If you bought the book from Amazon then it will be secured with DRM. This is easy to remove, some people do it even though illegal.

Backup Android photos with ADB

During my vacation a few days ago my Android phone (Samsung Galaxy S1) crashed unexpectedly.
I can only imagine that the reason was too little free sdcard space, but I'm not sure.
It happened to me already the second time and the first time I fixed it so that I rebooted the phone in recovery mode (reboot with pressing POWER + VOLUME UP + MENU buttons) and did factory reset, obviously loosing all data which was not backed up on the phone.
I think it could work as well this time, but the problem is I had plenty of nice picks done on vacation on my phone and would like to rescue them :)

This is what I did:

  1. Reboot phone in recovery mode (as described previously)
  2. Connect phone to PC with USB
  3. Run adb tool to restore photos to PC

I am using Ubuntu on my PC but the following would work similar on other OS. The only thing you will probably need to change is path to the temp folder on PC.

  • Run adb as root so that you can mount your sdcard in next steps

# adb root

  • Mount sdcard. Maybe you don't' need this step and your sdcard is already mounted. Mine was not.

# adb shell

then in shell type:

# mount /sdcard

Now you can list content of sdcard

# ls /sdcard

Among files on the list I could see folder DCIM
This is where camera photos and films are saved so I grab this to my temp folder.

  • Copy photos and videos to temp folder on PC

First exit shell:

# exit

Then copy:

# adb pull /sdcard/DCIM /tmp

This can take some of your drive space so be prepared otherwise the command will exit with message:
"No space left on device"

Thursday, June 5, 2014

RaspBMC Remote Desktop

First of all, although possible to connect to setup remote desktop on RaspBMC it works awfully slow and probably does not bring a other usability than navigating through UI.
Video simply hangs so it's impossible to watch any.

These are the steps to set it up:
1.  Open your favorite text editor and save the script,

e.g. command : nano vncserver
and paste this script:


case $1 in
    if [ -f /var/run/ ] ; then
      echo "VNC server is already running"
      initctl stop xbmc
      sudo vnc_dispmanx 2>/dev/null &
      echo $! | sudo dd of=/var/run/
      initctl start xbmc
    if [ -f /var/run/ ] ; then
      sudo kill -TERM $(cat /var/run/
      sudo rm /var/run/
      echo "VNC server is not running"
    echo "Usage $0 start|stop"

2. chmod +x vncserver

3. sudo mv vncserver /usr/local/sbin

4. vncserver start
If you want to check if it's running, check if vnc_dispmanx has the default VNC port open (5900)
pi@raspbmc:~$ sudo netstat -lnptu |grep vnc
tcp        0      0  *               LISTEN      3687/vnc_dispmanx

tcp6       0      0 :::5900                 :::*                    LISTEN      3687/vnc_dispmanx

5. When you're done, you should turn it off, as it's quite CPU hungry: 

vncserver stop

Connecting with VNC viewerFrom Ubuntu you can use vncviewer:

sudo apt-get install vncviewer