firebase-tools icon indicating copy to clipboard operation
firebase-tools copied to clipboard

Allow keeping cloud function image artifacts

Open dannnnthemannnn opened this issue 3 years ago • 1 comments

I am trying to redeploy my cloud function v2 with a slightly different configuration. My goal is to enable CPU allocation at all times rather than not having CPU allocated when the function is not processing requests. As it stands now, my spanner connection is being killed while CPU is not allocated between requests. I have min instances > 1 to avoid cold starts.

I cant update the cloud run service to enable CPU allocation because the build artifiact is not present any longer, so when I try to redeploy with updated settings, it fails to redeploy.

https://cloud.google.com/run/docs/configuring/cpu-allocation

Please submit feature requests through our support page.

dannnnthemannnn avatar Aug 30 '22 20:08 dannnnthemannnn

This is a great feature request. Our teammate suggested this might be a new flag in firebase.json:

"functions": {
  "artifactHistoryLength": 2
}

This will have to go through our API review process, but if anyone is interested in contributing let me know. When someone in our team begins working on this FR, I'll share an update here.

taeold avatar Sep 06 '22 21:09 taeold