nrwl / nx-cloud-helm

Nx Cloud Helm Charts
30 stars 13 forks source link

Nx Cloud 2406.29.1.patch2 fails to store cache on Azure Blob Storage #142

Open minijus opened 1 month ago

minijus commented 1 month ago

It seems that 2406.29.1.patch2 introduced new way to upload artifacts by streaming them (with storeV2 method). Unfortunately, this does not work well with Azure Blob Storage.

PUT requests towards Azure Blob Storage fail with Request failed with status code 400: Image

New method: Image

Cammisuli commented 1 month ago

Sorry about that! You can get around the issue by setting useLegacyCache: true in the nx.json (for versions >= 20) and it will use the old implementation. Or by setting NX_DB_CACHE=false in the env.

I'll look into fixing this properly for azure.

minijus commented 1 month ago

Is there any documentation of presentation on what is this new DB cache and what is exactly controlled with useLegacyCache/NX_DB_CACHE?

minijus commented 1 month ago

Sorry about that! You can get around the issue by setting useLegacyCache: true in the nx.json (for versions >= 20) and it will use the old implementation. Or by setting NX_DB_CACHE=false in the env.

I'll look into fixing this properly for azure.

Setting both useLegacyCache: true in the nx.json and NX_DB_CACHE=false in the env and running npx npx nx-cloud record -- npx nx format:check still triggers storeV2 with uploadFileStream. Using nx v20.0.1 and NX Cloud 2406.29.1.patch2, cloud bundle downloaded test.0920162733.

minijus commented 13 hours ago

Update: this does not seem to be an issue with 2024.10Nx Cloud anymore. Not sure if it has streaming enabled, but removing useLegacyCache: true from nx.json does not trigger the error anymore.