Skip to content

Commit

Permalink
upgrade K8s dependency lib to v0.21 (#1985)
Browse files Browse the repository at this point in the history
* upgrade K8s dependency to v0.21

* update CRD for new version of controller-runtime

* fix ci component revision create must fill Raw in runtime.RawExtension

* try fix test

* start control plane timeout set to 1min and fix tests

* add timeout for env test start and stop

* longer timeout time for BeforeSuit function

* upgrade kubebuilder and k8s cluster version to match with v1.21.2 in github action

* fix test

* fix resource tracker ownerRef override

* update developer guides
  • Loading branch information
wonderflow committed Aug 3, 2021
1 parent 7a1f957 commit aa87d3d
Show file tree
Hide file tree
Showing 194 changed files with 23,780 additions and 7,287 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,11 @@ jobs:
version: ${{ env.KIND_VERSION }}

- name: install Kubebuilder
uses: wonderflow/kubebuilder-action@v1.1
uses: RyanSiu1995/kubebuilder-action@v1.2
with:
version: 3.1.0
kubebuilderOnly: false
kubernetesVersion: v1.21.2

- name: Run Make compatibility-test
run: make compatibility-test
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/unit-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,11 @@ jobs:
version: ${{ env.KIND_VERSION }}

- name: install Kubebuilder
uses: wonderflow/kubebuilder-action@v1.1
uses: RyanSiu1995/kubebuilder-action@v1.2
with:
version: 3.1.0
kubebuilderOnly: false
kubernetesVersion: v1.21.2

- name: Run Make test
run: make test
Expand Down
5 changes: 3 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,9 @@ all: build

# Run tests
test: vet lint staticcheck
go test -race -coverprofile=coverage.txt -covermode=atomic ./pkg/... ./cmd/...
go test -race -covermode=atomic ./references/apiserver/... ./references/appfile/... ./references/cli/... ./references/common/... ./references/plugins/...
go test -coverprofile=coverage.txt ./pkg/... ./cmd/...
go test ./references/appfile/... ./references/cli/... ./references/common/... ./references/plugins/...
go test -race -covermode=atomic ./references/apiserver/...
@$(OK) unit-tests pass

# Build vela cli binary
Expand Down
699 changes: 529 additions & 170 deletions charts/oam-runtime/crds/core.oam.dev_applicationconfigurations.yaml

Large diffs are not rendered by default.

60 changes: 43 additions & 17 deletions charts/oam-runtime/crds/core.oam.dev_components.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,58 +30,78 @@ spec:
description: A Component describes how an OAM workload kind may be instantiated.
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: A ComponentSpec defines the desired state of a Component.
properties:
helm:
description: HelmRelease records a Helm release used by a Helm module workload.
description: HelmRelease records a Helm release used by a Helm module
workload.
properties:
release:
description: Release records a Helm release used by a Helm module workload.
description: Release records a Helm release used by a Helm module
workload.
type: object
x-kubernetes-preserve-unknown-fields: true
repository:
description: HelmRelease records a Helm repository used by a Helm module workload.
description: HelmRelease records a Helm repository used by a Helm
module workload.
type: object
x-kubernetes-preserve-unknown-fields: true
required:
- release
- repository
type: object
parameters:
description: Parameters exposed by this component. ApplicationConfigurations that reference this component may specify values for these parameters, which will in turn be injected into the embedded workload.
description: Parameters exposed by this component. ApplicationConfigurations
that reference this component may specify values for these parameters,
which will in turn be injected into the embedded workload.
items:
description: A ComponentParameter defines a configurable parameter of a component.
description: A ComponentParameter defines a configurable parameter
of a component.
properties:
description:
description: Description of this parameter.
type: string
fieldPaths:
description: FieldPaths specifies an array of fields within this Component's workload that will be overwritten by the value of this parameter. The type of the parameter (e.g. int, string) is inferred from the type of these fields; All fields must be of the same type. Fields are specified as JSON field paths without a leading dot, for example 'spec.replicas'.
description: FieldPaths specifies an array of fields within
this Component's workload that will be overwritten by the
value of this parameter. The type of the parameter (e.g. int,
string) is inferred from the type of these fields; All fields
must be of the same type. Fields are specified as JSON field
paths without a leading dot, for example 'spec.replicas'.
items:
type: string
type: array
name:
description: Name of this parameter. OAM ApplicationConfigurations will specify parameter values using this name.
description: Name of this parameter. OAM ApplicationConfigurations
will specify parameter values using this name.
type: string
required:
default: false
description: Required specifies whether or not a value for this parameter must be supplied when authoring an ApplicationConfiguration.
description: Required specifies whether or not a value for this
parameter must be supplied when authoring an ApplicationConfiguration.
type: boolean
required:
- fieldPaths
- name
type: object
type: array
workload:
description: A Workload that will be created for each ApplicationConfiguration that includes this Component. Workload is an instance of a workloadDefinition. We either use the GVK info or a special "type" field in the workload to associate the content of the workload with its workloadDefinition
description: A Workload that will be created for each ApplicationConfiguration
that includes this Component. Workload is an instance of a workloadDefinition.
We either use the GVK info or a special "type" field in the workload
to associate the content of the workload with its workloadDefinition
type: object
x-kubernetes-embedded-resource: true
x-kubernetes-preserve-unknown-fields: true
Expand All @@ -97,20 +117,25 @@ spec:
description: A Condition that may apply to a resource.
properties:
lastTransitionTime:
description: LastTransitionTime is the last time this condition transitioned from one status to another.
description: LastTransitionTime is the last time this condition
transitioned from one status to another.
format: date-time
type: string
message:
description: A Message containing details about this condition's last transition from one status to another, if any.
description: A Message containing details about this condition's
last transition from one status to another, if any.
type: string
reason:
description: A Reason for this condition's last transition from one status to another.
description: A Reason for this condition's last transition from
one status to another.
type: string
status:
description: Status of this condition; is it currently True, False, or Unknown?
description: Status of this condition; is it currently True,
False, or Unknown?
type: string
type:
description: Type of this condition. At most one of each condition type may apply to a resource at any point in time.
description: Type of this condition. At most one of each condition
type may apply to a resource at any point in time.
type: string
required:
- lastTransitionTime
Expand All @@ -128,7 +153,8 @@ spec:
format: int64
type: integer
revisionHash:
description: RevisionHash record the hash value of the spec of ApplicationRevision object.
description: RevisionHash record the hash value of the spec of
ApplicationRevision object.
type: string
required:
- name
Expand Down

0 comments on commit aa87d3d

Please sign in to comment.