This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cabal install scotty | |
cabal install aeson | |
runhaskell server.hs | |
curl -X POST -d '{"jsonrpc":"2.0", "method":"Calc.Add", "params":[10,50], "id":"abc"}' http://localhost:3000/api |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Jamess-MacBook-Pro:cabal-install james$ ghc --version | |
The Glorious Glasgow Haskell Compilation System, version 7.6.3 | |
Jamess-MacBook-Pro:cabal-install james$ cabal --version | |
cabal-install version 1.16.0.2 | |
using version 1.16.0 of the Cabal library | |
Jamess-MacBook-Pro:cabal-install james$ ./bootstrap.sh | |
Using gcc for C compiler. If this is not what you want, set CC. | |
Using /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld instead. | |
Checking installed packages for ghc-7.6.3... | |
deepseq is already installed and the version is ok. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package dingle; | |
@RunWith(Theories.class) | |
public class DingleTest { | |
@DataPoints | |
public static DbDingle[] randDingles() { | |
long now = System.currentTimeMillis(); | |
RandGenerator rand = new RandGenerator(); | |
return rand.randDingles(100).toArray(new DbDingle[100]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<head> | |
<script type="text/javascript" src="jquery.js"></script> | |
<script type="text/javascript" src="mithril.js"></script> | |
<link rel="stylesheet" href="bootstrap.min.css"> | |
<script type="text/javascript" src="bootstrap.min.js" charset="utf-8"></script> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
</head> | |
<body> | |
<div id="main"></div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
INFO[10-31|14:51:31] reporting seed list subsys=bootstrap ipnet=172.17.42.1/16 algo=coreos seeds=[] | |
INFO[10-31|14:51:32] reporting seed list subsys=bootstrap ipnet=172.31.32.153/20 algo=coreos seeds="[172.31.32.153 172.31.32.152 172.31.32.151]" | |
INFO[10-31|14:51:32] reporting seed list subsys=bootstrap ipnet=172.17.42.1/16 algo=coreos seeds=[] | |
SIGQUIT: quit | |
PC=0x430b71 | |
goroutine 22 [syscall, 3 minutes]: | |
runtime.notetsleepg(0x987a20, 0xffffffffffffffff) | |
/usr/local/go/src/pkg/runtime/lock_futex.c:198 +0x46 fp=0x7f6867fa1f40 sp=0x7f6867fa1f10 | |
runtime.signal_recv(0x0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn call-count-by-time-from-file | |
[fname] | |
(as-> fname $ | |
;; read timings from file and split by regex | |
(timings-from-file $) | |
;; group timings based on the URL or RPC call string | |
(group-by #(nth % 2) $) | |
;; create a vector with field order: call string, vector of timings (parsed as ints) | |
(map vector (keys $) (map #(map (fn [x] (. Integer parseInt (second x))) %) (vals $))) | |
;; convert each vector element into four fields: call string, total calls, total time, avg time |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370490/grand-jury-volume-1.pdf | |
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370491/grand-jury-volume-2.pdf | |
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370492/grand-jury-volume-3.pdf | |
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370493/grand-jury-volume-4.pdf | |
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370494/grand-jury-volume-5.pdf | |
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370495/grand-jury-volume-6.pdf | |
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370496/grand-jury-volume-7.pdf | |
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370497/grand-jury-volume-8.pdf | |
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370498/grand-jury-volume-9.pdf | |
https://s3.amazonaws.com/s3.documentcloud.org/documents/1370499/grand-jury-volume-10.pdf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.BufferedReader; | |
import java.io.InputStreamReader; | |
import java.net.HttpURLConnection; | |
import java.net.URL; | |
public class DNSimpleTest { | |
public static final void main(String argv[]) throws Exception { | |
System.setProperty("javax.net.debug", "all"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
cd /usr/local | |
curl -LO 'http://download.oracle.com/otn-pub/java/jdk/8u40-b25/jdk-8u40-linux-x64.rpm' -H 'Cookie: oraclelicense=accept-securebackup-cookie' | |
alternatives --remove java /usr/java/jdk1.7.0_71/jre/bin/java | |
rpm -qa | grep jdk | xargs -l rpm -e | |
rpm -i jdk-8u40-linux-x64.rpm | |
rm -f *.rpm | |
java -version |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
worker_processes 1; | |
events { | |
worker_connections 1024; | |
} | |
http { | |
include mime.types; | |
default_type application/octet-stream; |
OlderNewer