grafana / loki

Like Prometheus, but for logs.
https://grafana.com/loki
GNU Affero General Public License v3.0
23.87k stars 3.45k forks source link

Missing chunkDelimiter parameter for Azure storage in Helm chart #14010

Closed NGPixel closed 1 month ago

NGPixel commented 2 months ago

Describe the bug The Loki helm chart is missing the loki.storage.azure.chunkDelimiter parameter. This is needed when migrating from S3 (which uses :) to Azure Blob Storage (which uses - by default (why?!)).

To Reproduce Steps to reproduce the behavior:

  1. Set loki.storage.azure.chunkDelimiter to :
  2. Deploy to Kubernetes
  3. Delimiter is still using - because parameter is not set in the template.

Expected behavior Being able to set chunkDelimiter as part of the helm values.

Environment:

Screenshots, Promtail config, or terminal output N/A

vlad-diachenko commented 2 months ago

Hey @NGPixel . by default we replace : with - because Azure did not support a colon in object name through the SDK Loki uses under the hood. So, I believe it's useful to be able to customize chunkDelimiter in the helm chart but be aware that using a colon might bring the issue to your setup(not sure, because maybe Azure SDK already fixed the issue).

ubcharron commented 3 weeks ago

I think there's an issue issue with quoting. In chart version 6.18, helm fails to generate the template if I set chunkDelimiter to ":"

loki:
  storage:
    azure:
      chunkDelimiter: ":"

Error: 'error converting YAML to JSON: yaml: line 35: mapping values are not allowed in this context

I need to set it as follows for it to work:

chunkDelimiter: "\":\""

(And if it helps anybody else, I can confirm that Loki 3.2.0 works as expected when chunkDelimiter is set to ":" with Azure blob storage)