Verified Commit 99f27e6e authored by service-platforms-labkit's avatar service-platforms-labkit Committed by GitLab
Browse files

feat: update field constants from labkit-spec v1.0

parent a1276222
Loading
Loading
Loading
Loading
+13 −0
Original line number Diff line number Diff line
@@ -90,6 +90,12 @@ module Labkit
    # GitLab pipeline numeric ID.
    GL_PIPELINE_ID = "gl_pipeline_id"

    # GitLab namespace numeric ID.
    GL_NAMESPACE_ID = "gl_namespace_id"

    # GitLab root (top-level) namespace numeric ID.
    GL_ROOT_NAMESPACE_ID = "gl_root_namespace_id"

    # Log event timestamp in ISO 8601 format (e.g. "2026-04-02T12:00:00.000Z").
    TIMESTAMP = "timestamp"

@@ -122,6 +128,10 @@ module Labkit
    # The endpoint_id of the original caller at the root of the call chain.
    ROOT_CALLER_ID = "root_caller_id"

    # GitLab SentNotification record numeric ID associated with an incoming
    # email reply.
    GL_SENT_NOTIFICATION_ID = "gl_sent_notification_id"

    # Maps each field constant to its logging field variant version.
    # A version of 0 means the field is not yet assigned to any variant.
    VARIANT_VERSION = {
@@ -149,6 +159,8 @@ module Labkit
      TTFB_S => 0,
      GL_PROJECT_ID => 1,
      GL_PIPELINE_ID => 1,
      GL_NAMESPACE_ID => 0,
      GL_ROOT_NAMESPACE_ID => 0,
      TIMESTAMP => 0,
      SEVERITY => 0,
      LOG_MESSAGE => 1,
@@ -159,6 +171,7 @@ module Labkit
      ENDPOINT_ID => 0,
      CALLER_ID => 1,
      ROOT_CALLER_ID => 0,
      GL_SENT_NOTIFICATION_ID => 0,
    }.freeze

    # Get the constant name for a field value