-
Notifications
You must be signed in to change notification settings - Fork 600
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
upgrader #3110
upgrader #3110
Conversation
This pull request introduces 1 alert when merging 3b8d074 into d76621b - view on LGTM.com new alerts:
|
not tested, will do 👀 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Produced via:
prettier --write --prose-wrap=always $(find -name '*.md' | grep -v vendor | grep -v .github | grep -v docs/cmd/)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Produced via:
prettier --write --prose-wrap=always $(find -name '*.md' | grep -v vendor | grep -v .github | grep -v docs/cmd/)
I tested this against InMemoryChannel as well as Kafka channels by creating a Broker as usual, but then patching (or editing against the v1alpha1 API) and patching in a ChannelTemplateSpec and running the job, and checking the configmaps were created, channels were created and if I deleted the trigger channel, it was properly created. |
Hm.:
So, since that's a CreatePodOrFail, kills the test. |
/test pull-knative-eventing-integration-tests |
/test pull-knative-eventing-integration-tests |
Not 100% sure what the testing was... but (against your branch) I could not do this:
since
I'd appreciate a bit more of details what the steps were for your patching or editing against thanks |
serviceAccountName: eventing-controller | ||
restartPolicy: Never | ||
containers: | ||
- name: upgrade-brokers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perhaps the name is a bit too generic ?
It's same as here:
https://github.com/knative/eventing/blob/master/config/upgrade/v0.14.0/upgrade.yaml#L17
🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's just the container, I'd rather leave it and not bake the version in there as well? It's already in the job.
Here is what the apiVersion: messaging.knative.dev/v1alpha1
kind: KafkaChannel
metadata:
creationTimestamp: "2020-05-13T14:43:40Z"
finalizers:
- kafkachannels.messaging.knative.dev
generation: 1
labels:
eventing.knative.dev/broker: default
eventing.knative.dev/brokerEverything: "true"
managedFields:
- apiVersion: messaging.knative.dev/v1alpha1
fieldsType: FieldsV1
fieldsV1:
f:metadata:
f:labels:
.: {}
f:eventing.knative.dev/broker: {}
f:eventing.knative.dev/brokerEverything: {}
f:ownerReferences:
.: {}
k:{"uid":"cf62c7de-5761-4b11-8418-32a0c7437f73"}:
.: {}
f:apiVersion: {}
f:blockOwnerDeletion: {}
f:controller: {}
f:kind: {}
f:name: {}
f:uid: {}
f:spec:
.: {}
f:numPartitions: {}
f:replicationFactor: {}
manager: channel_broker
operation: Update
time: "2020-05-13T14:43:40Z"
- apiVersion: messaging.knative.dev/v1alpha1
fieldsType: FieldsV1
fieldsV1:
f:metadata:
f:finalizers:
.: {}
v:"kafkachannels.messaging.knative.dev": {}
f:status:
.: {}
f:address:
.: {}
f:hostname: {}
f:url: {}
f:conditions: {}
manager: channel_controller
operation: Update
time: "2020-05-13T14:43:46Z"
name: default-kne-trigger
namespace: default
ownerReferences:
- apiVersion: eventing.knative.dev/v1alpha1
blockOwnerDeletion: true
controller: true
kind: Broker
name: default
uid: cf62c7de-5761-4b11-8418-32a0c7437f73
resourceVersion: "2611"
selfLink: /apis/messaging.knative.dev/v1alpha1/namespaces/default/kafkachannels/default-kne-trigger
uid: b31d6050-5715-43f8-9027-978bd7a3e13e
spec:
numPartitions: 3
replicationFactor: 1
status:
address:
hostname: default-kne-trigger-kn-channel.default.svc.cluster.local
url: http://default-kne-trigger-kn-channel.default.svc.cluster.local
conditions:
- lastTransitionTime: "2020-05-13T14:43:46Z"
status: "True"
type: Addressable
- lastTransitionTime: "2020-05-13T14:43:46Z"
status: "True"
type: ChannelServiceReady
- lastTransitionTime: "2020-05-13T14:43:40Z"
status: "True"
type: ConfigurationReady
- lastTransitionTime: "2020-05-13T14:43:46Z"
status: "True"
type: DispatcherReady
- lastTransitionTime: "2020-05-13T14:43:46Z"
status: "True"
type: EndpointsReady
- lastTransitionTime: "2020-05-13T14:43:46Z"
status: "True"
type: Ready
- lastTransitionTime: "2020-05-13T14:43:41Z"
status: "True"
type: ServiceReady
- lastTransitionTime: "2020-05-13T14:43:41Z"
status: "True"
type: TopicReady |
and here is what the actual broker looks, when applying the snippet from above: apiVersion: eventing.knative.dev/v1beta1
kind: Broker
metadata:
annotations:
eventing.knative.dev/broker.class: ChannelBasedBroker
eventing.knative.dev/creator: minikube-user
eventing.knative.dev/lastModifier: minikube-user
kubectl.kubernetes.io/last-applied-configuration: |
{"apiVersion":"eventing.knative.dev/v1alpha1","kind":"Broker","metadata":{"annotations":{},"name":"default","namespace":"default"},"spec":{"channelTemplateSpec":{"apiVersion":"messaging.knative.dev/v1alpha1","kind":"KafkaChannel","spec":{"numPartitions":3,"replicationFactor":1}}}}
creationTimestamp: "2020-05-13T14:43:40Z"
finalizers:
- brokers.eventing.knative.dev
generation: 1
managedFields:
- apiVersion: eventing.knative.dev/v1alpha1
fieldsType: FieldsV1
fieldsV1:
f:metadata:
f:annotations:
.: {}
f:kubectl.kubernetes.io/last-applied-configuration: {}
f:spec:
.: {}
f:channelTemplateSpec:
.: {}
f:apiVersion: {}
f:kind: {}
f:spec:
.: {}
f:numPartitions: {}
f:replicationFactor: {}
manager: kubectl
operation: Update
time: "2020-05-13T14:43:40Z"
- apiVersion: eventing.knative.dev/v1alpha1
fieldsType: FieldsV1
fieldsV1:
f:metadata:
f:finalizers:
.: {}
v:"brokers.eventing.knative.dev": {}
f:status:
.: {}
f:address:
.: {}
f:hostname: {}
f:url: {}
f:conditions: {}
f:observedGeneration: {}
f:triggerChannel:
.: {}
f:apiVersion: {}
f:kind: {}
f:name: {}
f:namespace: {}
manager: channel_broker
operation: Update
time: "2020-05-13T14:43:47Z"
name: default
namespace: default
resourceVersion: "2651"
selfLink: /apis/eventing.knative.dev/v1beta1/namespaces/default/brokers/default
uid: cf62c7de-5761-4b11-8418-32a0c7437f73
spec:
config:
apiVersion: v1
kind: ConfigMap
name: config-br-default-channel
namespace: knative-eventing
status:
address:
url: http://default-broker.default.svc.cluster.local
conditions:
- lastTransitionTime: "2020-05-13T14:43:46Z"
status: "True"
type: Addressable
- lastTransitionTime: "2020-05-13T14:43:46Z"
message: Endpoints "default-broker-filter" are unavailable.
reason: EndpointsUnavailable
status: "False"
type: FilterReady
- lastTransitionTime: "2020-05-13T14:43:46Z"
message: Endpoints "default-broker" are unavailable.
reason: EndpointsUnavailable
status: "False"
type: IngressReady
- lastTransitionTime: "2020-05-13T14:43:47Z"
message: Endpoints "default-broker-filter" are unavailable.
reason: EndpointsUnavailable
status: "False"
type: Ready
- lastTransitionTime: "2020-05-13T14:43:46Z"
status: "True"
type: TriggerChannelReady
observedGeneration: 1 looks like the conversion has already somewhat transformed it |
@matzew Did you label the namespace? I can repro what you see if I don't label the namespace, and the symptom that I see if I look ad deployments, they fail with:
But, there were two ways I was testing:
I did the second one for a bit, then decided to just comment it out for testing purposes :) IIRC, you didn't have problems with the MT Broker? That would also support the theory of not having labeled the namespace possibly being a problem here? |
Thanks @matzew I think I addressed all your comments, ptal. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Produced via:
prettier --write --prose-wrap=always $(find -name '*.md' | grep -v vendor | grep -v .github | grep -v docs/cmd/)
/test pull-knative-eventing-unit-tests |
/test pull-knative-eventing-integration-tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Produced via:
prettier --write --prose-wrap=always $(find -name '*.md' | grep -v vendor | grep -v .github | grep -v docs/cmd/)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/approve
/retest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great to see tests for this!
/lgtm
```yaml | ||
apiVersion: v1 | ||
data: | ||
channelTemplateSpec: |2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this 2 intentional?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, it's because of showing the block there:
https://yaml.org/spec/1.2/spec.html#id2793979
```yaml | ||
apiVersion: v1 | ||
data: | ||
channelTemplateSpec: |2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this 2 intentional?
a4f0392
to
ce330f8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Produced via:
prettier --write --prose-wrap=always $(find -name '*.md' | grep -v vendor | grep -v .github | grep -v docs/cmd/)
- apiVersion: eventing.knative.dev/v1alpha1 | ||
blockOwnerDeletion: true | ||
controller: true | ||
kind: Broker | ||
name: newbroker |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Format markdown:
- apiVersion: eventing.knative.dev/v1alpha1 | |
blockOwnerDeletion: true | |
controller: true | |
kind: Broker | |
name: newbroker | |
- apiVersion: eventing.knative.dev/v1alpha1 | |
blockOwnerDeletion: true | |
controller: true | |
kind: Broker | |
name: newbroker |
- apiVersion: eventing.knative.dev/v1alpha1 | ||
blockOwnerDeletion: true | ||
controller: true | ||
kind: Broker | ||
name: newbroker-kafka |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Format markdown:
- apiVersion: eventing.knative.dev/v1alpha1 | |
blockOwnerDeletion: true | |
controller: true | |
kind: Broker | |
name: newbroker-kafka | |
- apiVersion: eventing.knative.dev/v1alpha1 | |
blockOwnerDeletion: true | |
controller: true | |
kind: Broker | |
name: newbroker-kafka |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: grantr, n3wscott, vaikas The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
The following is the coverage report on the affected files.
|
Fixes #
Proposed Changes
Release Note
Docs