Skip to content

feat(datastreams): added segment_name to hashable tags#4013

Merged
dd-mergequeue[bot] merged 4 commits into
mainfrom
kr-igor/allow-segment-name-tags-dsm
Oct 6, 2025
Merged

feat(datastreams): added segment_name to hashable tags#4013
dd-mergequeue[bot] merged 4 commits into
mainfrom
kr-igor/allow-segment-name-tags-dsm

Conversation

@kr-igor

@kr-igor kr-igor commented Oct 1, 2025

Copy link
Copy Markdown
Contributor

What does this PR do?

Adds new hashable tag to DSM.

Motivation

We now support latency segments, which can be set using the following code

ctx, ok = tracer.SetDataStreamsCheckpointWithParams(
    ctx,
    options.CheckpointParams{},
    "direction:internal", "type:segment", "segment_name:second")

This can be used to break down internal (processing latency).

Now: Topic A -> Service -> Topic B will have internal latency from consume to produce.
With segment_name: Topic A-> Service (segment A) -> Service (segment B)-> Topic B internal latency in this example is split into 2 named segments. The user can define any number of segments.

Reviewer's Checklist

  • Changed code has unit tests for its functionality at or near 100% coverage.
  • System-Tests covering this feature have been added and enabled with the va.b.c-dev version tag.
  • There is a benchmark for any new code, or changes to existing code.
  • If this interacts with the agent in a new way, a system test has been added.
  • New code is free of linting errors. You can check this by running ./scripts/lint.sh locally.
  • Add an appropriate team label so this PR gets put in the right place for the release notes.
  • Non-trivial go.mod changes, e.g. adding new modules, are reviewed by @DataDog/dd-trace-go-guild.

Unsure? Have a question? Request a review!

@kr-igor kr-igor changed the title Allow using segment tags for DSM feat(DSM): added segment_name to hashable tags Oct 1, 2025
@pr-commenter

pr-commenter Bot commented Oct 1, 2025

Copy link
Copy Markdown

Benchmarks

Benchmark execution time: 2025-10-03 13:41:10

Comparing candidate commit e99cb04 in PR branch kr-igor/allow-segment-name-tags-dsm with baseline commit 7d19197 in branch main.

Found 0 performance improvements and 0 performance regressions! Performance is the same for 24 metrics, 0 unstable metrics.

@kr-igor kr-igor changed the title feat(DSM): added segment_name to hashable tags feat(datastreams): added segment_name to hashable tags Oct 1, 2025
@kr-igor
kr-igor marked this pull request as ready for review October 1, 2025 20:30
@kr-igor
kr-igor requested a review from a team as a code owner October 1, 2025 20:30
@kr-igor

kr-igor commented Oct 1, 2025

Copy link
Copy Markdown
Contributor Author

/merge

@dd-devflow-routing-codex

dd-devflow-routing-codex Bot commented Oct 1, 2025

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2025-10-01 21:01:21 UTC ℹ️ Start processing command /merge


2025-10-01 21:01:26 UTC ℹ️ MergeQueue: pull request added to the queue

The expected merge time in main is approximately 18m (p90).


2025-10-01 23:01:46 UTCMergeQueue: The build pipeline has timeout

The merge request has been interrupted because the build 0 took longer than expected. The current limit for the base branch 'main' is 120 minutes.

Possible reasons:

  • some mandatory checkruns are failing:
    • check-title

@kr-igor

kr-igor commented Oct 2, 2025

Copy link
Copy Markdown
Contributor Author

/merge

@dd-devflow-routing-codex

dd-devflow-routing-codex Bot commented Oct 2, 2025

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2025-10-02 16:34:01 UTC ℹ️ Start processing command /merge


2025-10-02 16:34:06 UTC ℹ️ MergeQueue: pull request added to the queue

The expected merge time in main is approximately 18m (p90).


2025-10-02 16:44:15 UTC ℹ️ MergeQueue: Readding this merge request to the queue because another merge request processed with yours failed. No action is needed from your side.


2025-10-02 18:14:31 UTCMergeQueue: This merge request was updated

This PR is rejected because it was updated

@hannahkm

hannahkm commented Oct 2, 2025

Copy link
Copy Markdown
Contributor

/merge -c

@dd-devflow-routing-codex

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2025-10-02 18:52:05 UTC ℹ️ Start processing command /merge -c
If you need support, contact us on Slack #devflow!


2025-10-02 18:52:06 UTCDevflow: /merge -c

This merge request is not in the queue and can't be unqueued

To get help about command usage, write /merge --help

If you need support, contact us on Slack #devflow with those details!

@hannahkm

hannahkm commented Oct 2, 2025

Copy link
Copy Markdown
Contributor

/merge

@dd-devflow-routing-codex

dd-devflow-routing-codex Bot commented Oct 2, 2025

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2025-10-02 18:52:47 UTC ℹ️ Start processing command /merge


2025-10-02 18:52:55 UTC ℹ️ MergeQueue: waiting for PR to be ready

This merge request is not mergeable yet, because of pending checks/missing approvals. It will be added to the queue as soon as checks pass and/or get approvals.
Note: if you pushed new commits since the last approval, you may need additional approval.
You can remove it from the waiting list with /remove command.


2025-10-02 20:20:16 UTC ℹ️ MergeQueue: merge request added to the queue

The expected merge time in main is approximately 18m (p90).


2025-10-02 22:20:35 UTCMergeQueue: The build pipeline has timeout

The merge request has been interrupted because the build 0 took longer than expected. The current limit for the base branch 'main' is 120 minutes.

@kr-igor

kr-igor commented Oct 6, 2025

Copy link
Copy Markdown
Contributor Author

/merge

@dd-devflow-routing-codex

dd-devflow-routing-codex Bot commented Oct 6, 2025

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2025-10-06 07:32:42 UTC ℹ️ Start processing command /merge


2025-10-06 07:32:46 UTC ℹ️ MergeQueue: pull request added to the queue

The expected merge time in main is approximately 20m (p90).


2025-10-06 07:45:37 UTC ℹ️ MergeQueue: This merge request was merged

@dd-mergequeue
dd-mergequeue Bot merged commit f1dd348 into main Oct 6, 2025
238 checks passed
@dd-mergequeue
dd-mergequeue Bot deleted the kr-igor/allow-segment-name-tags-dsm branch October 6, 2025 07:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants