Skip to content

Instantly share code, notes, and snippets.

@yawnt
yawnt / monad_error.scala
Created August 10, 2017 17:55 — forked from etorreborre/monad_error.scala
Why is MonadError helpful?
/**
* Let's say I can read things from a "Store"
*/
trait Store[F] {
def read(path: Path): F[String]
}
/**
* Now I want to read more specific things, like a Configuration
*

This histogram shows the distribution of GitHub Gist API response times (in milliseconds) for a sample of 10,000 requests as observed by bl.ocks.org.

The distribution roughly follows a log-normal distribution, which is unsurprising for a complex process that has multiple independently-random sources of delay. The mode response time was in the range 120-140ms, while the median response time was 206ms. The middle 80% of requests were in the range 114-527ms. About 11% of requests took longer than 500ms, and 5% of requests took longer than one second. (The rightmost bin in the histogram includes these long requests.)

Since API endpoints vary dramatically in their computational cost, the distribution of response times is likely multimodal. In this dataset, 96% of requests were for a single gist (/gists/42), while the remaining 4% of requests were to list a user’s gist (/users/fred/gists). By separating the API r

@yawnt
yawnt / answer
Created October 27, 2012 19:34 — forked from sadasant/answer
jitsu's answer
sadasant@sadasant ~/code/heroku/Pong
jitsu deploy
info: Welcome to Nodejitsu sadasant
info: jitsu v0.10.3-1, node v0.8.9
info: It worked if it ends with Nodejitsu ok
info: Executing command deploy
info: Analyzing application dependencies in node app.js
info: Creating snapshot 0.0.1-1
info Uploading: [== ] 11%
error: Error running command deploy