Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
dbb715eb
Commit
dbb715eb
authored
Nov 06, 2016
by
Jun Gong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix kubelet's PodAdmitResult's message
parent
6f053ec4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
predicate.go
pkg/kubelet/lifecycle/predicate.go
+2
-2
No files found.
pkg/kubelet/lifecycle/predicate.go
View file @
dbb715eb
...
@@ -84,7 +84,7 @@ func (w *predicateAdmitHandler) Admit(attrs *PodAdmitAttributes) PodAdmitResult
...
@@ -84,7 +84,7 @@ func (w *predicateAdmitHandler) Admit(attrs *PodAdmitAttributes) PodAdmitResult
glog
.
V
(
2
)
.
Infof
(
"Predicate failed on Pod: %v, for reason: %v"
,
format
.
Pod
(
pod
),
message
)
glog
.
V
(
2
)
.
Infof
(
"Predicate failed on Pod: %v, for reason: %v"
,
format
.
Pod
(
pod
),
message
)
case
*
predicates
.
InsufficientResourceError
:
case
*
predicates
.
InsufficientResourceError
:
reason
=
fmt
.
Sprintf
(
"OutOf%s"
,
re
.
ResourceName
)
reason
=
fmt
.
Sprintf
(
"OutOf%s"
,
re
.
ResourceName
)
message
:
=
re
.
Error
()
message
=
re
.
Error
()
glog
.
V
(
2
)
.
Infof
(
"Predicate failed on Pod: %v, for reason: %v"
,
format
.
Pod
(
pod
),
message
)
glog
.
V
(
2
)
.
Infof
(
"Predicate failed on Pod: %v, for reason: %v"
,
format
.
Pod
(
pod
),
message
)
case
*
predicates
.
FailureReason
:
case
*
predicates
.
FailureReason
:
reason
=
re
.
GetReason
()
reason
=
re
.
GetReason
()
...
@@ -92,7 +92,7 @@ func (w *predicateAdmitHandler) Admit(attrs *PodAdmitAttributes) PodAdmitResult
...
@@ -92,7 +92,7 @@ func (w *predicateAdmitHandler) Admit(attrs *PodAdmitAttributes) PodAdmitResult
glog
.
V
(
2
)
.
Infof
(
"Predicate failed on Pod: %v, for reason: %v"
,
format
.
Pod
(
pod
),
message
)
glog
.
V
(
2
)
.
Infof
(
"Predicate failed on Pod: %v, for reason: %v"
,
format
.
Pod
(
pod
),
message
)
default
:
default
:
reason
=
"UnexpectedPredicateFailureType"
reason
=
"UnexpectedPredicateFailureType"
message
:
=
fmt
.
Sprintf
(
"GeneralPredicates failed due to %v, which is unexpected."
,
r
)
message
=
fmt
.
Sprintf
(
"GeneralPredicates failed due to %v, which is unexpected."
,
r
)
glog
.
Warningf
(
"Failed to admit pod %v - %s"
,
format
.
Pod
(
pod
),
message
)
glog
.
Warningf
(
"Failed to admit pod %v - %s"
,
format
.
Pod
(
pod
),
message
)
}
}
return
PodAdmitResult
{
return
PodAdmitResult
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment