Fixed some typos and improved comments

This commit is contained in:
qiaolei
2015-10-03 22:43:10 +08:00
parent 9659ab131a
commit 919add69be

View File

@@ -43,7 +43,7 @@ type Interface interface {
// Clusters is an abstract, pluggable interface for clusters of containers.
type Clusters interface {
// List lists the names of the available clusters.
// ListClusters lists the names of the available clusters.
ListClusters() ([]string, error)
// Master gets back the address (either DNS name or IP address) of the master node for the cluster.
Master(clusterName string) (string, error)
@@ -110,7 +110,7 @@ type Instances interface {
// AddSSHKeyToAllInstances adds an SSH public key as a legal identity for all instances
// expected format for the key is standard ssh-keygen format: <protocol> <blob>
AddSSHKeyToAllInstances(user string, keyData []byte) error
// Returns the name of the node we are currently running on
// CurrentNodeName returns the name of the node we are currently running on
// On most clouds (e.g. GCE) this is the hostname, so we provide the hostname
CurrentNodeName(hostname string) (string, error)
}
@@ -123,20 +123,20 @@ type Route struct {
// TargetInstance is the name of the instance as specified in routing rules
// for the cloud-provider (in gce: the Instance Name).
TargetInstance string
// Destination CIDR is the CIDR format IP range that this routing rule
// DestinationCIDR is the CIDR format IP range that this routing rule
// applies to.
DestinationCIDR string
}
// Routes is an abstract, pluggable interface for advanced routing rules.
type Routes interface {
// List all managed routes that belong to the specified clusterName
// ListRoutes lists all managed routes that belong to the specified clusterName
ListRoutes(clusterName string) ([]*Route, error)
// Create the described managed route
// CreateRoute creates the described managed route
// route.Name will be ignored, although the cloud-provider may use nameHint
// to create a more user-meaningful name.
CreateRoute(clusterName string, nameHint string, route *Route) error
// Delete the specified managed route
// DeleteRoute deletes the specified managed route
// Route should be as returned by ListRoutes
DeleteRoute(clusterName string, route *Route) error
}