Skip to content

Elasticsearch Storage

Doc

json
{
  "took" : 13,
  "timed_out" : false,
  "_shards" : {
    "total" : 1,
    "successful" : 1,
    "skipped" : 0,
    "failed" : 0
  },
  "hits" : {
    "total" : {
      "value" : 81,
      "relation" : "eq"
    },
    "max_score" : 1.0,
    "hits" : [
      {
        "_index" : "teletrace-traces",
        "_id" : "78817076c9cd460b",
        "_score" : 1.0,
        "_source" : {
          "resource" : {
            "attributes" : {
              "host.name" : "183ac322db40",
              "process.command_args" : [
                "/app/main"
              ],
              "process.executable.name" : "main",
              "process.executable.path" : "/app/main",
              "process.owner" : "root",
              "process.pid" : 1,
              "process.runtime.description" : "go version go1.18.10 linux/arm64",
              "process.runtime.name" : "go",
              "process.runtime.version" : "go1.18.10",
              "service.name" : "demo-server",
              "telemetry.sdk.language" : "go",
              "telemetry.sdk.name" : "opentelemetry",
              "telemetry.sdk.version" : "1.11.2"
            },
            "droppedAttributesCount" : 0
          },
          "scope" : {
            "name" : "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp",
            "version" : "semver:0.37.0",
            "attributes" : { },
            "droppedAttributesCount" : 0
          },
          "span" : {
            "traceId" : "1cb33ab03e6864be0bde9716a49be89b",
            "spanId" : "78817076c9cd460b",
            "traceState" : "",
            "parentSpanId" : "6472d7eccbd5f820",
            "name" : "/hello",
            "kind" : "Server",
            "startTimeUnixNano" : 1747908105861,
            "endTimeUnixNano" : 1747908106545,
            "attributes" : {
              "baggage key:client" : "cli",
              "baggage key:method" : "repl",
              "http.flavor" : "1.1",
              "http.host" : "demo-server:7080",
              "http.method" : "GET",
              "http.scheme" : "http",
              "http.server_name" : "/hello",
              "http.status_code" : 200,
              "http.target" : "/hello",
              "http.user_agent" : "Go-http-client/1.1",
              "http.wrote_bytes" : 11,
              "net.host.name" : "demo-server",
              "net.host.port" : 7080,
              "net.peer.ip" : "192.168.97.6",
              "net.peer.port" : 34214,
              "net.transport" : "ip_tcp",
              "server-attribute" : "foo"
            },
            "droppedAttributesCount" : 0,
            "droppedEventsCount" : 0,
            "droppedLinksCount" : 0,
            "status" : {
              "message" : "",
              "code" : "Unset"
            }
          },
          "externalFields" : {
            "durationNano" : 683
          },
          "ingestionTimeUnixNano" : 0
        }
      }
    ]
  }
}

Mapping Field

json
{
  "teletrace-traces": {
    "mappings": {
      "scope.name": {
        "full_name": "scope.name",
        "mapping": {
          "name": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.telemetry.sdk.name": {
        "full_name": "resource.attributes.telemetry.sdk.name",
        "mapping": {
          "name": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.status.message.keyword": {
        "full_name": "span.status.message.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.http.url.keyword": {
        "full_name": "span.attributes.http.url.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "resource.attributes.process.runtime.version": {
        "full_name": "resource.attributes.process.runtime.version",
        "mapping": {
          "version": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.host.name.keyword": {
        "full_name": "resource.attributes.host.name.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "scope.droppedAttributesCount": {
        "full_name": "scope.droppedAttributesCount",
        "mapping": {
          "droppedAttributesCount": {
            "type": "long"
          }
        }
      },
      "span.attributes.net.host.name": {
        "full_name": "span.attributes.net.host.name",
        "mapping": {
          "name": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.droppedAttributesCount": {
        "full_name": "span.droppedAttributesCount",
        "mapping": {
          "droppedAttributesCount": {
            "type": "long"
          }
        }
      },
      "span.attributes.http.scheme": {
        "full_name": "span.attributes.http.scheme",
        "mapping": {
          "scheme": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "_version": {
        "full_name": "_version",
        "mapping": {}
      },
      "span.attributes.http.scheme.keyword": {
        "full_name": "span.attributes.http.scheme.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.net.host.port": {
        "full_name": "span.attributes.net.host.port",
        "mapping": {
          "port": {
            "type": "long"
          }
        }
      },
      "span.attributes.server-attribute": {
        "full_name": "span.attributes.server-attribute",
        "mapping": {
          "server-attribute": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.process.runtime.description.keyword": {
        "full_name": "resource.attributes.process.runtime.description.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.status.code.keyword": {
        "full_name": "span.status.code.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.http.host.keyword": {
        "full_name": "span.attributes.http.host.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "resource.attributes.process.executable.path": {
        "full_name": "resource.attributes.process.executable.path",
        "mapping": {
          "path": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.http.status_code": {
        "full_name": "span.attributes.http.status_code",
        "mapping": {
          "status_code": {
            "type": "long"
          }
        }
      },
      "span.status.code": {
        "full_name": "span.status.code",
        "mapping": {
          "code": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.net.transport.keyword": {
        "full_name": "span.attributes.net.transport.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "externalFields.durationNano": {
        "full_name": "externalFields.durationNano",
        "mapping": {
          "durationNano": {
            "type": "long"
          }
        }
      },
      "span.droppedEventsCount": {
        "full_name": "span.droppedEventsCount",
        "mapping": {
          "droppedEventsCount": {
            "type": "long"
          }
        }
      },
      "resource.attributes.process.executable.path.keyword": {
        "full_name": "resource.attributes.process.executable.path.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "resource.attributes.telemetry.sdk.version": {
        "full_name": "resource.attributes.telemetry.sdk.version",
        "mapping": {
          "version": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.process.runtime.description": {
        "full_name": "resource.attributes.process.runtime.description",
        "mapping": {
          "description": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "_source": {
        "full_name": "_source",
        "mapping": {}
      },
      "resource.attributes.service.name": {
        "full_name": "resource.attributes.service.name",
        "mapping": {
          "name": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.process.executable.name": {
        "full_name": "resource.attributes.process.executable.name",
        "mapping": {
          "name": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.name": {
        "full_name": "span.name",
        "mapping": {
          "name": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.startTimeUnixNano": {
        "full_name": "span.startTimeUnixNano",
        "mapping": {
          "startTimeUnixNano": {
            "type": "long"
          }
        }
      },
      "span.attributes.http.flavor.keyword": {
        "full_name": "span.attributes.http.flavor.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "resource.attributes.service.name.keyword": {
        "full_name": "resource.attributes.service.name.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "resource.attributes.telemetry.sdk.name.keyword": {
        "full_name": "resource.attributes.telemetry.sdk.name.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.parentSpanId": {
        "full_name": "span.parentSpanId",
        "mapping": {
          "parentSpanId": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "scope.name.keyword": {
        "full_name": "scope.name.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.kind": {
        "full_name": "span.kind",
        "mapping": {
          "kind": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.net.peer.ip.keyword": {
        "full_name": "span.attributes.net.peer.ip.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.status.message": {
        "full_name": "span.status.message",
        "mapping": {
          "message": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.host.name": {
        "full_name": "resource.attributes.host.name",
        "mapping": {
          "name": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.http.url": {
        "full_name": "span.attributes.http.url",
        "mapping": {
          "url": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.http.host": {
        "full_name": "span.attributes.http.host",
        "mapping": {
          "host": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.process.command_args": {
        "full_name": "resource.attributes.process.command_args",
        "mapping": {
          "command_args": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.http.server_name": {
        "full_name": "span.attributes.http.server_name",
        "mapping": {
          "server_name": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.traceId": {
        "full_name": "span.traceId",
        "mapping": {
          "traceId": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.baggage key:client.keyword": {
        "full_name": "span.attributes.baggage key:client.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.traceState.keyword": {
        "full_name": "span.traceState.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "_nested_path": {
        "full_name": "_nested_path",
        "mapping": {}
      },
      "_field_names": {
        "full_name": "_field_names",
        "mapping": {}
      },
      "scope.version": {
        "full_name": "scope.version",
        "mapping": {
          "version": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.net.peer.port": {
        "full_name": "span.attributes.net.peer.port",
        "mapping": {
          "port": {
            "type": "long"
          }
        }
      },
      "resource.attributes.process.executable.name.keyword": {
        "full_name": "resource.attributes.process.executable.name.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "_feature": {
        "full_name": "_feature",
        "mapping": {}
      },
      "span.traceId.keyword": {
        "full_name": "span.traceId.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "_ignored": {
        "full_name": "_ignored",
        "mapping": {}
      },
      "resource.attributes.process.pid": {
        "full_name": "resource.attributes.process.pid",
        "mapping": {
          "pid": {
            "type": "long"
          }
        }
      },
      "span.traceState": {
        "full_name": "span.traceState",
        "mapping": {
          "traceState": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.parentSpanId.keyword": {
        "full_name": "span.parentSpanId.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.http.target": {
        "full_name": "span.attributes.http.target",
        "mapping": {
          "target": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.endTimeUnixNano": {
        "full_name": "span.endTimeUnixNano",
        "mapping": {
          "endTimeUnixNano": {
            "type": "long"
          }
        }
      },
      "_routing": {
        "full_name": "_routing",
        "mapping": {}
      },
      "_doc_count": {
        "full_name": "_doc_count",
        "mapping": {}
      },
      "resource.attributes.process.runtime.version.keyword": {
        "full_name": "resource.attributes.process.runtime.version.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.spanId": {
        "full_name": "span.spanId",
        "mapping": {
          "spanId": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.http.target.keyword": {
        "full_name": "span.attributes.http.target.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "resource.attributes.process.runtime.name.keyword": {
        "full_name": "resource.attributes.process.runtime.name.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.baggage key:client": {
        "full_name": "span.attributes.baggage key:client",
        "mapping": {
          "baggage key:client": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "_tier": {
        "full_name": "_tier",
        "mapping": {}
      },
      "_seq_no": {
        "full_name": "_seq_no",
        "mapping": {}
      },
      "span.attributes.http.method": {
        "full_name": "span.attributes.http.method",
        "mapping": {
          "method": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.net.peer.ip": {
        "full_name": "span.attributes.net.peer.ip",
        "mapping": {
          "ip": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.process.owner": {
        "full_name": "resource.attributes.process.owner",
        "mapping": {
          "owner": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "ingestionTimeUnixNano": {
        "full_name": "ingestionTimeUnixNano",
        "mapping": {
          "ingestionTimeUnixNano": {
            "type": "long"
          }
        }
      },
      "_id": {
        "full_name": "_id",
        "mapping": {}
      },
      "resource.attributes.process.command_args.keyword": {
        "full_name": "resource.attributes.process.command_args.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "scope.version.keyword": {
        "full_name": "scope.version.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "_index": {
        "full_name": "_index",
        "mapping": {}
      },
      "resource.attributes.telemetry.sdk.language": {
        "full_name": "resource.attributes.telemetry.sdk.language",
        "mapping": {
          "language": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.telemetry.sdk.version.keyword": {
        "full_name": "resource.attributes.telemetry.sdk.version.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.spanId.keyword": {
        "full_name": "span.spanId.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.net.host.name.keyword": {
        "full_name": "span.attributes.net.host.name.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "_data_stream_timestamp": {
        "full_name": "_data_stream_timestamp",
        "mapping": {}
      },
      "span.attributes.http.user_agent": {
        "full_name": "span.attributes.http.user_agent",
        "mapping": {
          "user_agent": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.http.flavor": {
        "full_name": "span.attributes.http.flavor",
        "mapping": {
          "flavor": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "resource.attributes.telemetry.sdk.language.keyword": {
        "full_name": "resource.attributes.telemetry.sdk.language.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.http.server_name.keyword": {
        "full_name": "span.attributes.http.server_name.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.droppedLinksCount": {
        "full_name": "span.droppedLinksCount",
        "mapping": {
          "droppedLinksCount": {
            "type": "long"
          }
        }
      },
      "resource.droppedAttributesCount": {
        "full_name": "resource.droppedAttributesCount",
        "mapping": {
          "droppedAttributesCount": {
            "type": "long"
          }
        }
      },
      "resource.attributes.process.owner.keyword": {
        "full_name": "resource.attributes.process.owner.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.http.wrote_bytes": {
        "full_name": "span.attributes.http.wrote_bytes",
        "mapping": {
          "wrote_bytes": {
            "type": "long"
          }
        }
      },
      "span.attributes.baggage key:method.keyword": {
        "full_name": "span.attributes.baggage key:method.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.http.user_agent.keyword": {
        "full_name": "span.attributes.http.user_agent.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "resource.attributes.process.runtime.name": {
        "full_name": "resource.attributes.process.runtime.name",
        "mapping": {
          "name": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.name.keyword": {
        "full_name": "span.name.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.kind.keyword": {
        "full_name": "span.kind.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.server-attribute.keyword": {
        "full_name": "span.attributes.server-attribute.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      },
      "span.attributes.net.transport": {
        "full_name": "span.attributes.net.transport",
        "mapping": {
          "transport": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.baggage key:method": {
        "full_name": "span.attributes.baggage key:method",
        "mapping": {
          "baggage key:method": {
            "type": "text",
            "fields": {
              "keyword": {
                "type": "keyword",
                "ignore_above": 256
              }
            }
          }
        }
      },
      "span.attributes.http.method.keyword": {
        "full_name": "span.attributes.http.method.keyword",
        "mapping": {
          "keyword": {
            "type": "keyword",
            "ignore_above": 256
          }
        }
      }
    }
  }
}