Skip to content

Commit

Permalink
Bump api version to v1alpha2
Browse files Browse the repository at this point in the history
  • Loading branch information
ChunyiLyu committed Mar 24, 2021
1 parent c40e4c3 commit 2d58cc6
Show file tree
Hide file tree
Showing 80 changed files with 381 additions and 381 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ manifests: install-tools
# Generate API reference documentation
api-reference:
crd-ref-docs \
--source-path ./api/v1alpha1 \
--source-path ./api/v1alpha2 \
--config ./docs/api/autogen/config.yaml \
--templates-dir ./docs/api/autogen/templates \
--output-path ./docs/api/rabbitmq.com.ref.asciidoc \
Expand Down
12 changes: 6 additions & 6 deletions PROJECT
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,20 @@ repo: github.com/rabbitmq/messaging-topology-operator
resources:
- group: rabbitmq.com
kind: Queue
version: v1alpha1
version: v1alpha2
- group: rabbitmq.com
kind: Exchange
version: v1alpha1
version: v1alpha2
- group: rabbitmq.com
kind: Binding
version: v1alpha1
version: v1alpha2
- group: rabbitmq.com
kind: User
version: v1alpha1
version: v1alpha2
- group: rabbitmq.com
kind: Vhost
version: v1alpha1
version: v1alpha2
- group: rabbitmq.com
kind: Policy
version: v1alpha1
version: v1alpha2
version: "2"
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This product is licensed to you under the Mozilla Public License 2.0 license (th
This product may include a number of subcomponents with separate copyright notices and license terms. Your use of these subcomponents is subject to the terms and conditions of the subcomponent's license, as noted in the LICENSE file.
*/

package v1alpha1
package v1alpha2

import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"context"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"fmt"
Expand All @@ -16,7 +16,7 @@ func (b *Binding) SetupWebhookWithManager(mgr ctrl.Manager) error {
Complete()
}

// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha1-binding,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=bindings,versions=v1alpha1,name=vbinding.kb.io,sideEffects=none,admissionReviewVersions=v1
// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha2-binding,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=bindings,versions=v1alpha2,name=vbinding.kb.io,sideEffects=none,admissionReviewVersions=v1

var _ webhook.Validator = &Binding{}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
. "github.com/onsi/ginkgo"
Expand Down
2 changes: 1 addition & 1 deletion api/v1alpha1/conditions.go → api/v1alpha2/conditions.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
corev1 "k8s.io/api/core/v1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
. "github.com/onsi/ginkgo"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This product is licensed to you under the Mozilla Public License 2.0 license (th
This product may include a number of subcomponents with separate copyright notices and license terms. Your use of these subcomponents is subject to the terms and conditions of the subcomponent's license, as noted in the LICENSE file.
*/

package v1alpha1
package v1alpha2

import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"context"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"fmt"
Expand All @@ -15,7 +15,7 @@ func (r *Exchange) SetupWebhookWithManager(mgr ctrl.Manager) error {
Complete()
}

// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha1-exchange,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=exchanges,versions=v1alpha1,name=vexchange.kb.io,sideEffects=none,admissionReviewVersions=v1
// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha2-exchange,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=exchanges,versions=v1alpha2,name=vexchange.kb.io,sideEffects=none,admissionReviewVersions=v1

var _ webhook.Validator = &Exchange{}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
. "github.com/onsi/ginkgo"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ This product is licensed to you under the Mozilla Public License 2.0 license (th
This product may include a number of subcomponents with separate copyright notices and license terms. Your use of these subcomponents is subject to the terms and conditions of the subcomponent's license, as noted in the LICENSE file.
*/

// Package v1alpha1 contains API Schema definitions for the rabbitmq.com v1alpha1 API group
// Package v1alpha2 contains API Schema definitions for the rabbitmq.com v1alpha2 API group
// +kubebuilder:object:generate=true
// +groupName=rabbitmq.com
package v1alpha1
package v1alpha2

import (
"k8s.io/apimachinery/pkg/runtime/schema"
Expand All @@ -19,7 +19,7 @@ import (

var (
// GroupVersion is group version used to register these objects
GroupVersion = schema.GroupVersion{Group: "rabbitmq.com", Version: "v1alpha1"}
GroupVersion = schema.GroupVersion{Group: "rabbitmq.com", Version: "v1alpha2"}

// SchemeBuilder is used to add go types to the GroupVersionKind scheme
SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"context"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"fmt"
Expand All @@ -15,7 +15,7 @@ func (p *Policy) SetupWebhookWithManager(mgr ctrl.Manager) error {
Complete()
}

// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha1-policy,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=policies,versions=v1alpha1,name=vpolicy.kb.io,sideEffects=none,admissionReviewVersions=v1
// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha2-policy,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=policies,versions=v1alpha2,name=vpolicy.kb.io,sideEffects=none,admissionReviewVersions=v1

var _ webhook.Validator = &Policy{}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
. "github.com/onsi/ginkgo"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This product is licensed to you under the Mozilla Public License 2.0 license (th
This product may include a number of subcomponents with separate copyright notices and license terms. Your use of these subcomponents is subject to the terms and conditions of the subcomponent's license, as noted in the LICENSE file.
*/

package v1alpha1
package v1alpha2

import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"context"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"fmt"
Expand All @@ -15,7 +15,7 @@ func (r *Queue) SetupWebhookWithManager(mgr ctrl.Manager) error {
Complete()
}

// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha1-queue,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=queues,versions=v1alpha1,name=vqueue.kb.io,sideEffects=none,admissionReviewVersions=v1sideEffects=none,admissionReviewVersions=v1
// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha2-queue,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=queues,versions=v1alpha2,name=vqueue.kb.io,sideEffects=none,admissionReviewVersions=v1sideEffects=none,admissionReviewVersions=v1

var _ webhook.Validator = &Queue{}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
. "github.com/onsi/ginkgo"
Expand Down
4 changes: 2 additions & 2 deletions api/v1alpha1/suite_test.go → api/v1alpha2/suite_test.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"path/filepath"
Expand All @@ -24,7 +24,7 @@ func TestAPIs(t *testing.T) {
RegisterFailHandler(Fail)

RunSpecsWithDefaultAndCustomReporters(t,
"v1alpha1 Suite",
"v1alpha2 Suite",
[]Reporter{printer.NewlineReporter{}})
}

Expand Down
2 changes: 1 addition & 1 deletion api/v1alpha1/user_types.go → api/v1alpha2/user_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This product is licensed to you under the Mozilla Public License 2.0 license (th
This product may include a number of subcomponents with separate copyright notices and license terms. Your use of these subcomponents is subject to the terms and conditions of the subcomponent's license, as noted in the LICENSE file.
*/

package v1alpha1
package v1alpha2

import (
corev1 "k8s.io/api/core/v1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"context"
Expand Down
4 changes: 2 additions & 2 deletions api/v1alpha1/user_webhook.go → api/v1alpha2/user_webhook.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"fmt"
Expand All @@ -15,7 +15,7 @@ func (u *User) SetupWebhookWithManager(mgr ctrl.Manager) error {
Complete()
}

// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha1-user,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=users,versions=v1alpha1,name=vuser.kb.io,sideEffects=none,admissionReviewVersions=v1
// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha2-user,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=users,versions=v1alpha2,name=vuser.kb.io,sideEffects=none,admissionReviewVersions=v1

var _ webhook.Validator = &User{}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
. "github.com/onsi/ginkgo"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This product is licensed to you under the Mozilla Public License 2.0 license (th
This product may include a number of subcomponents with separate copyright notices and license terms. Your use of these subcomponents is subject to the terms and conditions of the subcomponent's license, as noted in the LICENSE file.
*/

package v1alpha1
package v1alpha2

import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"context"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
"fmt"
Expand All @@ -15,7 +15,7 @@ func (r *Vhost) SetupWebhookWithManager(mgr ctrl.Manager) error {
Complete()
}

// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha1-vhost,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=vhosts,versions=v1alpha1,name=vvhost.kb.io,sideEffects=none,admissionReviewVersions=v1
// +kubebuilder:webhook:verbs=create;update,path=/validate-rabbitmq-com-v1alpha2-vhost,mutating=false,failurePolicy=fail,groups=rabbitmq.com,resources=vhosts,versions=v1alpha2,name=vvhost.kb.io,sideEffects=none,admissionReviewVersions=v1

var _ webhook.Validator = &Vhost{}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package v1alpha1
package v1alpha2

import (
. "github.com/onsi/ginkgo"
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion config/crd/bases/rabbitmq.com_bindings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ spec:
singular: binding
scope: Namespaced
versions:
- name: v1alpha1
- name: v1alpha2
schema:
openAPIV3Schema:
description: Binding is the Schema for the bindings API
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/rabbitmq.com_exchanges.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ spec:
singular: exchange
scope: Namespaced
versions:
- name: v1alpha1
- name: v1alpha2
schema:
openAPIV3Schema:
description: Exchange is the Schema for the exchanges API
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/rabbitmq.com_policies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ spec:
singular: policy
scope: Namespaced
versions:
- name: v1alpha1
- name: v1alpha2
schema:
openAPIV3Schema:
description: Policy is the Schema for the policies API
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/rabbitmq.com_queues.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ spec:
singular: queue
scope: Namespaced
versions:
- name: v1alpha1
- name: v1alpha2
schema:
openAPIV3Schema:
description: Queue is the Schema for the queues API
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/rabbitmq.com_users.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ spec:
singular: user
scope: Namespaced
versions:
- name: v1alpha1
- name: v1alpha2
schema:
openAPIV3Schema:
description: User is the Schema for the users API.
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/rabbitmq.com_vhosts.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ spec:
singular: vhost
scope: Namespaced
versions:
- name: v1alpha1
- name: v1alpha2
schema:
openAPIV3Schema:
description: Vhost is the Schema for the vhosts API
Expand Down
2 changes: 1 addition & 1 deletion config/samples/rabbitmq.com_v1alpha1_binding.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: rabbitmq.com/v1alpha1
apiVersion: rabbitmq.com/v1alpha2
kind: Binding
metadata:
name: binding-sample
Expand Down
2 changes: 1 addition & 1 deletion config/samples/rabbitmq.com_v1alpha1_exchange.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: rabbitmq.com/v1alpha1
apiVersion: rabbitmq.com/v1alpha2
kind: Exchange
metadata:
name: exchange-sample
Expand Down
2 changes: 1 addition & 1 deletion config/samples/rabbitmq.com_v1alpha1_policy.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: rabbitmq.com/v1alpha1
apiVersion: rabbitmq.com/v1alpha2
kind: Policy
metadata:
name: policy-sample
Expand Down
2 changes: 1 addition & 1 deletion config/samples/rabbitmq.com_v1alpha1_queue.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: rabbitmq.com/v1alpha1
apiVersion: rabbitmq.com/v1alpha2
kind: Queue
metadata:
name: test
2 changes: 1 addition & 1 deletion config/samples/rabbitmq.com_v1alpha1_user.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: rabbitmq.com/v1alpha1
apiVersion: rabbitmq.com/v1alpha2
kind: User
metadata:
name: user-sample
Expand Down
2 changes: 1 addition & 1 deletion config/samples/rabbitmq.com_v1alpha1_vhost.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: rabbitmq.com/v1alpha1
apiVersion: rabbitmq.com/v1alpha2
kind: Vhost
metadata:
name: vhost-sample
Expand Down
Loading

0 comments on commit 2d58cc6

Please sign in to comment.