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
48557a16
Commit
48557a16
authored
Nov 06, 2018
by
Bobby (Babak) Salamat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixup! Add a scheduler cache dumper
parent
4bb57c44
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
dumper.go
pkg/scheduler/internal/cache/debugger/dumper.go
+8
-8
No files found.
pkg/scheduler/internal/cache/debugger/dumper.go
View file @
48557a16
...
@@ -37,21 +37,21 @@ type CacheDumper struct {
...
@@ -37,21 +37,21 @@ type CacheDumper struct {
// DumpAll writes cached nodes and scheduling queue information to the scheduler logs.
// DumpAll writes cached nodes and scheduling queue information to the scheduler logs.
func
(
d
*
CacheDumper
)
DumpAll
()
{
func
(
d
*
CacheDumper
)
DumpAll
()
{
d
.
D
umpNodes
()
d
.
d
umpNodes
()
d
.
D
umpSchedulingQueue
()
d
.
d
umpSchedulingQueue
()
}
}
//
D
umpNodes writes NodeInfo to the scheduler logs.
//
d
umpNodes writes NodeInfo to the scheduler logs.
func
(
d
*
CacheDumper
)
D
umpNodes
()
{
func
(
d
*
CacheDumper
)
d
umpNodes
()
{
snapshot
:=
d
.
cache
.
Snapshot
()
snapshot
:=
d
.
cache
.
Snapshot
()
glog
.
Info
(
"Dump of cached NodeInfo"
)
glog
.
Info
(
"Dump of cached NodeInfo"
)
for
_
,
i
nfo
:=
range
snapshot
.
Nodes
{
for
_
,
nodeI
nfo
:=
range
snapshot
.
Nodes
{
glog
.
Info
(
printNodeInfo
(
i
nfo
))
glog
.
Info
(
printNodeInfo
(
nodeI
nfo
))
}
}
}
}
//
D
umpSchedulingQueue writes pods in the scheduling queue to the scheduler logs.
//
d
umpSchedulingQueue writes pods in the scheduling queue to the scheduler logs.
func
(
d
*
CacheDumper
)
D
umpSchedulingQueue
()
{
func
(
d
*
CacheDumper
)
d
umpSchedulingQueue
()
{
waitingPods
:=
d
.
podQueue
.
WaitingPods
()
waitingPods
:=
d
.
podQueue
.
WaitingPods
()
var
podData
strings
.
Builder
var
podData
strings
.
Builder
for
_
,
p
:=
range
waitingPods
{
for
_
,
p
:=
range
waitingPods
{
...
...
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