Monday, August 01, 2016

I'm using lein ancient to check version of dependencies, it provides a handy way to upgrade all libraries:

 $ lein ancient upgrade :interactive
if you want to skip tests:
 $ lein ancient upgrade :interactive :no-tests
add :check-clojure to upgrade clojure version as well.

Tuesday, August 02, 2016

added search function to blog contents (search box at the bottom of this page), now it's easier to find stuffs.

to change docker0 bridge cidr, the old way is add DOCKER_OPTS="–bip=" to /etc/default/docker

but it's not working anymore after upgraded to ubuntu 16.04, of course it's because of systemd.

update /lib/systemd/system/docker.service, add EnvironmentFile line and $DOCKER_OPTS:

ExecStart=/usr/bin/docker daemon $DOCKER_OPTS -H fd://


$ systemctl daemon-reload
$ service docker restart

Friday, August 05, 2016

returning to PHP, trying to catch up with new things...

PHP Box can pack your app as a phar, like a fat-jar, I found it because Symfony installer is using it.

after downloaded the installer, create a new symfony project is as simple as:

$ symfony new my_project 2.8


$ symfony new my_project lts

and running the app is easy too:

$ cd my_project
$ php app/check.php
$ php app/console server:run

I was like: "wow ..."

for VM, there is Laravel Homestead to help you quickly create a development machine, really cool.

Saturday, August 06, 2016

finally decided learn some react, I'm reading this: Hacking with React

Saturday, August 13, 2016

to resolve boot-clj repl cider problem:

WARNING: CIDER's version (0.13.0-snapshot) does not match cider-nrepl's version (nil). Things will break!

add these to build.boot:

(require 'boot.repl)

(swap! boot.repl/*default-dependencies*
       concat '[[cider/cider-nrepl "0.13.0-SNAPSHOT"]])

(swap! boot.repl/*default-middleware*
       conj 'cider.nrepl/cider-middleware)

Saturday, August 20, 2016

I'm busy finding a job, nothing much to update, some notable things from last couple weeks:

about MySQL: Why Uber Engineering Switched from Postgres to MySQL and re: Why Uber Engineering Switched from Postgres to MySQL

one interesting thing is Schemaless, their custom designed datastore built on top of MySQL.

Google's QUIC protocol: moving the web from TCP to UDP

I'm more interested in UDP than TCP, because of Joe Armstrong?

This is a really interesting one, but I don't have time to take a look yet.

about tcp: TCP Puzzlers and discussion on hacker news

Why do CPUs have multiple cache levels?

the best comment found on hacker news by jgord:

When my son was 5 or 6 I had a great discussion about salt containers - the little one you have on the table, the big packet in the pantry, the pallet that gets delivered to the supermarket, the vast piles of salt at the salt mine, and all that salt in the ocean.

Next time we had an egg and he wanted salt I scratched my head and asked him what should we do .. take our egg to the supermarket or we could take a pack lunch to the beach, and maybe wave the egg around in the water ? "No daddy, remember, we have a little salt cache in the kitchen." hehe.

Java 8 Top Tips

but you don't need java when you have kotlin:

New – AWS Application Load Balancer

supports http/2 and websocket, I don't have resources to check this thing out now, but layer 7 load balancing is definitely needed.

some history: Journey to HTTP/2

and the best comment from hackernews by morecoffee:

I work with HTTP/2 daily, and there are some pain points when running at high speeds:

- Headers are still head of line blocking. You must synchronize sending them to maintain the HPACK table state. At a high number of requests per second, this is a bottle neck

- Running over TLS is CPU bottleneck since encrypted messages are sequential. We get around this by making multiple TCP connections.

- Long lived HTTP/2 connections will often break because of NAT's (home internet), or changing IP address (mobile). A single dropped packet kills throughput for highspeed links too.

All of these are addressed by the QUIC protocol. I suspect that eventually HTTP/2 will be last major protocol over TCP because of most of the aforementioned problems come from running over it.

(QUIC is mentioned)

and another http/2 related: Real–world HTTP/2: 400gb of images per day

Go 1.7 is released, mainly compiler and performance optimizations, I like that. maybe I'll code some Go later this year.

related: Looking at your program's structure in Go 1.7

a very funny blog post about the whole microservices and containerization thing: It’s The Future

I'm using docker and I agree most applications don't need containers.

I had an job interview weeks ago, when I heard the interviewer mentioned docker inside docker, I was like "wow..."

couple scalability article:

paypal one is nice, more details: squbs: A New, Reactive Way for PayPal to Build Applications

talking about reactive, I'm going to read this book: Functional Reactive Programming

even pure java is very high performance, check this article from 2013: 135 Million messages a second between processes in pure Java, and discussion on hacker news

jvm rocks, someone mentioned this slide: Shenandoah GC: Java Without The Garbage Collection Hiccups, no gc, I wanna see how it does that.

some interesting tools/libries:

Monday, August 22, 2016

heard about few new libraries when reading this reddit thread: What does your dream Clojure stack look like?

but why so many cljs libraries?

a blog post about go: What Golang Is and Is Not and discussion on hacker news

I too think go is more suitable for scripting.

Tuesday, August 23, 2016

saw a very old link from hacker news: The Windows 95 User Interface: A Case Study in Usability Engineering

I like windows classic UI, so consistency and solid.

after reading that I switched my ubuntu to use gnome:

sudo apt-get install gnome-session-flashback

log out, on login box, click the ubuntu icon and select gnome flashback (metacity), then login.

I was going to install this theme: Windows Classic GTK 3 (just un-tar it to /usr/share/themes/), but found it doesn't look good.

however, gnome flashback is much faster than unity, I think I'll stick with it.

to customize, install few packages: gnome-tweak-tool, dconf-editor, gnome-search-tool

to add application shortcuts to the top panel, you'll need to use alt + right click

to speed up, open dconf-editor, follow the path: org > gnome > metacity, and uncheck:


when I used alt + tab under unity, it's so slow. now it switches instantly, so much better.

Wednesday, August 24, 2016

when I clicked on a link from my news site, this pge shows up.

I heard the vulnerbility before, but never remember to update the site. thanks to the page I just added rel="noopener noreferrer" to my _blank links.

read the blog I Don't Need No Stinking API - Web Scraping in 2016 and Beyond, don't like it but learned a few things for selenium, especially antigate.

when I visited local library, saw a bunch of perl books. I read some chapters randomly, I kinda want to pick up perl again.

I still want to finish Higher-Order Perl

I think perl is perfect for devops, but the only link I found from recently is A Perl toolchain for building micro-services at scale

will try mojolicious as it got so many positive comments.

Wednesday, August 31, 2016

still couldn't find connection between hoplon and backend unless using castra, but I don't want to use it.

couldn't decide which one to try: rum or quiescent.

and onyx is complicated.

I may need to take a break from clojure.

reading Go in Action and The Go Programming Language now.

didn't have time to finish them before, and will put reading notes online later.

docker is under fire since v1.12 with swarm:

I agree that docker shouldn't fight kubernetes and should give up swarm.

Blog Archives

Search Blog: