Skip to content

[Inference] Move tracing config to @kbn/tracing#225417

Merged
dgieselaar merged 10 commits intoelastic:mainfrom
dgieselaar:move-inference-processors
Jul 1, 2025
Merged

[Inference] Move tracing config to @kbn/tracing#225417
dgieselaar merged 10 commits intoelastic:mainfrom
dgieselaar:move-inference-processors

Conversation

@dgieselaar
Copy link
Contributor

@dgieselaar dgieselaar commented Jun 26, 2025

This moves the initialization of phoenix/langfuse processors+exporters to @kbn/tracing. Previously the Inference plugin initialized and registered them.

Why

We need to use the tracing spans outside of the Kibana application as well - for instance when running evaluations or other CLI-based workflows. This doesn't work if Kibana server manages the exporter, as it has no visibility in spans created outside of the process.

The configuration path moves from xpack.inference.tracing.exporter.{phoenix,langfuse} to telemetry.tracing.exporter.{phoenix,langfuse}, without backwards compatibility.

Notes

  • These are registered as exporters but implemented as processors. The reason is that they need to use baggage to make sure all spans created in the context of an LLM workflow get marked and exported. So exporters are somewhat of a misnomer but it seems overkill to me to register both exporters and processors separately.
  • I'm backporting to 8.19 as well, given A) the risk of merge conflicts, B) the fact that this is disabled by default.
  • I'm assuming this is not a breaking change because this is not on by default and not document. If it is a breaking change I would need some guidance on how to use the
  • I used o3 to write documentation for @kbn/tracing and @kbn/inference-tracing.

@dgieselaar dgieselaar added release_note:skip Skip the PR/issue when compiling release notes backport:version Backport to applied version labels v9.1.0 v8.19.0 v9.2.0 labels Jun 26, 2025
@dgieselaar dgieselaar force-pushed the move-inference-processors branch from 844e9ee to bb55e90 Compare June 26, 2025 09:26
@dgieselaar dgieselaar marked this pull request as ready for review June 26, 2025 12:54
@dgieselaar dgieselaar requested review from a team as code owners June 26, 2025 12:54
@dgieselaar
Copy link
Contributor Author

@elasticmachine merge upstream

@rudolf rudolf requested a review from afharo June 30, 2025 10:10
Copy link
Contributor

@rudolf rudolf left a comment

Choose a reason for hiding this comment

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

If any clusters have values set for xpack.inference.tracing.exporter.{phoenix,langfuse} upgrading will cause their cluster to fail to start. It would be safer to deprecate these settings.

Copy link
Member

@afharo afharo left a comment

Choose a reason for hiding this comment

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

LGTM! I think that the breaking change is assumable since the original configs were introduced in 8.19 and 9.1, and they haven't been released yet. Let's make sure to backport these changes before the releases.

nit: I think that we should start grouping OTel packages in a directory (platform/packags/shared/opentelemetry/*). WDYT?

* and is temporary until we fully migrate to [OpenTelemetry
* tracing](https://github.com/elastic/kibana/issues/220914).
*/
const ctx = propagation.extract(context.active(), request.headers, defaultTextMapGetter);
Copy link
Member

Choose a reason for hiding this comment

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

I wonder if it's worth moving this to a previous handler. This way, the context can be reused for any previous lifecycle steps like authentication/authorization, validation, etc.

I don't think that it should block the PR, though. We can move it in a follow-up PR.

WDYT?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes makes sense: #225817

Copy link
Contributor Author

Choose a reason for hiding this comment

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

sorry, replied to the wrong comment - wdym with:

I wonder if it's worth moving this to a previous handler.

It should definitely happen as early as possible. where would I need to put it then?

Copy link
Member

@afharo afharo Jun 30, 2025

Choose a reason for hiding this comment

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

I was thinking about something similar to

private setupRequestStateAssignment(
.

Maybe we can store the context in the request.app in a similar fashion (only if it makes sense).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ah that does not actually work I think, you need to be able to wrap a callback

Comment on lines 11 to 12
export const RESOURCE_ATTR_SERVICE_NODE_NAME = 'service.node.name';
export const RESOURCE_ATTR_SERVICE_ENVIRONMENT = 'service.environment';
Copy link
Member

Choose a reason for hiding this comment

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

Do these conform to SemConv?

AFAIK, service.environment should be deployment.environment.name: https://opentelemetry.io/docs/specs/semconv/resource/deployment-environment/

Based on the definition of ServiceNodeName, should service.node.name be `container.name?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

cheers, will rename!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've changed to service.instance.id and service.namespace (which are both in development, so I'm defining them in @kbn/opentelemetry-attributes.

// Helpers to check if ID is not all zeros (spec prohibits all-zero ids)
const isAllZeros = (str: string) => /^0+$/.test(str);

export function fromTraceparent(traceparent: string): SpanContext | undefined {
Copy link
Member

Choose a reason for hiding this comment

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

😮 I'm surprised that this helper is not provided in the @opentelemetry libraries

Copy link
Contributor Author

Choose a reason for hiding this comment

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

me too, I'll have another look to see if I haven't missed anything.

"id": "@kbn/tracing-config",
"owner": "@elastic/kibana-core",
"group": "platform",
"visibility": "shared"
Copy link
Member

Choose a reason for hiding this comment

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

nit: I wonder if this should be "private"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

tbh I really don't get the point of private packages. Why should everything in x-pack/platform be able to import it, but nothing in x-pack/solutions/observability? but a topic for another day.. 😄

@dgieselaar
Copy link
Contributor Author

@elasticmachine merge upstream

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
@kbn/inference-tracing 17 19 +2
@kbn/inference-tracing-config - 1 +1
@kbn/opentelemetry-attributes - 9 +9
@kbn/opentelemetry-utils - 7 +7
@kbn/telemetry-config 0 1 +1
total +20

Public APIs missing exports

Total count of every type that is part of your API that should be exported but is not. This will cause broken links in the API documentation system. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats exports for more detailed information.

id before after diff
@kbn/inference-common 12 10 -2
@kbn/inference-tracing 1 2 +1
@kbn/inference-tracing-config - 1 +1
total -0
Unknown metric groups

API count

id before after diff
@kbn/inference-tracing 20 22 +2
@kbn/inference-tracing-config - 12 +12
@kbn/opentelemetry-attributes - 9 +9
@kbn/opentelemetry-utils - 9 +9
@kbn/telemetry-config 7 4 -3
@kbn/tracing-config - 6 +6
total +35

ESLint disabled line counts

id before after diff
@kbn/opentelemetry-utils - 1 +1

Total ESLint disabled count

id before after diff
@kbn/opentelemetry-utils - 1 +1

History

Copy link
Contributor

@peteharverson peteharverson left a comment

Choose a reason for hiding this comment

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

AI infra owned changes LGTM

@dgieselaar dgieselaar merged commit cbd3a97 into elastic:main Jul 1, 2025
13 checks passed
@dgieselaar dgieselaar deleted the move-inference-processors branch July 1, 2025 08:28
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.19, 9.1

https://github.com/elastic/kibana/actions/runs/15994035227

kibanamachine added a commit to kibanamachine/kibana that referenced this pull request Jul 1, 2025
This moves the initialization of phoenix/langfuse processors+exporters
to @kbn/tracing. Previously the Inference plugin initialized and
registered them.

## Why

We need to use the tracing spans outside of the Kibana application as
well - for instance when running evaluations or other CLI-based
workflows. This doesn't work if Kibana server manages the exporter, as
it has no visibility in spans created outside of the process.

**The configuration path moves from
`xpack.inference.tracing.exporter.{phoenix,langfuse}` to
`telemetry.tracing.exporter.{phoenix,langfuse}`, without backwards
compatibility.**

## Notes

- These are registered as _exporters_ but implemented as _processors_.
The reason is that they need to use baggage to make sure all spans
created in the context of an LLM workflow get marked and exported. So
`exporters` are somewhat of a misnomer but it seems overkill to me to
register both `exporters` and `processors` separately.
- I'm backporting to 8.19 as well, given A) the risk of merge conflicts,
B) the fact that this is disabled by default.
- I'm assuming this is not a breaking change because this is not on by
default and not document. If it _is_ a breaking change I would need some
guidance on how to use the
- I used o3 to write documentation for @kbn/tracing and
@kbn/inference-tracing.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
(cherry picked from commit cbd3a97)
@kibanamachine
Copy link
Contributor

💔 Some backports could not be created

Status Branch Result
8.19 Backport failed because of merge conflicts

You might need to backport the following PRs to 8.19:
- [ska][x-pack] Move painless_lab, upgrade_assistant and reporting_management functional tests (#225829)
- Update codeowners for observability ESQL_RECOMMENDED_QUERIES (#225429)
- [ska][x-pack] Move canvas, watcher and dev_tools functional tests
- [ska] relocate 'shared/lib/security' helpers to 'osquery/cypress' dir (#225438)
- [ska] relocate api_integration_basic & defend_workflows_cypress tests (#225374)
- Load huggingface content datasets (#224543)
- [Lens] Add internal CRUD api routes (#223296)
- Move apps/security and apps/spaces tests under platform
9.1

Note: Successful backport PRs will be merged automatically after passing CI.

Manual backport

To create the backport manually run:

node scripts/backport --pr 225417

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Jul 1, 2025
)

# Backport

This will backport the following commits from `main` to `9.1`:
- [[Inference] Move tracing config to @kbn/tracing
(#225417)](#225417)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Dario
Gieselaar","email":"dario.gieselaar@elastic.co"},"sourceCommit":{"committedDate":"2025-07-01T08:28:51Z","message":"[Inference]
Move tracing config to @kbn/tracing (#225417)\n\nThis moves the
initialization of phoenix/langfuse processors+exporters\nto
@kbn/tracing. Previously the Inference plugin initialized
and\nregistered them.\n\n## Why\n\nWe need to use the tracing spans
outside of the Kibana application as\nwell - for instance when running
evaluations or other CLI-based\nworkflows. This doesn't work if Kibana
server manages the exporter, as\nit has no visibility in spans created
outside of the process.\n\n**The configuration path moves
from\n`xpack.inference.tracing.exporter.{phoenix,langfuse}`
to\n`telemetry.tracing.exporter.{phoenix,langfuse}`, without
backwards\ncompatibility.**\n\n## Notes\n\n- These are registered as
_exporters_ but implemented as _processors_.\nThe reason is that they
need to use baggage to make sure all spans\ncreated in the context of an
LLM workflow get marked and exported. So\n`exporters` are somewhat of a
misnomer but it seems overkill to me to\nregister both `exporters` and
`processors` separately.\n- I'm backporting to 8.19 as well, given A)
the risk of merge conflicts,\nB) the fact that this is disabled by
default.\n- I'm assuming this is not a breaking change because this is
not on by\ndefault and not document. If it _is_ a breaking change I
would need some\nguidance on how to use the\n- I used o3 to write
documentation for @kbn/tracing
and\n@kbn/inference-tracing.\n\n---------\n\nCo-authored-by:
kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by:
Elastic Machine
<elasticmachine@users.noreply.github.com>","sha":"cbd3a97eb241e09e63049842518df83b1c64bebd","branchLabelMapping":{"^v9.2.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","backport:version","v9.1.0","v8.19.0","v9.2.0"],"title":"[Inference]
Move tracing config to
@kbn/tracing","number":225417,"url":"https://github.com/elastic/kibana/pull/225417","mergeCommit":{"message":"[Inference]
Move tracing config to @kbn/tracing (#225417)\n\nThis moves the
initialization of phoenix/langfuse processors+exporters\nto
@kbn/tracing. Previously the Inference plugin initialized
and\nregistered them.\n\n## Why\n\nWe need to use the tracing spans
outside of the Kibana application as\nwell - for instance when running
evaluations or other CLI-based\nworkflows. This doesn't work if Kibana
server manages the exporter, as\nit has no visibility in spans created
outside of the process.\n\n**The configuration path moves
from\n`xpack.inference.tracing.exporter.{phoenix,langfuse}`
to\n`telemetry.tracing.exporter.{phoenix,langfuse}`, without
backwards\ncompatibility.**\n\n## Notes\n\n- These are registered as
_exporters_ but implemented as _processors_.\nThe reason is that they
need to use baggage to make sure all spans\ncreated in the context of an
LLM workflow get marked and exported. So\n`exporters` are somewhat of a
misnomer but it seems overkill to me to\nregister both `exporters` and
`processors` separately.\n- I'm backporting to 8.19 as well, given A)
the risk of merge conflicts,\nB) the fact that this is disabled by
default.\n- I'm assuming this is not a breaking change because this is
not on by\ndefault and not document. If it _is_ a breaking change I
would need some\nguidance on how to use the\n- I used o3 to write
documentation for @kbn/tracing
and\n@kbn/inference-tracing.\n\n---------\n\nCo-authored-by:
kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by:
Elastic Machine
<elasticmachine@users.noreply.github.com>","sha":"cbd3a97eb241e09e63049842518df83b1c64bebd"}},"sourceBranch":"main","suggestedTargetBranches":["9.1","8.19"],"targetPullRequestStates":[{"branch":"9.1","label":"v9.1.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.2.0","branchLabelMappingKey":"^v9.2.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/225417","number":225417,"mergeCommit":{"message":"[Inference]
Move tracing config to @kbn/tracing (#225417)\n\nThis moves the
initialization of phoenix/langfuse processors+exporters\nto
@kbn/tracing. Previously the Inference plugin initialized
and\nregistered them.\n\n## Why\n\nWe need to use the tracing spans
outside of the Kibana application as\nwell - for instance when running
evaluations or other CLI-based\nworkflows. This doesn't work if Kibana
server manages the exporter, as\nit has no visibility in spans created
outside of the process.\n\n**The configuration path moves
from\n`xpack.inference.tracing.exporter.{phoenix,langfuse}`
to\n`telemetry.tracing.exporter.{phoenix,langfuse}`, without
backwards\ncompatibility.**\n\n## Notes\n\n- These are registered as
_exporters_ but implemented as _processors_.\nThe reason is that they
need to use baggage to make sure all spans\ncreated in the context of an
LLM workflow get marked and exported. So\n`exporters` are somewhat of a
misnomer but it seems overkill to me to\nregister both `exporters` and
`processors` separately.\n- I'm backporting to 8.19 as well, given A)
the risk of merge conflicts,\nB) the fact that this is disabled by
default.\n- I'm assuming this is not a breaking change because this is
not on by\ndefault and not document. If it _is_ a breaking change I
would need some\nguidance on how to use the\n- I used o3 to write
documentation for @kbn/tracing
and\n@kbn/inference-tracing.\n\n---------\n\nCo-authored-by:
kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by:
Elastic Machine
<elasticmachine@users.noreply.github.com>","sha":"cbd3a97eb241e09e63049842518df83b1c64bebd"}}]}]
BACKPORT-->

Co-authored-by: Dario Gieselaar <dario.gieselaar@elastic.co>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
dgieselaar added a commit to dgieselaar/kibana that referenced this pull request Jul 2, 2025
This moves the initialization of phoenix/langfuse processors+exporters
to @kbn/tracing. Previously the Inference plugin initialized and
registered them.

## Why

We need to use the tracing spans outside of the Kibana application as
well - for instance when running evaluations or other CLI-based
workflows. This doesn't work if Kibana server manages the exporter, as
it has no visibility in spans created outside of the process.

**The configuration path moves from
`xpack.inference.tracing.exporter.{phoenix,langfuse}` to
`telemetry.tracing.exporter.{phoenix,langfuse}`, without backwards
compatibility.**

## Notes

- These are registered as _exporters_ but implemented as _processors_.
The reason is that they need to use baggage to make sure all spans
created in the context of an LLM workflow get marked and exported. So
`exporters` are somewhat of a misnomer but it seems overkill to me to
register both `exporters` and `processors` separately.
- I'm backporting to 8.19 as well, given A) the risk of merge conflicts,
B) the fact that this is disabled by default.
- I'm assuming this is not a breaking change because this is not on by
default and not document. If it _is_ a breaking change I would need some
guidance on how to use the
- I used o3 to write documentation for @kbn/tracing and
@kbn/inference-tracing.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
(cherry picked from commit cbd3a97)

# Conflicts:
#	.github/CODEOWNERS
#	src/core/packages/http/router-server-internal/src/router.ts
@dgieselaar
Copy link
Contributor Author

💚 All backports created successfully

Status Branch Result
8.19

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

dgieselaar added a commit that referenced this pull request Jul 2, 2025
…6224)

# Backport

This will backport the following commits from `main` to `8.19`:
- [[Inference] Move tracing config to @kbn/tracing
(#225417)](#225417)

<!--- Backport version: 10.0.0 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Dario
Gieselaar","email":"dario.gieselaar@elastic.co"},"sourceCommit":{"committedDate":"2025-07-01T08:28:51Z","message":"[Inference]
Move tracing config to @kbn/tracing (#225417)\n\nThis moves the
initialization of phoenix/langfuse processors+exporters\nto
@kbn/tracing. Previously the Inference plugin initialized
and\nregistered them.\n\n## Why\n\nWe need to use the tracing spans
outside of the Kibana application as\nwell - for instance when running
evaluations or other CLI-based\nworkflows. This doesn't work if Kibana
server manages the exporter, as\nit has no visibility in spans created
outside of the process.\n\n**The configuration path moves
from\n`xpack.inference.tracing.exporter.{phoenix,langfuse}`
to\n`telemetry.tracing.exporter.{phoenix,langfuse}`, without
backwards\ncompatibility.**\n\n## Notes\n\n- These are registered as
_exporters_ but implemented as _processors_.\nThe reason is that they
need to use baggage to make sure all spans\ncreated in the context of an
LLM workflow get marked and exported. So\n`exporters` are somewhat of a
misnomer but it seems overkill to me to\nregister both `exporters` and
`processors` separately.\n- I'm backporting to 8.19 as well, given A)
the risk of merge conflicts,\nB) the fact that this is disabled by
default.\n- I'm assuming this is not a breaking change because this is
not on by\ndefault and not document. If it _is_ a breaking change I
would need some\nguidance on how to use the\n- I used o3 to write
documentation for @kbn/tracing
and\n@kbn/inference-tracing.\n\n---------\n\nCo-authored-by:
kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by:
Elastic Machine
<elasticmachine@users.noreply.github.com>","sha":"cbd3a97eb241e09e63049842518df83b1c64bebd","branchLabelMapping":{"^v9.2.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","backport:version","v9.1.0","v8.19.0","v9.2.0"],"title":"[Inference]
Move tracing config to
@kbn/tracing","number":225417,"url":"https://github.com/elastic/kibana/pull/225417","mergeCommit":{"message":"[Inference]
Move tracing config to @kbn/tracing (#225417)\n\nThis moves the
initialization of phoenix/langfuse processors+exporters\nto
@kbn/tracing. Previously the Inference plugin initialized
and\nregistered them.\n\n## Why\n\nWe need to use the tracing spans
outside of the Kibana application as\nwell - for instance when running
evaluations or other CLI-based\nworkflows. This doesn't work if Kibana
server manages the exporter, as\nit has no visibility in spans created
outside of the process.\n\n**The configuration path moves
from\n`xpack.inference.tracing.exporter.{phoenix,langfuse}`
to\n`telemetry.tracing.exporter.{phoenix,langfuse}`, without
backwards\ncompatibility.**\n\n## Notes\n\n- These are registered as
_exporters_ but implemented as _processors_.\nThe reason is that they
need to use baggage to make sure all spans\ncreated in the context of an
LLM workflow get marked and exported. So\n`exporters` are somewhat of a
misnomer but it seems overkill to me to\nregister both `exporters` and
`processors` separately.\n- I'm backporting to 8.19 as well, given A)
the risk of merge conflicts,\nB) the fact that this is disabled by
default.\n- I'm assuming this is not a breaking change because this is
not on by\ndefault and not document. If it _is_ a breaking change I
would need some\nguidance on how to use the\n- I used o3 to write
documentation for @kbn/tracing
and\n@kbn/inference-tracing.\n\n---------\n\nCo-authored-by:
kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by:
Elastic Machine
<elasticmachine@users.noreply.github.com>","sha":"cbd3a97eb241e09e63049842518df83b1c64bebd"}},"sourceBranch":"main","suggestedTargetBranches":["8.19"],"targetPullRequestStates":[{"branch":"9.1","label":"v9.1.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/225953","number":225953,"state":"MERGED","mergeCommit":{"sha":"eacd7e491663394e39ce410b1629da769b416b26","message":"[9.1]
[Inference] Move tracing config to @kbn/tracing (#225417) (#225953)\n\n#
Backport\n\nThis will backport the following commits from `main` to
`9.1`:\n- [[Inference] Move tracing config to
@kbn/tracing\n(#225417)](https://github.com/elastic/kibana/pull/225417)\n\n\n\n###
Questions ?\nPlease refer to the [Backport
tool\ndocumentation](https://github.com/sorenlouv/backport)\n\n\n\nCo-authored-by:
Dario Gieselaar <dario.gieselaar@elastic.co>\nCo-authored-by: Elastic
Machine
<elasticmachine@users.noreply.github.com>"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.2.0","branchLabelMappingKey":"^v9.2.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/225417","number":225417,"mergeCommit":{"message":"[Inference]
Move tracing config to @kbn/tracing (#225417)\n\nThis moves the
initialization of phoenix/langfuse processors+exporters\nto
@kbn/tracing. Previously the Inference plugin initialized
and\nregistered them.\n\n## Why\n\nWe need to use the tracing spans
outside of the Kibana application as\nwell - for instance when running
evaluations or other CLI-based\nworkflows. This doesn't work if Kibana
server manages the exporter, as\nit has no visibility in spans created
outside of the process.\n\n**The configuration path moves
from\n`xpack.inference.tracing.exporter.{phoenix,langfuse}`
to\n`telemetry.tracing.exporter.{phoenix,langfuse}`, without
backwards\ncompatibility.**\n\n## Notes\n\n- These are registered as
_exporters_ but implemented as _processors_.\nThe reason is that they
need to use baggage to make sure all spans\ncreated in the context of an
LLM workflow get marked and exported. So\n`exporters` are somewhat of a
misnomer but it seems overkill to me to\nregister both `exporters` and
`processors` separately.\n- I'm backporting to 8.19 as well, given A)
the risk of merge conflicts,\nB) the fact that this is disabled by
default.\n- I'm assuming this is not a breaking change because this is
not on by\ndefault and not document. If it _is_ a breaking change I
would need some\nguidance on how to use the\n- I used o3 to write
documentation for @kbn/tracing
and\n@kbn/inference-tracing.\n\n---------\n\nCo-authored-by:
kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by:
Elastic Machine
<elasticmachine@users.noreply.github.com>","sha":"cbd3a97eb241e09e63049842518df83b1c64bebd"}}]}]
BACKPORT-->

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:version Backport to applied version labels release_note:skip Skip the PR/issue when compiling release notes v8.19.0 v9.1.0 v9.2.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants

Comments