commit
49e7c7ead4
2
cache/memory/memory.go
vendored
2
cache/memory/memory.go
vendored
@ -29,7 +29,7 @@ import (
|
||||
// ErrDataNotFound is the error resulting if failed to find a container in memory cache.
|
||||
var ErrDataNotFound = errors.New("unable to find data in memory cache")
|
||||
|
||||
// TODO(vmarmol): See about refactoring this class, we have an unecessary redirection of containerCache and InMemoryCache.
|
||||
// TODO(vmarmol): See about refactoring this class, we have an unnecessary redirection of containerCache and InMemoryCache.
|
||||
// containerCache is used to store per-container information
|
||||
type containerCache struct {
|
||||
ref info.ContainerReference
|
||||
|
@ -78,7 +78,7 @@ func (iw *InotifyWatcher) RemoveWatch(containerName, dir string) (bool, error) {
|
||||
iw.lock.Lock()
|
||||
defer iw.lock.Unlock()
|
||||
|
||||
// If we don't have a watch registed for this, just return.
|
||||
// If we don't have a watch registered for this, just return.
|
||||
cgroupsWatched, ok := iw.containersWatched[containerName]
|
||||
if !ok {
|
||||
return false, nil
|
||||
|
@ -228,7 +228,7 @@ func newDockerContainerHandler(
|
||||
handler.labels["restartcount"] = strconv.Itoa(ctnr.RestartCount)
|
||||
}
|
||||
|
||||
// Obtain the IP address for the contianer.
|
||||
// Obtain the IP address for the container.
|
||||
// If the NetworkMode starts with 'container:' then we need to use the IP address of the container specified.
|
||||
// This happens in cases such as kubernetes where the containers doesn't have an IP address itself and we need to use the pod's address
|
||||
ipAddress := ctnr.NetworkSettings.IPAddress
|
||||
|
2
fs/fs.go
2
fs/fs.go
@ -114,7 +114,7 @@ func NewFsInfo(context Context) (FsInfo, error) {
|
||||
|
||||
fsUUIDToDeviceName, err := getFsUUIDToDeviceNameMap()
|
||||
if err != nil {
|
||||
// UUID is not always avaiable across different OS distributions.
|
||||
// UUID is not always available across different OS distributions.
|
||||
// Do not fail if there is an error.
|
||||
glog.Warningf("Failed to get disk UUID mapping, getting disk info by uuid will not work: %v", err)
|
||||
}
|
||||
|
@ -102,11 +102,11 @@ type ContainerInfoRequest struct {
|
||||
NumStats int `json:"num_stats,omitempty"`
|
||||
|
||||
// Start time for which to query information.
|
||||
// If ommitted, the beginning of time is assumed.
|
||||
// If omitted, the beginning of time is assumed.
|
||||
Start time.Time `json:"start,omitempty"`
|
||||
|
||||
// End time for which to query information.
|
||||
// If ommitted, current time is assumed.
|
||||
// If omitted, current time is assumed.
|
||||
End time.Time `json:"end,omitempty"`
|
||||
}
|
||||
|
||||
|
@ -38,7 +38,7 @@ type CpuSpec struct {
|
||||
Mask string `json:"mask,omitempty"`
|
||||
// CPUQuota Default is disabled
|
||||
Quota uint64 `json:"quota,omitempty"`
|
||||
// Period is the CPU reference time in ns e.g the quota is compared aginst this.
|
||||
// Period is the CPU reference time in ns e.g the quota is compared against this.
|
||||
Period uint64 `json:"period,omitempty"`
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user