Custom Xray Trace for Graphql Mutation

1

Hi there, I have Xray enabled in my NodeJs Express App with Graphql. I can see segments for other rest endpoints but the other query and mutation that goes through Graphql only /graphql as the path with makes it hard if i need to troubleshoot. Is there a way i can trace GraphQL mutation with AWS xray?

profile picture
已提問 1 年前檢視次數 302 次
1 個回答
0

You probably are looking for subsegments. So you would create a subsegment with a namespace of "remote" and add the mutation data in metadata. This way you can filter the traces based on the mutation performed.

https://docs.aws.amazon.com/xray/latest/devguide/xray-sdk-nodejs-subsegments.html

已回答 1 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南