Skip to content

trace-export-event

Generated reference page for spec/v1/schemas/events/trace-export-event.json.

Metadata

  • Type: JSON Schema
  • Source: spec/v1/schemas/events/trace-export-event.json
  • Raw: View Raw

Summary

Source

json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://agent-service.spec/v1/schemas/events/trace-export-event.json",
  "$defs": {
    "TraceExportSource": {
      "type": "object",
      "additionalProperties": false,
      "required": ["component", "transport"],
      "properties": {
        "component": {
          "type": "string",
          "enum": ["runtime", "adapter", "collector"]
        },
        "transport": {
          "type": "string",
          "enum": ["http", "grpc", "queue", "memory", "event-adapter"]
        },
        "language": {
          "type": "string"
        },
        "runtimeVersion": {
          "type": "string"
        },
        "rawEventName": {
          "type": "string"
        }
      }
    },
    "CompletedAgentSpan": {
      "allOf": [
        {
          "$ref": "../resources/agent-span.json"
        },
        {
          "type": "object",
          "required": ["status", "endTime", "durationMs", "metrics"],
          "properties": {
            "status": {
              "enum": ["success", "failed", "cancelled", "timeout"]
            }
          }
        }
      ]
    },
    "TraceSpanCompletedEvent": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "schemaVersion",
        "type",
        "eventId",
        "emittedAt",
        "occurredAt",
        "source",
        "span"
      ],
      "properties": {
        "schemaVersion": {
          "type": "string",
          "const": "v1"
        },
        "type": {
          "type": "string",
          "const": "TRACE_SPAN_COMPLETED"
        },
        "eventId": {
          "$ref": "../common/identity.json#/$defs/eventId"
        },
        "emittedAt": {
          "$ref": "../common/identity.json#/$defs/timestamp"
        },
        "occurredAt": {
          "$ref": "../common/identity.json#/$defs/timestamp"
        },
        "deliveryAttempt": {
          "type": "integer",
          "minimum": 1
        },
        "source": {
          "$ref": "#/$defs/TraceExportSource"
        },
        "span": {
          "$ref": "#/$defs/CompletedAgentSpan"
        }
      }
    },
    "TraceSpanEventCapturedEvent": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "schemaVersion",
        "type",
        "eventId",
        "emittedAt",
        "occurredAt",
        "source",
        "event"
      ],
      "properties": {
        "schemaVersion": {
          "type": "string",
          "const": "v1"
        },
        "type": {
          "type": "string",
          "const": "TRACE_SPAN_EVENT_CAPTURED"
        },
        "eventId": {
          "$ref": "../common/identity.json#/$defs/eventId"
        },
        "emittedAt": {
          "$ref": "../common/identity.json#/$defs/timestamp"
        },
        "occurredAt": {
          "$ref": "../common/identity.json#/$defs/timestamp"
        },
        "deliveryAttempt": {
          "type": "integer",
          "minimum": 1
        },
        "source": {
          "$ref": "#/$defs/TraceExportSource"
        },
        "event": {
          "$ref": "../resources/trace-event.json"
        }
      }
    },
    "TraceExportAck": {
      "type": "object",
      "additionalProperties": false,
      "required": ["eventId", "accepted", "receivedAt"],
      "properties": {
        "eventId": {
          "$ref": "../common/identity.json#/$defs/eventId"
        },
        "accepted": {
          "type": "boolean"
        },
        "receivedAt": {
          "$ref": "../common/identity.json#/$defs/timestamp"
        },
        "ingestId": {
          "type": "string"
        },
        "reason": {
          "type": "string"
        }
      }
    }
  }
}

Generated from spec source.