Remove dangerous access to record using element/2

It seems to incorrectly store the version when {version, views} was
desired.
Add ping_quorum and get_peer_info support calls

riak_ensemble_peer:ping_quorum/1 checks an ensemble for an active
quorum, returning the current ensemble leader as well as the list of
peers supporting the current quorum.

riak_ensemble_manager:get_peer_info/2 returns information about a
given ensemble peer: the peer's current FSM state, if it is or is not
trusted, and it's current epoch.
Merge pull request #26 from basho/feature/ensemble-commands

Add ping_quorum and get_peer_info support calls

Reviewed-by: engelsanchez
Centralize settings/timeouts into a single module

This commit moves all hardcoded settings/timeouts into the new
riak_ensemble_config module. This not only makes it easier to quickly
look up the various values, but is also the first step in making many
of these settings user configurable.
Make several hardcoded settings user configurable

As a first pass, we directly query configurable settings directly from
the application environment variables. In the future, we should profile
and see if the added contention against the application ETS table matters.
If so, we could consider caching settings using a approach such as the
one used by sidejob_config.
Merge pull request #28 from basho/feature/configurable

Make several hardcoded settings user configurable

Reviewed-by: reiddraper
Add handle_down/4 cb for backend behavior

Handle 'DOWN' messages in the peer and callback into the backend
handle_down/4 function.

Part of a fix for basho/riak_kv#985
only issue client ops if ensembles enabled
fix 'DOWN' message handling in peer
Merge pull request #31 from basho/optimization/only-issue-cmd-if-enabled

only issue client ops if ensembles enabled

Reviewed-by: engelsanchez
Merge pull request #33 from basho/bugfix/monitor-vnode-proxy

Add handle_down/4 cb for backend behavior

Reviewed-by: lordnull
Add ready to start backend callback

This will be used, for example, to indicate that Riak KV ensemble peers
should wait for the riak_kv service to be up before starting to avoid
some nasty races.
Merge pull request #24 from basho/refactor/should-be-record-field

Fix root ensemble initial record

Reviewed-by: andrewjstone
Merge pull request #32 from basho/feature/dont-start-peer-until-backend-ready

Add ready to start backend callback

Reviewed-by: lordnull
Step down if local_put fails in leader worker

In riak_ensemble_peer:put_obj/4 when local_put/4 fails, step down by
sending a 'request_failed' message to the leader.