Consistently use bytes for memory statistics

For some reason, stat_collector assumed rss was reported in kilobytes
instead of bytes and multiplied it by 1024.  The rest of the code then
started to divide the 'used_memory_in_bytes' by 1024 to really get bytes
back.  Very odd.

This change simply removes the hacks that multiply and divide to get
expected data.
Make memory reported match cgroup usage data

The DEA was reporting 'used_memory_in_bytes' as the RSS returned from
warden.  RSS, however, is not what cgroup uses when checking container
memory limits so it's inappropriate memory statistic to report to end
users via cf stats.

The Linux cgroup implementation reports container memory usage in
memory/memory.usage_in_bytes and calculates this by adding
memory/memory.stat:cache and memory/memory.stat:rss so this change will
introduce the same logic to the DEA.  Instead of using cache and rss,
however, total_rss and total_cache will be used as it accounts for child
containers when present.
Merge branch 'used-is-rss-plus-cache' of https://github.com/sykesm/dea_ng into sykesm-used-is-rss-plus-cache

Signed-off-by: Michael Maximilien <maxim@us.ibm.com>

Conflicts:
	lib/dea/starting/instance.rb
	lib/dea/stat_collector.rb
	spec/unit/starting/instance_spec.rb
	spec/unit/stat_collector_spec.rb
Only update routes for instances that are running

If an update message is processed by a an instance that is not in the
proper state, a router registration message may get published with port
0 as the target port.  This is, obviously, unreachable. :)

This change will prevent updates to app instances that aren't in an
appropropriate state.  When app update messages are skipped because of
incorrect state, the app instance version remains at the old level so
the health manager can detect the problem and correct it.
Refactor instance uri update

Signed-off-by: Phan Le <ple@pivotallabs.com>
Auto-merge remote-tracking branch 'upstream/master'