Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion datastore/datastore.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ type DataStore interface {
DeleteObjectAtomic(kvObject KVObject) error
// DeleteTree deletes a record
DeleteTree(kvObject KVObject) error
// Watchable returns whether the store is watchable are not
// Watchable returns whether the store is watchable or not
Watchable() bool
// Watch for changes on a KVObject
Watch(kvObject KVObject, stopCh <-chan struct{}) (<-chan KVObject, error)
Expand Down
2 changes: 1 addition & 1 deletion discoverapi/discoverapi.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ type DiscoveryType int
const (
// NodeDiscovery represents Node join/leave events provided by discovery
NodeDiscovery = iota + 1
// DatastoreConfig represents a add/remove datastore event
// DatastoreConfig represents an add/remove datastore event
DatastoreConfig
)

Expand Down
2 changes: 1 addition & 1 deletion driverapi/driverapi.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ type JoinInfo interface {
// SetGatewayIPv6 sets the default IPv6 gateway when a container joins the endpoint.
SetGatewayIPv6(net.IP) error

// AddStaticRoute adds a routes to the sandbox.
// AddStaticRoute adds a route to the sandbox.
// It may be used in addtion to or instead of a default gateway (as above).
AddStaticRoute(destination *net.IPNet, routeType int, nextHop net.IP) error

Expand Down
4 changes: 2 additions & 2 deletions driverapi/ipamdata.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func (i *IPAMData) UnmarshalJSON(data []byte) error {
return nil
}

// Validate checks wheter the IPAMData structure contains congruent data
// Validate checks whether the IPAMData structure contains congruent data
func (i *IPAMData) Validate() error {
var isV6 bool
if i.Pool == nil {
Expand Down Expand Up @@ -93,7 +93,7 @@ func (i *IPAMData) Validate() error {
return nil
}

// IsV6 returns wheter this is an IPv6 IPAMData structure
// IsV6 returns whether this is an IPv6 IPAMData structure
func (i *IPAMData) IsV6() bool {
return nil == i.Pool.IP.To4()
}
Expand Down
2 changes: 1 addition & 1 deletion idm/idm.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"github.com/docker/libnetwork/datastore"
)

// Idm manages the reservation/release of numerical ids from a contiguos set
// Idm manages the reservation/release of numerical ids from a contiguous set
type Idm struct {
start uint64
end uint64
Expand Down
4 changes: 2 additions & 2 deletions ipam/structures.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ type addrSpace struct {
}

// AddressRange specifies first and last ip ordinal which
// identify a range in a a pool of addresses
// identifies a range in a pool of addresses
type AddressRange struct {
Sub *net.IPNet
Start, End uint64
Expand Down Expand Up @@ -85,7 +85,7 @@ func (s *SubnetKey) String() string {
return k
}

// FromString populate the SubnetKey object reading it from string
// FromString populates the SubnetKey object reading it from string
func (s *SubnetKey) FromString(str string) error {
if str == "" || !strings.Contains(str, "/") {
return types.BadRequestErrorf("invalid string form for subnetkey: %s", str)
Expand Down
2 changes: 1 addition & 1 deletion ipam/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ func getAddressVersion(ip net.IP) ipVersion {
}

// Adds the ordinal IP to the current array
// 192.168.0.0 + 53 => 192.168.53
// 192.168.0.0 + 53 => 192.168.0.53
func addIntToIP(array []byte, ordinal uint64) {
for i := len(array) - 1; i >= 0; i-- {
array[i] |= (byte)(ordinal & 0xff)
Expand Down
2 changes: 1 addition & 1 deletion ipamapi/contract.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ type Callback interface {
* IPAM Errors
**************/

// Weel-known errors returned by IPAM
// Well-known errors returned by IPAM
var (
ErrIpamInternalError = types.InternalErrorf("IPAM Internal Error")
ErrInvalidAddressSpace = types.BadRequestErrorf("Invalid Address Space")
Expand Down
10 changes: 5 additions & 5 deletions types/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,7 @@ const (
// NEXTHOP indicates a StaticRoute with an IP next hop.
NEXTHOP = iota

// CONNECTED indicates a StaticRoute with a interface for directly connected peers.
// CONNECTED indicates a StaticRoute with an interface for directly connected peers.
CONNECTED
)

Expand Down Expand Up @@ -458,25 +458,25 @@ type NotFoundError interface {
NotFound()
}

// ForbiddenError is an interface for errors which denote an valid request that cannot be honored
// ForbiddenError is an interface for errors which denote a valid request that cannot be honored
type ForbiddenError interface {
// Forbidden makes implementer into ForbiddenError type
Forbidden()
}

// NoServiceError is an interface for errors returned when the required service is not available
// NoServiceError is an interface for errors returned when the required service is not available
type NoServiceError interface {
// NoService makes implementer into NoServiceError type
NoService()
}

// TimeoutError is an interface for errors raised because of timeout
// TimeoutError is an interface for errors raised because of timeout
type TimeoutError interface {
// Timeout makes implementer into TimeoutError type
Timeout()
}

// NotImplementedError is an interface for errors raised because of requested functionality is not yet implemented
// NotImplementedError is an interface for errors raised because of requested functionality is not yet implemented
type NotImplementedError interface {
// NotImplemented makes implementer into NotImplementedError type
NotImplemented()
Expand Down