Skip to content

Commit

Permalink
Replace top level go mod with project specific dependency model
Browse files Browse the repository at this point in the history
The Platform Aware Scheduling repository now contains multiple go
dependency files - using a go.mod file in each subproject. This
commit adds the files for the extender and Telemetry Aware
Scheduling directories and removes the older single go.mod at
the top level of the repo.
  • Loading branch information
killianmuldoon authored and togashidm committed Jun 8, 2021
1 parent 48c2d0f commit 3081377
Show file tree
Hide file tree
Showing 35 changed files with 809 additions and 101 deletions.
12 changes: 6 additions & 6 deletions .github/e2e/e2e_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ import (

"github.com/pkg/errors"

"github.com/intel/telemetry-aware-scheduling/telemetry-aware-scheduling/pkg/metrics"
"github.com/intel/telemetry-aware-scheduling/telemetry-aware-scheduling/pkg/strategies/deschedule"
"github.com/intel/telemetry-aware-scheduling/telemetry-aware-scheduling/pkg/strategies/dontschedule"
"github.com/intel/telemetry-aware-scheduling/telemetry-aware-scheduling/pkg/strategies/scheduleonmetric"
api "github.com/intel/telemetry-aware-scheduling/telemetry-aware-scheduling/pkg/telemetrypolicy/api/v1alpha1"
tasclient "github.com/intel/telemetry-aware-scheduling/telemetry-aware-scheduling/pkg/telemetrypolicy/client/v1alpha1"
"github.com/intel/platform-aware-scheduling/telemetry-aware-scheduling/pkg/metrics"
"github.com/intel/platform-aware-scheduling/telemetry-aware-scheduling/pkg/strategies/deschedule"
"github.com/intel/platform-aware-scheduling/telemetry-aware-scheduling/pkg/strategies/dontschedule"
"github.com/intel/platform-aware-scheduling/telemetry-aware-scheduling/pkg/strategies/scheduleonmetric"
api "github.com/intel/platform-aware-scheduling/telemetry-aware-scheduling/pkg/telemetrypolicy/api/v1alpha1"
tasclient "github.com/intel/platform-aware-scheduling/telemetry-aware-scheduling/pkg/telemetrypolicy/client/v1alpha1"
v1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/api/resource"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
Expand Down
16 changes: 16 additions & 0 deletions .github/e2e/go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
module github.com/intel/platform-aware-scheduling/e2e

go 1.15

require (
github.com/intel/platform-aware-scheduling/telemetry-aware-scheduling v0.0.0-00010101000000-000000000000
github.com/pkg/errors v0.9.1
k8s.io/api v0.20.2
k8s.io/apimachinery v0.20.2
k8s.io/client-go v0.20.2
)

replace (
github.com/intel/platform-aware-scheduling/extender => ../../extender
github.com/intel/platform-aware-scheduling/telemetry-aware-scheduling => ../../telemetry-aware-scheduling
)
484 changes: 484 additions & 0 deletions .github/e2e/go.sum

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .github/workflows/end-to-end-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ jobs:
- name: Set up cluster with TAS and custom metrics
run: ./.github/scripts/e2e_setup_cluster.sh
- name: Run end to end tests
run: go test -v ./.github/e2e/e2e_test.go
run: cd .github/e2e/&& go test -v e2e_test.go
8 changes: 4 additions & 4 deletions .github/workflows/go-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ jobs:
go-version: 1.16

- name: Build
run: go build -v ./...
run: make test

- name: Test
run: go test -v ./...
run: make build

build-older-go-version:
runs-on: ubuntu-latest
Expand All @@ -37,7 +37,7 @@ jobs:
go-version: ${{ matrix.go-version }}

- name: Build
run: go build -v ./...
run: make build

- name: Test
run: go test -v ./...
run: make test
11 changes: 6 additions & 5 deletions .github/workflows/static-analysis.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,22 +29,23 @@ jobs:
with:
go-version: 1.15
- run: go get golang.org/x/tools/cmd/goimports; test -z $(goimports -l .) && test -z $(gofmt -l .)
golangci:

golangci-TAS:
strategy:
matrix:
go-version: [1.15.x]
os: [ubuntu-latest]
workingdir: [extender, telemetry-aware-scheduling]
name: lint
runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-go@v2
with:
go-version: 1.15
- name: golangci-lint
- name: golangci-lint-TAS
uses: golangci/golangci-lint-action@v2
with:
version: v1.29
skip-go-installation: true
working-directory: ${{matrix.workingdir }}
# Additional linting tools can be added here
args: --enable=golint --timeout=5m
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,11 @@ With a policy like the above as part of the Kubernetes scheduler configuration t

To read more about scheduler extenders see the [official docs](https://github.com/kubernetes/community/blob/master/contributors/design-proposals/scheduling/scheduler_extender.md).

## Adding a new extender to Platform Aware Scheduling
Platform Aware Scheduling is a single repo designed to host multiple hardware enabling Kubernetes Scheduler Extenders. A new scheduler can be added with an issue and pull request.

Each project under the top-level repo has its own go module, dependency model and lifecycle.There is no single top level go.mod for the project. Some development tools and testing workflows may need to be done in the context of the go module they're targeting i.e. by changing into one of the directories that contains a go module.

## Communication and contribution

Report a bug by [filing a new issue](https://github.com/intel/telemetry-aware-scheduling/issues).
Expand Down
5 changes: 5 additions & 0 deletions extender/go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module github.com/intel/platform-aware-scheduling/extender

go 1.15

require k8s.io/api v0.20.2
Loading

0 comments on commit 3081377

Please sign in to comment.