Skip to content

Conversation

@anantadwi13
Copy link
Contributor

@anantadwi13 anantadwi13 commented Jun 18, 2025

Description

There are so many cloud providers out there. This PR is used to add templating for pod log urls. Instead of relying only on Stackdriver logs (which is a Google product), we give our users the ability to create their own log urls. There are some variables that can be used by our users.

Image Builder Log

  1. Available Variables
  • cluster_name (string)
  • namespace_name (string)
  • job_name (string)
  • start_time (string)
  • end_time (string)
  1. Usage
# merlin config.yaml

FeatureToggleConfig:
  LogConfig:
    LogImageBuilderURL: https://logviewer.sample.local/logs/viewer?cluster={{cluster_name}}&namespace={{namespace_name}}&job={{job_name}}

# it generates
# https://logviewer.sample.local/logs/viewer?cluster=caraml-cluster&namespace=caraml-namespace&job=job-caraml

Model Log

  1. Available Variables
  • cluster_name (string)
  • namespace_name (string)
  • pod_names (array of {value, is_first})
  • start_time (string)
  1. Usage
# merlin config.yaml

FeatureToggleConfig:
  LogConfig:
    LogModelURL: https://logviewer.sample.local/logs/viewer?cluster={{cluster_name}}&namespace={{namespace_name}}&pods={{#pod_names}}{{#is_first}}{{value}}{{/is_first}}{{^is_first}},{{value}}{{/is_first}}{{/pod_names}}

# it generates
# https://logviewer.sample.local/logs/viewer?cluster=caraml-cluster&namespace=caraml-namespace&pods=pod-1,pod-2,pod-3

Modifications

BE

  • add LogImageBuilderURL and LogModelURL

FE

  • add mustache templating
  • change Stackdriver urls to custom log url with backward compatibility

Tests

Checklist

  • Added PR label
  • Added unit test, integration, and/or e2e tests
  • Tested locally
  • Updated documentation
  • Update Swagger spec if the PR introduce API changes
  • Regenerated Golang and Python client if the PR introduces API changes

Release Notes


@anantadwi13 anantadwi13 added enhancement New feature or request breaking Breaking change, not backward compatible labels Jun 18, 2025
@anantadwi13 anantadwi13 self-assigned this Jun 18, 2025
@anantadwi13
Copy link
Contributor Author

i'm going to update this pr to add backward compatibility to the stackdriver url

@anantadwi13 anantadwi13 removed the breaking Breaking change, not backward compatible label Jul 21, 2025
Copy link
Contributor

@deadlycoconuts deadlycoconuts left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot for this PR! Everything looks good 🚀 I just left one comment but that's all 😅

@anantadwi13 anantadwi13 force-pushed the update-merlin-logging-url branch from b565bd1 to 384ef9d Compare July 25, 2025 11:40
@anantadwi13 anantadwi13 merged commit e896a5c into main Jul 25, 2025
32 checks passed
@anantadwi13 anantadwi13 deleted the update-merlin-logging-url branch July 25, 2025 12:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants