<p>I have a service that uses SSE and therefore requires a long-living connection. I attempted to use the &quot;cloud.google.com/backend-config&quot; annotation to specify my back-end config but I keep getting an error indicating that the label is invalid. The error I receive is:</p>
<p>metadata.labels: Invalid value: &quot;\{&quot;default&quot;: &quot;my-backendconfig&quot;\}&quot;: a valid label must be an empty string or consist of alphanumeric characters, '-', '<em>' or '.', and must start and end with an alphanumeric character (e.g. 'MyValue',  or 'my_value',  or '12345', regex used for validation is '(([A-Za-z0-9][-A-Za-z0-9</em>.]*)?[A-Za-z0-9])?')</p>
<p>The value I am attempting to use is almost the exact same value I have seen in multiple examples including one from stack overflow <a href="https://stackoverflow.com/questions/36200528/how-to-configure-ingress-request-timeouts-on-gke">here</a></p>
<p>Here is the exact annotation I am using:</p>
<pre><code>cloud.google.com/backend-config: '{&quot;default&quot;: &quot;my-backendconfig&quot;}'
</code></pre>
<p>Note that I get this error when using my helm chart deployment as well as trying to manually update the service via the GKE console.</p>
<p>I am using version 1.25.10-gke.1200</p>
<p>I have tried to escape the brackets as well but of course this didn't help. As mentioned, I originally added this change to my helm chart and when I received the error I thought maybe helm didn't support these type of values. I then tried to update my currently deployed service directly in the Google Cloud admin console and I get the same error.</p>
<p>The backend config appears to be deployed successfully although based on the error I don't think  the service is getting that far down the road.  When I describe the backend config I see:</p>
<pre><code>Name:         my-backendconfig
Namespace:    ***
Labels:       &lt;none&gt;
Annotations:  &lt;none&gt;
API Version:  cloud.google.com/v1
Kind:         BackendConfig
Metadata:
  Creation Timestamp:  2023-08-14T14:41:51Z
  Generation:          1
  Resource Version:    865340930
  UID:                 ***
Spec:
  Connection Draining:
    Draining Timeout Sec:  1800
  Timeout Sec:             1800
Events:                    &lt;none&gt;
</code></pre>

Troy
<p>Ok, this was just a plain silly mistake. I had the annotation in the wrong place. The annotation was getting generated in the &quot;label&quot; section instead of &quot;annotations&quot;. Of course labels can only be text, thus the parsing error.</p>
