Skip to content

Instantly share code, notes, and snippets.

@BlancosWay
BlancosWay / System Design.md
Created November 11, 2018 07:32 — forked from vasanthk/System Design.md
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@BlancosWay
BlancosWay / jessfraz.md
Created July 30, 2018 03:29 — forked from acolyer/jessfraz.md
Containers, operating systems and other fun things from The Morning Paper
#!/bin/bash
JQPATH=$(which jq)
if [ "x$JQPATH" == "x" ]; then
echo "Couldn't find jq executable." 1>&2
exit 2
fi
set -eu
shopt -s nullglob
@BlancosWay
BlancosWay / docker-registry-caching-proxy.conf
Created June 25, 2018 17:29 — forked from etuttle/docker-registry-caching-proxy.conf
NGINX config for a caching proxy that sits in front of a docker registry
upstream docker-mirror-upstream {
server upstream.example.com;
}
proxy_cache_path /var/lib/docker-mirror/cache levels=1:2 max_size=10g inactive=48h keys_zone=cache:10m;
server {
listen 80 default_server;
listen 443 ssl default_server;
@BlancosWay
BlancosWay / anaconda-tensorflow-keras.txt
Created March 8, 2018 22:50 — forked from jeffgreenca/anaconda-tensorflow-keras.txt
Anaconda Keras / TensorFlow environment setup
Install TensorFlow (CPU), Keras, and some other tools to a new anaconda environment.
Open Anaconda Prompt
conda create --name tensorflow35 python=3.5
conda activate tensorflow35
conda install jupyter
conda install scipy
conda install spyder
pip install tensorflow
@BlancosWay
BlancosWay / FileClient.java
Created June 7, 2017 07:14 — forked from CarlEkerot/FileClient.java
Simple java file transfer
package client;
import java.io.DataOutputStream;
import java.io.FileInputStream;
import java.io.IOException;
import java.net.Socket;
public class FileClient {
private Socket s;
@BlancosWay
BlancosWay / explanation.md
Created March 22, 2017 18:13 — forked from ThatRendle/explanation.md
Why I am not a fan of Apache Kafka

Update, September 2016

OK, you can pretty much ignore what I wrote below this update, because it doesn't really apply anymore.

I wrote this over a year ago, and at the time I had spent a couple of weeks trying to get Kafka 0.8 working with .NET and then Node.js with much frustration and very little success. I was rather angry. It keeps getting linked, though, and just popped up on Hacker News, so here's sort of an update, although I haven't used Kafka at all this year so I don't really have any new information.

In the end, we managed to get things working with a Node.js client, although we continued to have problems, both with our code and with managing a Kafka/Zookeeper cluster generally. What made it worse was that I did not then, and do not now, believe that Kafka was the correct solution for that particular problem at that particular company. What they were trying to achieve could have been done more simply with any number of other messaging systems, with a subscriber reading messages off and writing

@BlancosWay
BlancosWay / 00. tutorial.md
Created March 9, 2017 19:08 — forked from maxivak/00. tutorial.md
Importing/Indexing database (MySQL or SQL Server) in Solr using Data Import Handler
@BlancosWay
BlancosWay / bk-tree.hpp
Created February 14, 2017 22:02 — forked from eiiches/bk-tree.hpp
BK-tree implementation in C++
/*
* BK-tree implementation in C++
* Copyright (C) 2012 Eiichi Sato
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
@BlancosWay
BlancosWay / .gitignore
Created February 6, 2017 16:58 — forked from miku/.gitignore
Word segmentation in a nutshell.
*gz