elastic / elastic/apm

APM UI - Not able to search for child span/transaction labels

Open
#582 3 comments 1 reaction 0 assignees View on GitHub
Dominant language
Gherkin
Stars
427
Forks
125
PR merge metrics
No merged PRs in 30d

Description

_Note: I've posted this on [Elastic Forum](https://discuss.elastic.co/t/apm-ui-not-able-to-search-for-child-span-transaction-labels/294081). But as it may also be a bug, I've posted this here too_

**Describe the bug**

I expected to be able to filter traces based on their transactions' labels. However as shown below I am not able to do that.

With the following distributed transaction:

![Screenshot from 2022-01-11 18-20-01](https://user-images.githubusercontent.com/8304447/149150012-25c15df9-161d-4311-9e53-5127ed7d1649.png)

When I see the child transaction from the "station-write" service, we can see that there is a "stationId" label:

![Screenshot from 2022-01-11 18-20-14](https://user-images.githubusercontent.com/8304447/149150097-5b3103bd-e34a-4cc6-8449-d3374716545f.png)

When I see the parent transaction from the "gateway" service, we can see that there are other labels:

![Screenshot from 2022-01-11 18-20-30](https://user-images.githubusercontent.com/8304447/149150112-e112bb77-c065-44a0-8ddd-03f95698dd40.png)

**To Reproduce**
Steps to reproduce the behavior:

Go to "Traces" page, enter in the search box the "labels.stationId" field(we can see that the auto complete works):
![Screenshot from 2022-01-11 18-21-13](https://user-images.githubusercontent.com/8304447/149150141-225776aa-3afd-4624-b772-712aaa7d87e7.png)

Filter by a given value, and see that it doesn't show any transactions
![Screenshot from 2022-01-11 18-21-28](https://user-images.githubusercontent.com/8304447/149150153-fd2aa365-b2cc-4608-858d-718f8a4abafa.png)

I couldn't find anywhere that said that it is(or is not) possible to search by labels in child spans/transactions. If it isn't possible to search by those labels, is there any way that I can add those labels to the parent transaction, in order for them to be searchable? The gateway service starts the trace, and this "station-write" service creates another transaction inside of that distributed trace(they are in different pods).

**Expected behavior**
I expected to be able to filter traces based on their transactions' labels.

**Versions**

**Kibana version**: 7.15.1
**Elasticsearch version**: 7.15.1
**APM Server version**: 7.15.1
**APM Agent language and version**: Node.JS at 3.26.0

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.