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
9219a762
Commit
9219a762
authored
May 18, 2018
by
Guoliang Wang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove unused code of (pkg/scheduler)
parent
e6688fc6
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
7 additions
and
16 deletions
+7
-16
selector_spreading_test.go
...scheduler/algorithm/priorities/selector_spreading_test.go
+0
-1
BUILD
pkg/scheduler/core/BUILD
+0
-1
equivalence_cache_test.go
pkg/scheduler/core/equivalence_cache_test.go
+0
-2
extender_test.go
pkg/scheduler/core/extender_test.go
+7
-11
cache_test.go
pkg/scheduler/schedulercache/cache_test.go
+0
-1
No files found.
pkg/scheduler/algorithm/priorities/selector_spreading_test.go
View file @
9219a762
...
@@ -409,7 +409,6 @@ func TestZoneSelectorSpreadPriority(t *testing.T) {
...
@@ -409,7 +409,6 @@ func TestZoneSelectorSpreadPriority(t *testing.T) {
tests
:=
[]
struct
{
tests
:=
[]
struct
{
pod
*
v1
.
Pod
pod
*
v1
.
Pod
pods
[]
*
v1
.
Pod
pods
[]
*
v1
.
Pod
nodes
[]
string
rcs
[]
*
v1
.
ReplicationController
rcs
[]
*
v1
.
ReplicationController
rss
[]
*
extensions
.
ReplicaSet
rss
[]
*
extensions
.
ReplicaSet
services
[]
*
v1
.
Service
services
[]
*
v1
.
Service
...
...
pkg/scheduler/core/BUILD
View file @
9219a762
...
@@ -27,7 +27,6 @@ go_test(
...
@@ -27,7 +27,6 @@ go_test(
"//vendor/k8s.io/api/apps/v1beta1:go_default_library",
"//vendor/k8s.io/api/apps/v1beta1:go_default_library",
"//vendor/k8s.io/api/core/v1:go_default_library",
"//vendor/k8s.io/api/core/v1:go_default_library",
"//vendor/k8s.io/api/extensions/v1beta1:go_default_library",
"//vendor/k8s.io/api/extensions/v1beta1:go_default_library",
"//vendor/k8s.io/api/policy/v1beta1:go_default_library",
"//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library",
"//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library",
"//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library",
"//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library",
"//vendor/k8s.io/apimachinery/pkg/types:go_default_library",
"//vendor/k8s.io/apimachinery/pkg/types:go_default_library",
...
...
pkg/scheduler/core/equivalence_cache_test.go
View file @
9219a762
...
@@ -635,7 +635,6 @@ func TestInvalidateCachedPredicateItemOfAllNodes(t *testing.T) {
...
@@ -635,7 +635,6 @@ func TestInvalidateCachedPredicateItemOfAllNodes(t *testing.T) {
tests
:=
[]
struct
{
tests
:=
[]
struct
{
podName
string
podName
string
nodeName
string
nodeName
string
predicateKey
string
equivalenceHashForUpdatePredicate
uint64
equivalenceHashForUpdatePredicate
uint64
cachedItem
predicateItemType
cachedItem
predicateItemType
}{
}{
...
@@ -707,7 +706,6 @@ func TestInvalidateAllCachedPredicateItemOfNode(t *testing.T) {
...
@@ -707,7 +706,6 @@ func TestInvalidateAllCachedPredicateItemOfNode(t *testing.T) {
tests
:=
[]
struct
{
tests
:=
[]
struct
{
podName
string
podName
string
nodeName
string
nodeName
string
predicateKey
string
equivalenceHashForUpdatePredicate
uint64
equivalenceHashForUpdatePredicate
uint64
cachedItem
predicateItemType
cachedItem
predicateItemType
}{
}{
...
...
pkg/scheduler/core/extender_test.go
View file @
9219a762
...
@@ -22,7 +22,6 @@ import (
...
@@ -22,7 +22,6 @@ import (
"time"
"time"
"k8s.io/api/core/v1"
"k8s.io/api/core/v1"
policy
"k8s.io/api/policy/v1beta1"
metav1
"k8s.io/apimachinery/pkg/apis/meta/v1"
metav1
"k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/util/wait"
"k8s.io/apimachinery/pkg/util/wait"
"k8s.io/kubernetes/pkg/scheduler/algorithm"
"k8s.io/kubernetes/pkg/scheduler/algorithm"
...
@@ -117,7 +116,6 @@ type FakeExtender struct {
...
@@ -117,7 +116,6 @@ type FakeExtender struct {
// Cached node information for fake extender
// Cached node information for fake extender
cachedNodeNameToInfo
map
[
string
]
*
schedulercache
.
NodeInfo
cachedNodeNameToInfo
map
[
string
]
*
schedulercache
.
NodeInfo
cachedPDBs
[]
*
policy
.
PodDisruptionBudget
}
}
func
(
f
*
FakeExtender
)
IsIgnorable
()
bool
{
func
(
f
*
FakeExtender
)
IsIgnorable
()
bool
{
...
@@ -332,15 +330,13 @@ var _ algorithm.SchedulerExtender = &FakeExtender{}
...
@@ -332,15 +330,13 @@ var _ algorithm.SchedulerExtender = &FakeExtender{}
func
TestGenericSchedulerWithExtenders
(
t
*
testing
.
T
)
{
func
TestGenericSchedulerWithExtenders
(
t
*
testing
.
T
)
{
tests
:=
[]
struct
{
tests
:=
[]
struct
{
name
string
name
string
predicates
map
[
string
]
algorithm
.
FitPredicate
predicates
map
[
string
]
algorithm
.
FitPredicate
prioritizers
[]
algorithm
.
PriorityConfig
prioritizers
[]
algorithm
.
PriorityConfig
extenders
[]
FakeExtender
extenders
[]
FakeExtender
extenderPredicates
[]
fitPredicate
nodes
[]
string
extenderPrioritizers
[]
priorityConfig
expectedHost
string
nodes
[]
string
expectsErr
bool
expectedHost
string
expectsErr
bool
}{
}{
{
{
predicates
:
map
[
string
]
algorithm
.
FitPredicate
{
"true"
:
truePredicate
},
predicates
:
map
[
string
]
algorithm
.
FitPredicate
{
"true"
:
truePredicate
},
...
...
pkg/scheduler/schedulercache/cache_test.go
View file @
9219a762
...
@@ -517,7 +517,6 @@ func TestUpdatePod(t *testing.T) {
...
@@ -517,7 +517,6 @@ func TestUpdatePod(t *testing.T) {
makeBasePod
(
t
,
nodeName
,
"test"
,
"200m"
,
"1Ki"
,
""
,
[]
v1
.
ContainerPort
{{
HostIP
:
"127.0.0.1"
,
HostPort
:
8080
,
Protocol
:
"TCP"
}}),
makeBasePod
(
t
,
nodeName
,
"test"
,
"200m"
,
"1Ki"
,
""
,
[]
v1
.
ContainerPort
{{
HostIP
:
"127.0.0.1"
,
HostPort
:
8080
,
Protocol
:
"TCP"
}}),
}
}
tests
:=
[]
struct
{
tests
:=
[]
struct
{
podsToAssume
[]
*
v1
.
Pod
podsToAdd
[]
*
v1
.
Pod
podsToAdd
[]
*
v1
.
Pod
podsToUpdate
[]
*
v1
.
Pod
podsToUpdate
[]
*
v1
.
Pod
...
...
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