You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@aurora.apache.org by ma...@apache.org on 2014/10/17 22:50:16 UTC

git commit: Add client cluster configuration docs.

Repository: incubator-aurora
Updated Branches:
  refs/heads/master 465ff3419 -> 5c378ac21


Add client cluster configuration docs.

Bugs closed: AURORA-846

Reviewed at https://reviews.apache.org/r/26834/


Project: http://git-wip-us.apache.org/repos/asf/incubator-aurora/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-aurora/commit/5c378ac2
Tree: http://git-wip-us.apache.org/repos/asf/incubator-aurora/tree/5c378ac2
Diff: http://git-wip-us.apache.org/repos/asf/incubator-aurora/diff/5c378ac2

Branch: refs/heads/master
Commit: 5c378ac21abebd2848b2d520bd01d835a9e918fe
Parents: 465ff34
Author: Joshua Cohen <jc...@twopensource.com>
Authored: Fri Oct 17 13:50:08 2014 -0700
Committer: Maxim Khutornenko <ma...@apache.org>
Committed: Fri Oct 17 13:50:08 2014 -0700

----------------------------------------------------------------------
 docs/client-cluster-configuration.md | 71 +++++++++++++++++++++++++++++++
 docs/client-commands.md              |  5 ++-
 docs/developing-aurora-client.md     | 20 ++++++---
 3 files changed, 89 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/5c378ac2/docs/client-cluster-configuration.md
----------------------------------------------------------------------
diff --git a/docs/client-cluster-configuration.md b/docs/client-cluster-configuration.md
new file mode 100644
index 0000000..86bd17c
--- /dev/null
+++ b/docs/client-cluster-configuration.md
@@ -0,0 +1,71 @@
+# Client Cluster Configuration
+
+A cluster configuration file is used by the Aurora client to describe the Aurora clusters with
+which it can communicate. Ultimately this allows client users to reference clusters with short names
+like us-east and eu. The following properties may be set:
+
+  **Property**             | **Type** | **Description**
+  :------------------------| :------- | :--------------
+   **name**                | String   | Cluster name (Required)
+   **slave_root**          | String   | Path to mesos slave work dir (Required)
+   **slave_run_directory** | String   | Name of mesos slave run dir (Required)
+   **zk**                  | String   | Hostname of ZooKeeper instance used to resolve Aurora schedulers.
+   **zk_port**             | Integer  | Port of ZooKeeper instance used to locate Aurora schedulers (Default: 2181)
+   **scheduler_zk_path**   | String   | ZooKeeper path under which scheduler instances are registered.
+   **scheduler_uri**       | String   | URI of Aurora scheduler instance.
+   **proxy_url**           | String   | Used by the client to format URLs for display.
+   **auth_mechanism**      | String   | The authentication mechanism to use when communicating with the scheduler. (Default: UNAUTHENTICATED)
+
+#### name
+
+The name of the Aurora cluster represented by this entry. This name will be the `cluster` portion of
+any job keys identifying jobs running within the cluster.
+
+#### slave_root
+
+The path on the mesos slaves where executing tasks can be found. It is used in combination with the
+`slave_run_directory` property by `aurora task run` and `aurora task ssh` to change into the sandbox
+directory after connecting to the host. This value should match the value passed to `mesos-slave`
+as `-work_dir`.
+
+#### slave_run_directory
+
+The name of the directory where the task run can be found. This is used in combination with the
+`slave_root` property by `aurora task run` and `aurora task ssh` to change into the sandbox
+directory after connecting to the host. This should almost always be set to `latest`.
+
+#### zk
+
+The hostname of the ZooKeeper instance used to resolve the Aurora scheduler. Aurora uses ZooKeeper
+to elect a leader. The client will connect to this ZooKeeper instance to determine the current
+leader. This host should match the host passed to the scheduler as `-zk_endpoints`.
+
+#### zk_port
+
+The port on which the ZooKeeper instance is running. If not set this will default to the standard
+ZooKeeper port of 2181. This port should match the port in the host passed to the scheduler as
+`-zk_endpoints`.
+
+#### scheduler_zk_path
+
+The path on the ZooKeeper instance under which the Aurora serverset is registered. This value should
+match the value passed to the scheduler as `-serverset_path`.
+
+#### scheduler_uri
+
+The URI of the scheduler. This would be used in place of the ZooKeeper related configuration above
+in circumstances where direct communication with a single scheduler is needed (e.g. testing
+environments). It is strongly advised to **never** use this property for production deploys.
+
+#### proxy_url
+
+Instead of using the hostname of the leading scheduler as the base url, if `proxy_url` is set, its
+value will be used instead. In that scenario the value for `proxy_url` would be, for example, the
+URL of your VIP in a loadbalancer or a roundrobin DNS name.
+
+#### auth_mechanism
+
+The identifier of an authentication mechanism that the client should use when communicating with the
+scheduler. Support for values other than `UNAUTHENTICATED` is currently not available, however work
+is [in progress](https://issues.apache.org/jira/browse/AURORA-720) to add federated authentication
+to Aurora which will allow for more robust configuration of client/scheduler authentication.

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/5c378ac2/docs/client-commands.md
----------------------------------------------------------------------
diff --git a/docs/client-commands.md b/docs/client-commands.md
index f61fc66..0424e8f 100644
--- a/docs/client-commands.md
+++ b/docs/client-commands.md
@@ -57,7 +57,7 @@ Aurora Jobs.
 Cluster Configuration
 ---------------------
 
-The client must be able to find a configuration file that speciies available clusters. This file
+The client must be able to find a configuration file that specifies available clusters. This file
 declares shorthand names for clusters, which are in turn referenced by job configuration files
 and client commands.
 
@@ -87,6 +87,9 @@ A configuration for a leader-elected scheduler would contain something like:
 }]
 ```
 
+For more details on cluster configuration see the
+[Client Cluster Configuration](client-cluster-configuration.md) documentation.
+
 Job Keys
 --------
 

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/5c378ac2/docs/developing-aurora-client.md
----------------------------------------------------------------------
diff --git a/docs/developing-aurora-client.md b/docs/developing-aurora-client.md
index e1b2ccd..b9912bc 100644
--- a/docs/developing-aurora-client.md
+++ b/docs/developing-aurora-client.md
@@ -1,6 +1,5 @@
-
 Getting Started
-=================
+===============
 
 Aurora consists of four main pieces: the scheduler (which finds resources in the cluster that can be used to run a job), the executor (which uses the resources assigned by the scheduler to run a job), the command-line client, and the web-ui. For information about working on the scheduler or the webUI, see the file "developing-aurora-scheduler.md" in this directory.
 
@@ -23,8 +22,17 @@ To run all of the client tests:
     $ ./pasts src/test/python/apache/aurora/client/:all
 
 
+Client Configuration
+====================
+
+The client uses a configuration file that specifies available clusters. More information about the
+contents of this file can be found in the
+[Client Cluster Configuration](client-cluster-configuration.md) documentation. Information about
+how the client locates this file can be found in the
+[Client Commands](client-commands.md#cluster-configuration) documentation.
+
 Client Versions
-==================
+===============
 
 There are currently two versions of the aurora client, imaginatively known as v1 and v2. All new development is done entirely in v2, but we continue to support and fix bugs in v1, until we get to the point where v2 is feature-complete and tested, and aurora users have had some time at adapt and switch their processes to use v2.
 
@@ -38,7 +46,7 @@ found in the `__init__.py` file in that directory.
 
 
 Building and Testing the Client
-=================================
+===============================
 
 Building and testing the client code are both done using Pants. The relevant targets to know about are:
 
@@ -50,7 +58,7 @@ Building and testing the client code are both done using Pants. The relevant tar
 
 
 Overview of the Client Architecture
-=====================================
+===================================
 
 The client is built on a stacked architecture:
 
@@ -80,7 +88,7 @@ The client is built on a stacked architecture:
        * `client.py` contains the code that binds the client v2 nouns and verbs into an executable.
 
 Running/Debugging the Client
-=============================
+============================
 
 For manually testing client changes against a cluster, we use vagrant. To start a virtual cluster,
 you need to install a working vagrant environment, and then run "vagrant up" for the root of