Skip to content

Instantly share code, notes, and snippets.

View mattroberts297's full-sized avatar

Matt Roberts mattroberts297

View GitHub Profile
@mattroberts297
mattroberts297 / SprayRoutingPitfall.scala
Created August 11, 2014 10:41
Spray Routing Pitfall
def route = path("foo") {
get {
complete {
println("In foo") // Run on request, not run at start up :-).
BodylessHttpResponse(OK)
}
}
} ~ path("bar") {
get {
println("In bar") // Run at start up, not run on request :-(.
$ traceroute lodash.com
traceroute to lodash.com (83.137.145.21), 64 hops max, 52 byte packets
1 192.168.1.254 (192.168.1.254) 3.152 ms 2.516 ms 2.952 ms
2 217.32.147.4 (217.32.147.4) 10.234 ms 12.651 ms 10.333 ms
3 217.32.147.46 (217.32.147.46) 12.023 ms 11.620 ms 10.780 ms
4 213.120.156.194 (213.120.156.194) 14.348 ms 14.435 ms 13.077 ms
5 217.41.168.249 (217.41.168.249) 12.791 ms 12.756 ms 11.999 ms
6 217.41.168.109 (217.41.168.109) 12.342 ms 12.376 ms 12.919 ms
7 109.159.249.248 (109.159.249.248) 12.970 ms
acc2-te0-0-0-20.l-far.21cn-ipp.bt.net (109.159.249.220) 12.824 ms