This repository has been archived by the owner on Jun 19, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add rollout restart time annotation to Brokercell and update Brokerce…
…ll deployments (#1775) * Update docs for CloudBuildSource to use v1 * Add rollout restart time annotation to brokercell * add empty line * fix format * Rename annotation keys
- Loading branch information
Showing
8 changed files
with
400 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
107 changes: 107 additions & 0 deletions
107
pkg/reconciler/brokercell/testingdata/fanout_deployment_with_restart_annotation.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
# Copyright 2020 Google LLC | ||
|
||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
|
||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
|
||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# This yaml matches the fanout deployment objected created by the reconciler with | ||
# additional status so that reconciler will mark readiness based on the status. | ||
metadata: | ||
name: test-brokercell-brokercell-fanout | ||
namespace: testnamespace | ||
labels: | ||
app: cloud-run-events | ||
brokerCell: test-brokercell | ||
role: fanout | ||
ownerReferences: | ||
- apiVersion: internal.events.cloud.google.com/v1alpha1 | ||
kind: BrokerCell | ||
name: test-brokercell | ||
controller: true | ||
blockOwnerDeletion: true | ||
spec: | ||
selector: | ||
matchLabels: &labels | ||
app: cloud-run-events | ||
brokerCell: test-brokercell | ||
role: fanout | ||
minReadySeconds: 60 | ||
strategy: | ||
rollingUpdate: | ||
maxUnavailable: 0 | ||
maxSurge: 1 | ||
template: | ||
metadata: | ||
labels: *labels | ||
annotations: | ||
sidecar.istio.io/inject: "true" | ||
events.cloud.google.com/RestartRequestedAt: "2020-09-25T16:28:36-04:00" | ||
spec: | ||
serviceAccountName: broker | ||
terminationGracePeriodSeconds: 60 | ||
containers: | ||
- name: fanout | ||
image: fanout | ||
livenessProbe: | ||
failureThreshold: 3 | ||
httpGet: | ||
path: /healthz | ||
port: 8080 | ||
scheme: HTTP | ||
initialDelaySeconds: 15 | ||
periodSeconds: 15 | ||
successThreshold: 1 | ||
timeoutSeconds: 5 | ||
env: | ||
- name: GOOGLE_APPLICATION_CREDENTIALS | ||
value: /var/secrets/google/key.json | ||
- name: SYSTEM_NAMESPACE | ||
value: knative-testing | ||
- name: POD_NAME | ||
valueFrom: | ||
fieldRef: | ||
fieldPath: metadata.name | ||
- name: CONFIG_LOGGING_NAME | ||
value: config-logging | ||
- name: CONFIG_OBSERVABILITY_NAME | ||
value: config-observability | ||
- name: METRICS_DOMAIN | ||
value: knative.dev/internal/eventing | ||
- name: MAX_CONCURRENCY_PER_EVENT | ||
value: "100" | ||
volumeMounts: | ||
- name: broker-config | ||
mountPath: /var/run/cloud-run-events/broker | ||
- name: google-broker-key | ||
mountPath: /var/secrets/google | ||
resources: | ||
limits: | ||
memory: 3000Mi | ||
requests: | ||
cpu: 1500m | ||
memory: 3000Mi | ||
ports: | ||
- name: metrics | ||
containerPort: 9090 | ||
- name: http-health | ||
containerPort: 8080 | ||
volumes: | ||
- name: broker-config | ||
configMap: | ||
name: test-brokercell-brokercell-broker-targets | ||
- name: google-broker-key | ||
secret: | ||
secretName: google-broker-key | ||
optional: true | ||
status: | ||
conditions: | ||
- status: "True" | ||
type: Available |
116 changes: 116 additions & 0 deletions
116
pkg/reconciler/brokercell/testingdata/ingress_deployment_with_restart_annotation.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,116 @@ | ||
# Copyright 2020 Google LLC | ||
|
||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
|
||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
|
||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# This yaml matches the ingress deployment objected created by the reconciler with | ||
# additional status so that reconciler will mark readiness based on the status. | ||
metadata: | ||
name: test-brokercell-brokercell-ingress | ||
namespace: testnamespace | ||
labels: | ||
app: cloud-run-events | ||
brokerCell: test-brokercell | ||
role: ingress | ||
ownerReferences: | ||
- apiVersion: internal.events.cloud.google.com/v1alpha1 | ||
kind: BrokerCell | ||
name: test-brokercell | ||
controller: true | ||
blockOwnerDeletion: true | ||
spec: | ||
selector: | ||
matchLabels: &labels | ||
app: cloud-run-events | ||
brokerCell: test-brokercell | ||
role: ingress | ||
minReadySeconds: 60 | ||
strategy: | ||
rollingUpdate: | ||
maxUnavailable: 0 | ||
maxSurge: 1 | ||
template: | ||
metadata: | ||
labels: *labels | ||
annotations: | ||
sidecar.istio.io/inject: "true" | ||
events.cloud.google.com/RestartRequestedAt: "2020-09-25T16:28:36-04:00" | ||
spec: | ||
serviceAccountName: broker | ||
terminationGracePeriodSeconds: 60 | ||
containers: | ||
- name: ingress | ||
image: ingress | ||
livenessProbe: | ||
failureThreshold: 5 | ||
httpGet: | ||
path: /healthz | ||
port: 8080 | ||
scheme: HTTP | ||
initialDelaySeconds: 15 | ||
periodSeconds: 15 | ||
successThreshold: 1 | ||
timeoutSeconds: 5 | ||
readinessProbe: | ||
failureThreshold: 5 | ||
httpGet: | ||
path: /healthz | ||
port: 8080 | ||
scheme: HTTP | ||
periodSeconds: 15 | ||
successThreshold: 1 | ||
timeoutSeconds: 5 | ||
env: | ||
- name: GOOGLE_APPLICATION_CREDENTIALS | ||
value: /var/secrets/google/key.json | ||
- name: SYSTEM_NAMESPACE | ||
value: knative-testing | ||
- name: POD_NAME | ||
valueFrom: | ||
fieldRef: | ||
fieldPath: metadata.name | ||
- name: CONFIG_LOGGING_NAME | ||
value: config-logging | ||
- name: CONFIG_OBSERVABILITY_NAME | ||
value: config-observability | ||
- name: METRICS_DOMAIN | ||
value: knative.dev/internal/eventing | ||
- name: PORT | ||
value: "8080" | ||
volumeMounts: | ||
- name: broker-config | ||
mountPath: /var/run/cloud-run-events/broker | ||
- name: google-broker-key | ||
mountPath: /var/secrets/google | ||
resources: | ||
limits: | ||
memory: 2000Mi | ||
requests: | ||
cpu: 2000m | ||
memory: 2000Mi | ||
ports: | ||
- name: metrics | ||
containerPort: 9090 | ||
- name: http | ||
containerPort: 8080 | ||
volumes: | ||
- name: broker-config | ||
configMap: | ||
name: test-brokercell-brokercell-broker-targets | ||
- name: google-broker-key | ||
secret: | ||
secretName: google-broker-key | ||
optional: true | ||
status: | ||
conditions: | ||
- status: "True" | ||
type: Available |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.