Skip to content

Commit 759517c

Browse files
Merge branch 'main' into add-rp-e2e-test
2 parents f8c83ce + 6cbfa8f commit 759517c

File tree

13 files changed

+51
-51
lines changed

13 files changed

+51
-51
lines changed

cmd/hubagent/workload/setup.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,10 @@ import (
5353
"github.com/kubefleet-dev/kubefleet/pkg/scheduler/framework"
5454
"github.com/kubefleet-dev/kubefleet/pkg/scheduler/profile"
5555
"github.com/kubefleet-dev/kubefleet/pkg/scheduler/queue"
56-
schedulercrbwatcher "github.com/kubefleet-dev/kubefleet/pkg/scheduler/watchers/clusterresourcebinding"
57-
schedulercrpwatcher "github.com/kubefleet-dev/kubefleet/pkg/scheduler/watchers/clusterresourceplacement"
58-
schedulercspswatcher "github.com/kubefleet-dev/kubefleet/pkg/scheduler/watchers/clusterschedulingpolicysnapshot"
56+
schedulerbindingwatcher "github.com/kubefleet-dev/kubefleet/pkg/scheduler/watchers/binding"
5957
"github.com/kubefleet-dev/kubefleet/pkg/scheduler/watchers/membercluster"
58+
schedulerplacementwatcher "github.com/kubefleet-dev/kubefleet/pkg/scheduler/watchers/placement"
59+
schedulerspswatcher "github.com/kubefleet-dev/kubefleet/pkg/scheduler/watchers/schedulingpolicysnapshot"
6060
"github.com/kubefleet-dev/kubefleet/pkg/utils"
6161
"github.com/kubefleet-dev/kubefleet/pkg/utils/controller"
6262
"github.com/kubefleet-dev/kubefleet/pkg/utils/informer"
@@ -371,7 +371,7 @@ func SetupControllers(ctx context.Context, wg *sync.WaitGroup, mgr ctrl.Manager,
371371

372372
// Set up the watchers for the controller
373373
klog.Info("Setting up the clusterResourcePlacement watcher for scheduler")
374-
if err := (&schedulercrpwatcher.Reconciler{
374+
if err := (&schedulerplacementwatcher.Reconciler{
375375
Client: mgr.GetClient(),
376376
SchedulerWorkQueue: defaultSchedulingQueue,
377377
}).SetupWithManagerForClusterResourcePlacement(mgr); err != nil {
@@ -380,7 +380,7 @@ func SetupControllers(ctx context.Context, wg *sync.WaitGroup, mgr ctrl.Manager,
380380
}
381381

382382
klog.Info("Setting up the clusterSchedulingPolicySnapshot watcher for scheduler")
383-
if err := (&schedulercspswatcher.Reconciler{
383+
if err := (&schedulerspswatcher.Reconciler{
384384
Client: mgr.GetClient(),
385385
SchedulerWorkQueue: defaultSchedulingQueue,
386386
}).SetupWithManagerForClusterSchedulingPolicySnapshot(mgr); err != nil {
@@ -389,7 +389,7 @@ func SetupControllers(ctx context.Context, wg *sync.WaitGroup, mgr ctrl.Manager,
389389
}
390390

391391
klog.Info("Setting up the clusterResourceBinding watcher for scheduler")
392-
if err := (&schedulercrbwatcher.Reconciler{
392+
if err := (&schedulerbindingwatcher.Reconciler{
393393
Client: mgr.GetClient(),
394394
SchedulerWorkQueue: defaultSchedulingQueue,
395395
}).SetupWithManagerForClusterResourceBinding(mgr); err != nil {
@@ -399,7 +399,7 @@ func SetupControllers(ctx context.Context, wg *sync.WaitGroup, mgr ctrl.Manager,
399399

400400
if opts.EnableResourcePlacement {
401401
klog.Info("Setting up the resourcePlacement watcher for scheduler")
402-
if err := (&schedulercrpwatcher.Reconciler{
402+
if err := (&schedulerplacementwatcher.Reconciler{
403403
Client: mgr.GetClient(),
404404
SchedulerWorkQueue: defaultSchedulingQueue,
405405
}).SetupWithManagerForResourcePlacement(mgr); err != nil {
@@ -408,7 +408,7 @@ func SetupControllers(ctx context.Context, wg *sync.WaitGroup, mgr ctrl.Manager,
408408
}
409409

410410
klog.Info("Setting up the schedulingPolicySnapshot watcher for scheduler")
411-
if err := (&schedulercspswatcher.Reconciler{
411+
if err := (&schedulerspswatcher.Reconciler{
412412
Client: mgr.GetClient(),
413413
SchedulerWorkQueue: defaultSchedulingQueue,
414414
}).SetupWithManagerForSchedulingPolicySnapshot(mgr); err != nil {
@@ -417,7 +417,7 @@ func SetupControllers(ctx context.Context, wg *sync.WaitGroup, mgr ctrl.Manager,
417417
}
418418

419419
klog.Info("Setting up the resourceBinding watcher for scheduler")
420-
if err := (&schedulercrbwatcher.Reconciler{
420+
if err := (&schedulerbindingwatcher.Reconciler{
421421
Client: mgr.GetClient(),
422422
SchedulerWorkQueue: defaultSchedulingQueue,
423423
}).SetupWithManagerForResourceBinding(mgr); err != nil {

pkg/scheduler/watchers/clusterresourcebinding/controller_integration_test.go renamed to pkg/scheduler/watchers/binding/controller_integration_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package clusterresourcebinding
17+
package binding
1818

1919
import (
2020
"fmt"

pkg/scheduler/watchers/clusterresourcebinding/suite_test.go renamed to pkg/scheduler/watchers/binding/suite_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package clusterresourcebinding
17+
package binding
1818

1919
import (
2020
"context"
@@ -49,7 +49,7 @@ var (
4949
func TestAPIs(t *testing.T) {
5050
RegisterFailHandler(Fail)
5151

52-
RunSpecs(t, "Scheduler Source Cluster Resource Binding Controller Suite")
52+
RunSpecs(t, "Scheduler Source Binding Controller Suite")
5353
}
5454

5555
var _ = BeforeSuite(func() {

pkg/scheduler/watchers/clusterresourcebinding/watcher.go renamed to pkg/scheduler/watchers/binding/watcher.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package clusterresourcebinding
17+
package binding
1818

1919
import (
2020
"context"

pkg/scheduler/watchers/clusterresourceplacement/controller_integration_test.go renamed to pkg/scheduler/watchers/placement/controller_integration_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package clusterresourceplacement
17+
package placement
1818

1919
import (
2020
"fmt"

pkg/scheduler/watchers/clusterresourceplacement/suite_test.go renamed to pkg/scheduler/watchers/placement/suite_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package clusterresourceplacement
17+
package placement
1818

1919
import (
2020
"context"
@@ -49,7 +49,7 @@ var (
4949
func TestAPIs(t *testing.T) {
5050
RegisterFailHandler(Fail)
5151

52-
RunSpecs(t, "Scheduler Source Cluster Resource Placement Controller Suite")
52+
RunSpecs(t, "Scheduler Source Placement Controller Suite")
5353
}
5454

5555
var _ = BeforeSuite(func() {

pkg/scheduler/watchers/clusterresourceplacement/watcher.go renamed to pkg/scheduler/watchers/placement/watcher.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
// Package clusterresourceplacement features a controller that enqueues placement objects for the
17+
// Package placement features a controller that enqueues placement objects for the
1818
// scheduler to process where the placement object is marked for deletion.
19-
package clusterresourceplacement
19+
package placement
2020

2121
import (
2222
"context"

pkg/scheduler/watchers/clusterschedulingpolicysnapshot/controller_integration_test.go renamed to pkg/scheduler/watchers/schedulingpolicysnapshot/controller_integration_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package clusterschedulingpolicysnapshot
17+
package schedulingpolicysnapshot
1818

1919
import (
2020
"fmt"

pkg/scheduler/watchers/clusterschedulingpolicysnapshot/suite_test.go renamed to pkg/scheduler/watchers/schedulingpolicysnapshot/suite_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package clusterschedulingpolicysnapshot
17+
package schedulingpolicysnapshot
1818

1919
import (
2020
"context"
@@ -49,7 +49,7 @@ var (
4949
func TestAPIs(t *testing.T) {
5050
RegisterFailHandler(Fail)
5151

52-
RunSpecs(t, "Scheduler Source Cluster Scheduling Policy Snapshot Controller Suite")
52+
RunSpecs(t, "Scheduler Source Scheduling Policy Snapshot Controller Suite")
5353
}
5454

5555
var _ = BeforeSuite(func() {

pkg/scheduler/watchers/clusterschedulingpolicysnapshot/watcher.go renamed to pkg/scheduler/watchers/schedulingpolicysnapshot/watcher.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
// Package clusterschedulingpolicysnapshot features a controller that enqueues placement objects for the
17+
// Package schedulingpolicysnapshot features a controller that enqueues placement objects for the
1818
// scheduler to process where there is a change in their scheduling policy snapshots.
19-
package clusterschedulingpolicysnapshot
19+
package schedulingpolicysnapshot
2020

2121
import (
2222
"context"

0 commit comments

Comments
 (0)