From 9442b814ea7b08235f3af9fef0c0a9ea814dc699 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Tich=C3=A1k?= Date: Fri, 3 Jul 2026 16:38:45 +0200 Subject: [PATCH] [control-operator] disable grpc streams for time being --- control-operator/internal/controller/grpc_client.go | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/control-operator/internal/controller/grpc_client.go b/control-operator/internal/controller/grpc_client.go index 3b82f4e4..1ae82df0 100644 --- a/control-operator/internal/controller/grpc_client.go +++ b/control-operator/internal/controller/grpc_client.go @@ -171,11 +171,16 @@ func (c *OccClient) ConsumeIfReady(ctx context.Context) bool { c.log.V(1).Info("connection is in different state than ready", "conn state", connState.String()) return false } - clientCtx, clientCancel := context.WithCancel(context.Background()) + // clientCtx, clientCancel := context.WithCancel(context.Background()) + _, clientCancel := context.WithCancel(context.Background()) c.cancel = &clientCancel - go c.ConsumeEventStream(clientCtx) - go c.ConsumeStateStream(clientCtx) + // TODO: Streams are not used anywhere now so we turn them off until they are fixed/useful + // they are not useful for now because any Transition call imediately returns final + // status. So for now we don't need them. Of course the problem is that if something + // changes inside OCC container we have no way how to detect it now. + // go c.ConsumeEventStream(clientCtx) + // go c.ConsumeStateStream(clientCtx) return true }