Restricted API for clients during upgrades

When an upgrade is in progress clients will be given an API root that
only allows a small subset of read-only API calls. Other API calls
will return an "upgrade in progress" error.

This helps to ensure that no state changes occur during an upgrade. An
attempt to change state while schema migrations are happening could be
problematic.
Merge pull request #214 from mjs/api-upgrade-mode

Restricted API for clients during upgrades

This is a little rough (with no tests) and is not intended for merging as-is. This demonstrates how the API available to clients can be restricted during upgrades.

With this change in place, most API calls made by clients will fail with an "upgrade in progress" error. A select few API calls used by commands for monitoring will still function. For example:

```
# During upgrade...
$ juju status
environment: local
machines:
  "0":
    agent-state: started
    agent-version: 1.19.5.3
    dns-name: localhost
    instance-id: localhost
    series: trusty
    state-server-member-status: has-vote
services: {}
$ juju deploy local:precise/dummy-source
ERROR upgrade in progress - method Client.EnvironmentGet is not available

# Time passes ... upgrade completes.
$ juju deploy local:precise/dummy-source
Added charm "local:precise/dummy-source-0" to the environment.
```