Fix "implicit argument passing of super from method defined by define_method() is not supported. Specify all arguments explicitly."
Add a method to get the current memory usage.
Don't allow a bloated job to permanently keep a worker's memory usage high.
Don't check memory after every job.

* From my benchmarks, it takes about 3-4ms to get the
  current memory usage since we shell out since ruby
  doesn't provide us with a system call API for that.
* I don't want to add 3ms to the time it takes to run
  every job.  Adding 3ms to every 10th job isn't so
  bad, though.
Add optional debugging info for this spec, and increase timeout.

Travis needs more time for this spec.
Use proc-wait3, when available, to get memory usage.

It's much, much faster (see the benchmark!).
Move memory monitoring logic to a middleware.

Dan rightfully pointed out that this logic
doesn't really belong in the core worker and is
much more appropriate for a middleware.
Add nicer formatting.
Switch from a multiple to an absolute value.

This is easier to reason about and less prone
to flapping based on the initial memory varying.
Revert the serial worker to what it originally was before this PR.
Switch from proc-wait3 to rusage gem.

proc-wait3 monkey patches `$?` which was causing
problems for poltergeist. rusage is lighter weight
and provides the bit of proc-wait3 we care about.
usage is different on OS X and Linux, apparently.

On my computer, it returns the memory usage in bytes.
On a linux server, I SSH'd into, it returns it in KB.

The OS X (BSD) getrusage man page says it is in bytes.
The Linux man page says it is in KB as of a particular
Linux version.

We deal with this by comparing the `ps` approach to
what rusage returns, and optionally dividing by 1024
if it appears that the amount is coming back in raw bytes.

We also switched everything to KB while we are at it
as that is easier to deal with.
Harden the test against flickering.

I found it was passing in isolation but failing
when run with the whole suite, depending on when
it runs.  It's best to make it relative to the
current memory usage of the process.
Re-order conditional branches for greater clarity.
Fix typo.
Increase timeout on Travis.
Merge pull request #147 from seomoz/fix_memory_issues

Don't allow a bloated job to permanently keep a worker's memory usage high