Skip to content

Instantly share code, notes, and snippets.

View jung-kim's full-sized avatar
🏫
Learning...

jung-kim jung-kim

🏫
Learning...
View GitHub Profile
@jung-kim
jung-kim / keybase.md
Created December 8, 2021 00:35
kebase.md

Keybase proof

I hereby claim:

  • I am jung-kim on github.
  • I am jungkim3627 (https://keybase.io/jungkim3627) on keybase.
  • I have a public key whose fingerprint is 3488 66A1 B31F 7C94 D008 EE42 1E08 CB0E 1E15 54AC

To claim this, I am signing this object:

@jung-kim
jung-kim / bigtableEmulatorTest.go
Created June 20, 2017 17:17
big table emulator test
package main
import (
"context"
"log"
"cloud.google.com/go/bigtable"
)
const (
@jung-kim
jung-kim / zkvetcd.md
Last active July 26, 2023 07:37
ZK vs ETCD

ZK vs ETCD

Quick notes about implementation difference between ZK and ETCD not Paxos vs Raft

Zookeeper

PRO:

  • Industry battle tested, it is the most widely used concensus algorithm implementation
  • Ephemeral nodes, think global lock.
  • Stateful connection to ZK quorum (implies more tight and strong concensus)
@jung-kim
jung-kim / ungit.md
Last active August 30, 2016 11:48
Ungit blog post

Ungit: The easiest way to use git.


I love Git, I think it is better than the invention of slice of bread. Git is a version control system that is elegantly distributed yet beautifully fault tolerant with powerful features. Git is a fundamental development tool that powers my company, GoGuardian, and many other companies and communities. But just like anything in our lives, it is not perfect. It has its own dark side. Git is notorious for having sharp learning curve and complex commands. If you think learning git or explaining git is easy, good for you. You are a better person than I will ever be so go cure cancer. But for most of us peons, git is a challenging beast to wrap our heads around especially for more complex operations. It may possibly be due to the fact that our minds have been abused and in the shape of CVS, SVN or, even worse, clearcase. But I'm not the only one to think this: exhib

@jung-kim
jung-kim / generator_into.js
Created February 7, 2016 06:36
Obvious benefits of generator
// Generator, doing async without promise looking like sync...
function* countWithGenerator(n){
for (var x = 0; x < n; x++) {
yield x
console.log('fetched!')
}
}
function countInteratively(n){
@jung-kim
jung-kim / gist:5269a1d52c41c508c189
Last active February 5, 2016 19:57
ungit test hanging issue
// https://s3.amazonaws.com/archive.travis-ci.org/jobs/107128468/log.txt
travis_fold:start:worker_info
Worker information
hostname: travis-worker-gce-org-prod-5:1f8229d5-9fe3-4eea-a6d2-31f3f6df03ea
version: v2.1.0-44-ge7ef5db https://github.com/travis-ci/worker/tree/e7ef5db4f469f8e76792dee8309e601b6e53e56b
instance: testing-gce-bf03c753-588d-409a-b787-80ec9ab583da:travis-ci-nodejs-precise-1450195912
startup: 21.275166624s
travis_fold:end:worker_info
@jung-kim
jung-kim / map-weakmap-perf.js
Last active December 9, 2022 08:43
Map vs WeakMap performance
"use strict";
let looper = (callback) => {
let n = 2000000;
while (n > 0) {
callback(n);
n--;
}
}
@jung-kim
jung-kim / map.js
Last active February 4, 2016 20:18
map vs obj
var a = {a: 1}
var b = {b: 2}
var map = new Map();
var obj = {};
obj[a] = "***";
obj[b] = "###";
map.set(a, "***");
map.set(b, "###");
@jung-kim
jung-kim / map-perf.js
Last active May 25, 2023 07:01
es6 map vs array vs obj performance test
"use strict";
let looper = (callback) => {
let n = 2000000;
while (n > 0) {
callback(n);
n--;
}
}
23:15:21.633 [main] DEBUG c.y.c.m.s.t.broker.SanityTestClient - Loading configuration from /home/y/conf/cloud_messaging_broker/cloud_messaging_broker.conf
23:15:21.644 [main] INFO c.y.c.m.s.t.broker.SanityTestClient - Start native test 111
23:15:21.645 [main] INFO c.y.c.m.s.t.broker.SanityTestClient - Start native test 111
23:15:21.653 [main] INFO c.y.c.m.s.t.broker.SanityTestClient - Start native test 111
23:15:21.653 [main] INFO c.y.c.m.s.t.broker.SanityTestClient - >>>1
23:15:21.665 [main] DEBUG c.y.c.m.client.admin.CmsAdmin - created: serviceUrl=http://devqa1-broker1.messaging.gq1.yahoo.com:4080, ycaRole=yahoo.cloud_messaging.hosts.broker.env-devqa
23:15:21.916 [main] DEBUG c.y.c.m.client.admin.CmsAdmin - ycaCert=v=1;a=yahoo.cloud_messaging.hosts.broker.env-devqa;h=10.211.18.79;t=1450377535;s=TYmaFmxhSmShsngoWin2Q7mTPpeV2Y2_iAjEumXETWXDdt5bwA3rYzW9RxJE9CMQcEkKlQEZi8NEXUrIeqlaVg--
23:15:22.507 [main] INFO c.y.c.m.s.t.b.NativeSanityTestConsumer - Persistent topic persistent://cms/gq1/devqa1-broker1.mes