Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move apis&cache into pkg/controllers folder #80

Merged
merged 1 commit into from
Apr 9, 2019
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
4 changes: 2 additions & 2 deletions hack/.golint_failures
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ volcano.sh/volcano/pkg/apis/batch/v1alpha1
volcano.sh/volcano/pkg/apis/bus/v1alpha1
volcano.sh/volcano/pkg/apis/helpers
volcano.sh/volcano/pkg/cli/job
volcano.sh/volcano/pkg/controllers/apis
volcano.sh/volcano/pkg/controllers/cache
volcano.sh/volcano/pkg/controllers/job
volcano.sh/volcano/pkg/controllers/job/apis
volcano.sh/volcano/pkg/controllers/job/cache
volcano.sh/volcano/pkg/controllers/job/helpers
volcano.sh/volcano/pkg/controllers/job/plugins
volcano.sh/volcano/pkg/controllers/job/plugins/env
Expand Down
6 changes: 3 additions & 3 deletions hack/run-e2e-kind.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,9 @@ function install-volcano {
docker pull ${MPI_EXAMPLE_IMAGE}

echo "Loading docker images into kind cluster"
kind load docker-image ${IMAGE}-controllers:${TAG} ${CLUSTER_CONTEXT}
kind load docker-image ${IMAGE}-scheduler:${TAG} ${CLUSTER_CONTEXT}
kind load docker-image ${IMAGE}-admission:${TAG} ${CLUSTER_CONTEXT}
kind load docker-image ${IMAGE_PREFIX}-controllers:${TAG} ${CLUSTER_CONTEXT}
kind load docker-image ${IMAGE_PREFIX}-scheduler:${TAG} ${CLUSTER_CONTEXT}
kind load docker-image ${IMAGE_PREFIX}-admission:${TAG} ${CLUSTER_CONTEXT}
kind load docker-image ${MPI_EXAMPLE_IMAGE} ${CLUSTER_CONTEXT}

echo "Install volcano plugin into cluster...."
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import (
"k8s.io/client-go/util/workqueue"

"volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type jobCache struct {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"k8s.io/api/core/v1"

"volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type Cache interface {
Expand Down
4 changes: 2 additions & 2 deletions pkg/controllers/job/job_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ import (
vkcoreinfo "volcano.sh/volcano/pkg/client/informers/externalversions/bus/v1alpha1"
vkbatchlister "volcano.sh/volcano/pkg/client/listers/batch/v1alpha1"
vkcorelister "volcano.sh/volcano/pkg/client/listers/bus/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
jobcache "volcano.sh/volcano/pkg/controllers/job/cache"
"volcano.sh/volcano/pkg/controllers/apis"
jobcache "volcano.sh/volcano/pkg/controllers/cache"
"volcano.sh/volcano/pkg/controllers/job/state"
)

Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/job_controller_actions.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ import (
vkbatchv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/apis/helpers"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
vkjobhelpers "volcano.sh/volcano/pkg/controllers/job/helpers"
"volcano.sh/volcano/pkg/controllers/job/state"
)
Expand Down
21 changes: 0 additions & 21 deletions pkg/controllers/job/job_controller_const.go

This file was deleted.

4 changes: 2 additions & 2 deletions pkg/controllers/job/job_controller_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ import (
kbtype "github.com/kubernetes-sigs/kube-batch/pkg/apis/scheduling/v1alpha1"
vkbatchv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
vkbusv1 "volcano.sh/volcano/pkg/apis/bus/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
vkcache "volcano.sh/volcano/pkg/controllers/job/cache"
"volcano.sh/volcano/pkg/controllers/apis"
vkcache "volcano.sh/volcano/pkg/controllers/cache"
)

func (cc *Controller) addCommand(obj interface{}) {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/job_controller_util.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import (
admissioncontroller "volcano.sh/volcano/pkg/admission"
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/apis/helpers"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

func eventKey(obj interface{}) interface{} {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/state/aborted.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package state

import (
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type abortedState struct {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/state/aborting.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package state

import (
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type abortingState struct {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/state/completing.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package state

import (
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type completingState struct {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/state/factory.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package state

import (
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type NextStateFn func(status vkv1.JobStatus) vkv1.JobState
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/state/finished.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package state

import (
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type finishedState struct {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/state/pending.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package state

import (
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type pendingState struct {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/state/restarting.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package state

import (
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type restartingState struct {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/state/running.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package state

import (
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type runningState struct {
Expand Down
2 changes: 1 addition & 1 deletion pkg/controllers/job/state/terminating.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package state

import (
vkv1 "volcano.sh/volcano/pkg/apis/batch/v1alpha1"
"volcano.sh/volcano/pkg/controllers/job/apis"
"volcano.sh/volcano/pkg/controllers/apis"
)

type terminatingState struct {
Expand Down