<p>I've been running into this issue where every once in a while Knative will become unable to create new Deployments, and will spontaneously recover within a few hours and create it. Until then, the following errors keep playing out within the serving components. What it feels like to me is the requests to kubernetes service are timing out, but I cannot tell why.</p>
<h2>Expected Behavior</h2>
<p>On making updates to a service, expecting deployment of new revision to work.</p>
<h2>Actual Behavior</h2>
<p>Occasionally, while making valid changes <code>ex: changing the value of an annotation</code> Knative will become unable to deploy a new revision, getting stuck in the state of constantly trying to reconcile it for hours before spontaneously recovering.</p>
<pre><code>$ kn revision list -A
NAMESPACE        NAME                       SERVICE              TRAFFIC   TAGS      GENERATION   AGE         CONDITIONS   READY     REASON
knative       service-00033                  service                                 33           &lt;invalid&gt;   0 OK / 3     Unknown   Deploying
knative       service-00032                  service             100%      primary   32           &lt;invalid&gt;   4 OK / 4     True
</code></pre>
<p>In  the controller logs I see the following context deadline exceeded error while trying to post to the Kubernetes service IP:</p>
<pre><code>{
  &quot;insertId&quot;: &quot;plhs429mzmf9nh5f&quot;,
  &quot;jsonPayload&quot;: {
    &quot;logger&quot;: &quot;controller.event-broadcaster&quot;,
    &quot;caller&quot;: &quot;record/event.go:285&quot;,
    &quot;knative.dev/pod&quot;: &quot;controller-8c6b99cb7-7zg6n&quot;,
    &quot;commit&quot;: &quot;484e848&quot;,
    &quot;message&quot;: &quot;Event(v1.ObjectReference{Kind:\&quot;Revision\&quot;, Namespace:\&quot;knative\&quot;, Name:\&quot;service-00033\&quot;, UID:\&quot;8a09a3ff-655e-4e5f-b8d4-1a4886ab0678\&quot;, APIVersion:\&quot;serving.knative.dev/v1\&quot;, ResourceVersion:\&quot;1844291799\&quot;, FieldPath:\&quot;\&quot;}): type: 'Warning' reason: 'InternalError' failed to create deployment \&quot;service-api-00033-deployment\&quot;: Post \&quot;https://10.123.20.1:443/apis/apps/v1/namespaces/knative/deployments\&quot;: context deadline exceeded&quot;,
    &quot;timestamp&quot;: &quot;2023-06-30T09:57:08.7332053Z&quot;
  }
</code></pre>
<p>and right before it the following in Webhook logs:</p>
<pre><code>{
  &quot;insertId&quot;: &quot;k078pd2dmx16qrr7&quot;,
  &quot;jsonPayload&quot;: {
    &quot;knative.dev/pod&quot;: &quot;webhook-d44b476b8-89gbx&quot;,
    &quot;message&quot;: &quot;Failed the resource specific validation&quot;,
    &quot;knative.dev/operation&quot;: &quot;UPDATE&quot;,
    &quot;logger&quot;: &quot;webhook&quot;,
    &quot;knative.dev/name&quot;: &quot;service&quot;,
    &quot;knative.dev/subresource&quot;: &quot;&quot;,
    &quot;knative.dev/namespace&quot;: &quot;knative&quot;,
    &quot;knative.dev/kind&quot;: &quot;serving.knative.dev/v1, Kind=Service&quot;,
    &quot;knative.dev/resource&quot;: &quot;serving.knative.dev/v1, Resource=services&quot;,
    &quot;commit&quot;: &quot;484e848&quot;,
    &quot;knative.dev/userinfo&quot;: &quot;system:serviceaccount:service:default&quot;,
    &quot;timestamp&quot;: &quot;2023-06-30T09:56:38.327880939Z&quot;,
    &quot;caller&quot;: &quot;validation/validation_admit.go:183&quot;,
    &quot;stacktrace&quot;: &quot;knative.dev/pkg/webhook/resourcesemantics/validation.validate\n\tknative.dev/pkg@v0.0.0-20230117181655-247510c00e9d/webhook/resourcesemantics/validation/validation_admit.go:183\nknative.dev/pkg/webhook/resourcesemantics/validation.(*reconciler).Admit\n\tknative.dev/pkg@v0.0.0-20230117181655-247510c00e9d/webhook/resourcesemantics/validation/validation_admit.go:79\nknative.dev/pkg/webhook.admissionHandler.func1\n\tknative.dev/pkg@v0.0.0-20230117181655-247510c00e9d/webhook/admission.go:123\nnet/http.HandlerFunc.ServeHTTP\n\tnet/http/server.go:2109\nnet/http.(*ServeMux).ServeHTTP\n\tnet/http/server.go:2487\nknative.dev/pkg/webhook.(*Webhook).ServeHTTP\n\tknative.dev/pkg@v0.0.0-20230117181655-247510c00e9d/webhook/webhook.go:263\nknative.dev/pkg/network/handlers.(*Drainer).ServeHTTP\n\tknative.dev/pkg@v0.0.0-20230117181655-247510c00e9d/network/handlers/drain.go:113\nnet/http.serverHandler.ServeHTTP\n\tnet/http/server.go:2947\nnet/http.(*conn).serve\n\tnet/http/server.go:1991&quot;
  }
</code></pre>
<p>At a complete loss here at this point.</p>
<h2>Steps to Reproduce the Problem</h2>
<p>Unknown</p>

Desolar1um
<p>I haven't looked at your service yaml, but I have a hypothesis that this might be related to slow <a href="https://knative.dev/docs/serving/tag-resolution/" rel="nofollow noreferrer">tag to digest resolution</a>.  Your can try the following:</p>
<ol>
<li><p>Monitor latency for registry operations, particularly <code>GET</code> operations.</p>
</li>
<li><p>Use image digests when referencing images.  These look like <code>@sha256:...</code> rather than <code>:latest</code>, and ensure that the image does not change after deployment.</p>
</li>
<li><p>Disable tag to digest resolution.  Note that this can lead to unpredictable behavior if a referenced tag is moved.  Some instances may pick up the new image, while other instances may use an earlier image.</p>
</li>
</ol>
<p>If this is tag to digest resolution and you're using public Dockerhub images, adding pull credentials to the service account that's running the Knative Service might give you higher rate limits.</p>
