Skip to content

Instantly share code, notes, and snippets.

@jordi-rc
jordi-rc / main.go
Created September 24, 2019 20:18 — forked from seafooler/main.go
Concurrency Pattern in "Golang in Action": pool
// This sample program demonstrates how to use the pool package
// to share a simulated set of database connections.
package main
import (
"io"
"log"
"math/rand"
"sync"
"sync/atomic"
@jordi-rc
jordi-rc / web-servers.md
Created August 15, 2018 21:00 — forked from willurd/web-servers.md
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000