Skip to content

Commit 8414824

Browse files
committed
Add telemetry api timeouts
1 parent dfc0ead commit 8414824

2 files changed

Lines changed: 8 additions & 0 deletions

File tree

apis/core/v1beta1/openstackcontrolplane_webhook.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -853,6 +853,8 @@ func (r *OpenStackControlPlane) DefaultServices() {
853853
r.Spec.Telemetry.Template = &telemetryv1.TelemetrySpecCore{}
854854
}
855855
r.Spec.Telemetry.Template.Default()
856+
initializeOverrideSpec(&r.Spec.Telemetry.AodhAPIOverride.Route, true)
857+
r.Spec.Telemetry.Template.Autoscaling.SetDefaultRouteAnnotations(r.Spec.Telemetry.AodhAPIOverride.Route.Annotations)
856858
}
857859

858860
// Heat

tests/functional/ctlplane/openstackoperator_controller_test.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -587,6 +587,9 @@ var _ = Describe("OpenStackOperator controller", func() {
587587
//Expect(OSCtlplane.Spec.Octavia.APIOverride.Route).Should(Not(BeNil()))
588588
//Expect(OSCtlplane.Spec.Octavia.APIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "120s"))
589589
//Expect(OSCtlplane.Spec.Octavia.APIOverride.Route.Annotations).Should(HaveKeyWithValue("api.octavia.openstack.org/timeout", "120s"))
590+
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route).Should(Not(BeNil()))
591+
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "60s"))
592+
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route.Annotations).Should(HaveKeyWithValue("api.aodh.openstack.org/timeout", "60s"))
590593
})
591594

592595
It("should create selfsigned issuer and public+internal CA and issuer", func() {
@@ -861,6 +864,9 @@ var _ = Describe("OpenStackOperator controller", func() {
861864
Expect(OSCtlplane.Spec.Heat.CnfAPIOverride.Route).Should(Not(BeNil()))
862865
Expect(OSCtlplane.Spec.Heat.CnfAPIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "600s"))
863866
Expect(OSCtlplane.Spec.Heat.CnfAPIOverride.Route.Annotations).Should(HaveKeyWithValue("api.heat.openstack.org/timeout", "600s"))
867+
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route).Should(Not(BeNil()))
868+
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route.Annotations).Should(HaveKeyWithValue("haproxy.router.openshift.io/timeout", "60s"))
869+
Expect(OSCtlplane.Spec.Telemetry.AodhAPIOverride.Route.Annotations).Should(HaveKeyWithValue("api.aodh.openstack.org/timeout", "60s"))
864870
})
865871

866872
It("should create selfsigned issuer and public, internal, libvirt and ovn CA and issuer", func() {

0 commit comments

Comments
 (0)