Make region metadata extraction logic a static method.
Add zookeeper and netflix curator as dependencies.

curator is a better zk client; nathan uses it as well.
Not sure what the extracted properties get us.
Use the cdh4 zookeeper.
Add lazy-initialized zookeeper client.

The connection string is hardwired to localhost:2181, which is good enough right up until we can inspect a storm config.

At that point we'll take storm's connection configuration, however we can't even get at that data until the metadata gathering is pushed down into either component start or the scheduler.
Publish region metadata to zookeeper.

This is pretty awful code, but I promise the integration tests still work.
The scheduler pulls region metadata from zookeeper.

Notice it is not yet *publishing* that information; we haven't yet switched the direction data is pushed.  This merely proves we can use ZK to communicate.
Don't specify a default TOPOLOGY_TASKS.

It can only be supplied at topology submission time, so if it would contain the table region count then the submitter would have to count it themselves.

The existence of RegionMapping allows us to cope with region-task count mismatches, so this doesn't break correctness, only (perhaps) performance.
Give TopologyScheduler an HTable client.

Do so with the mockable faux-injection pattern.  It'll all be ripped out when guice hits..
Read region metadata from zookeeper json.
Populate zookeeper with region metadata from scheduler.

This isn't being used yet, but we're proving we can do it.
Mock out ZK client in HBaseComponent as called by TopologyScheduler.
Start moving HBaseComponent.setHTableMetadata to TopologyScheduler.
TopologyScheduler no longer reads metadata from zookeeper.

It still publishes it there.
HBaseComponent fetches region metadata from zookeeper.
HBaseComponent no longer writes to zookeeper.

Instead it only reads from it, in getRegionMetadata (called after start()).

Further, drop the use of getComponentConfiguration().  A subtle quirk in how storm builds its thrift requests prevents properties set directly by the topology submitter from showing up in the map.  However they are still present in the underlying thrift object; we just need to json parse it out ourselves.

This completes the change of direction for flow of region metadata: now it is discovered and published by the scheduler, and consumed by the components.
Make a test pass.
This test doesn't port very cleanly, ditch.
It's unclear where these tests should live.

On reflection, it's not HbaseComponentTest.  I'm not going to lose sleep over ditching them.
Drop unused accessor.