Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Jaeger file export doc #73

Merged
merged 2 commits into from
Jul 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions docs/deployment-operations/errors.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,17 @@ Cannot propagate endpoint/service metadata to Restate components. If you see thi

We recommend wiping the Meta storage and recreate it by registering endpoints in the same order they were registered before.

## META0006 {#META0006}

Cannot register the newly discovered service revision in the provided service endpoint, because it conflicts with an already existing service revision.

When implementing a new service revision, make sure that:

* The service instance type and the key definition, if any, is exactly the same as of the previous revisions.
* The Protobuf contract and message definitions are backward compatible.

See the [versioning documentation](http://restate.dev/docs/deployment-operations/versioning) for more information.

## RT0001 {#RT0001}

The invocation response stream was aborted due to the timeout configured in `worker.invoker.response_abort_timeout`.
Expand Down
4 changes: 1 addition & 3 deletions docs/deployment-operations/observability.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,12 @@ You can configure a span/event filter in a similar fashion to the [Log filter](#

### Setup Jaeger file exporter

If you can't configure a Jaeger agent, you can still export traces writing them to files, using the Jaeger JSON format. In order to do so, setup the configuration entry `observability.jaeger_file.path` pointing towards the path where trace files should be written.
If you can't configure a Jaeger agent, you can still export traces writing them to files, using the Jaeger JSON format. In order to do so, setup the configuration entry `observability.tracing.json_file_export_path` pointing towards the path where trace files should be written.

You can import the trace files using the Jaeger UI:

![Jaeger UI File import](/img/jaeger-import-file.png)

You can configure a span/event filter in a similar fashion to the [Log filter](#log-filter) setting the `observability.jaeger_file.filter` configuration entry.

### Understanding traces

Similarly to logs, traces export [attributes/tags](#components-and-log-event-context-fields) that correlates the trace with the service and/or invocation. For example, you can filter directly in the Jaeger UI all the traces belonging to the service `org.example.ExampleService` by setting the tag filter `rpc.service=org.example.ExampleService`.
Expand Down
55 changes: 15 additions & 40 deletions static/schemas/config_schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
},
"observability": {
"default": {
"jaeger_file": null,
"log": {
"disable_ansi_codes": false,
"filter": "warn,restate=info",
Expand Down Expand Up @@ -60,7 +59,7 @@
"type": "Exponential"
},
"suspension_timeout": "1m",
"tmp_dir": "/tmp/invoker-01893fd5353b7bec8ee359e5661f0ec9"
"tmp_dir": "/tmp/invoker-01896e5bc84973bfa8611d235bd766e7"
},
"partitions": 1024,
"storage_grpc": {
Expand Down Expand Up @@ -103,17 +102,6 @@
}
]
},
"jaeger_file": {
"title": "Jaeger file exporter options",
"anyOf": [
{
"$ref": "#/definitions/JaegerFileOptions"
},
{
"type": "null"
}
]
},
"log": {
"title": "Logging options",
"default": {
Expand All @@ -127,37 +115,24 @@
},
"TracingOptions": {
"title": "Tracing Options",
"description": "Configuration for the [OTLP exporter](https://opentelemetry.io/docs/specs/otel/protocol/exporter/) which can export to all OTLP compatible systems (e.g. Jaeger).\n\nTo configure the sampling, please refer to the [opentelemetry autoconfigure docs](https://github.com/open-telemetry/opentelemetry-java/blob/main/sdk-extensions/autoconfigure/README.md#sampler).",
"description": "Configuration for the [OTLP exporter](https://opentelemetry.io/docs/specs/otel/protocol/exporter/) which can export to all OTLP compatible systems (e.g. Jaeger).\n\nAt least `endpoint` or `json_file_export_path` must be configured.\n\nTo configure the sampling, please refer to the [opentelemetry autoconfigure docs](https://github.com/open-telemetry/opentelemetry-java/blob/main/sdk-extensions/autoconfigure/README.md#sampler).",
"type": "object",
"required": [
"endpoint"
],
"properties": {
"endpoint": {
"title": "Endpoint",
"description": "Specify the tracing endpoint to send traces to. Traces will be exported using [OTLP gRPC](https://opentelemetry.io/docs/specs/otlp/#otlpgrpc) through [opentelemetry_otlp](https://docs.rs/opentelemetry-otlp/0.12.0/opentelemetry_otlp/).",
"type": "string"
"type": [
"string",
"null"
]
},
"filter": {
"title": "Filter",
"description": "Exporter filter configuration. Check the [`RUST_LOG` documentation](https://docs.rs/tracing-subscriber/latest/tracing_subscriber/filter/struct.EnvFilter.html) for more details how to configure it.",
"default": "info",
"type": "string"
}
}
},
"JaegerFileOptions": {
"title": "Jaeger File Options",
"description": "Configuration for the Jaeger file exporter. This exporter writes traces as JSON in the Jaeger format.\n\nIt can be used to export traces in a structured format without configuring a Jaeger agent. To inspect the traces, open the Jaeger UI and use the Upload JSON feature to load and inspect them.\n\nAll spans will be sampled.",
"type": "object",
"required": [
"path"
],
"properties": {
"path": {
"title": "Path",
"description": "Specify the path where all the traces will be exported. Each trace file will start with the `trace` prefix.",
"type": "string"
"json_file_export_path": {
"title": "JSON File export path",
"description": "If set, an exporter will be configured to write traces to files using the Jaeger JSON format. Each trace file will start with the `trace` prefix.\n\nIf unset, no traces will be written to file.\n\nIt can be used to export traces in a structured format without configuring a Jaeger agent.\n\nTo inspect the traces, open the Jaeger UI and use the Upload JSON feature to load and inspect them.",
"type": [
"string",
"null"
]
},
"filter": {
"title": "Filter",
Expand Down Expand Up @@ -318,7 +293,7 @@
"type": "Exponential"
},
"suspension_timeout": "1m",
"tmp_dir": "/tmp/invoker-01893fd5353b779bab84357e232b3902"
"tmp_dir": "/tmp/invoker-01896e5bc8497142be25b3bd060cdfae"
},
"$ref": "#/definitions/InvokerOptions"
},
Expand Down Expand Up @@ -529,7 +504,7 @@
"tmp_dir": {
"title": "Temporary directory",
"description": "Temporary directory to use for the invoker temporary files. If empty, the system temporary directory will be used instead.",
"default": "/tmp/invoker-01893fd5353b75108708e8fae7d40579",
"default": "/tmp/invoker-01896e5bc8497fd4acc531b925d96c7f",
"type": "string"
},
"concurrency_limit": {
Expand Down
2 changes: 1 addition & 1 deletion static/schemas/openapi-meta.json

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion static/schemas/restate.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
shutdown_grace_period: 1m
observability:
tracing: null
jaeger_file: null
log:
filter: warn,restate=info
format: Pretty
Expand Down