URL path naming
Closed this issue · 3 comments
Hi,
I'm looking into x-ray with rails atm, and can see that whenever I group traces by URL - those are by full URLs with parameters. I would rather expect having parameter keys instead of values, so the grouping is more valuable. i.e. with routes like
get "/:locale/books/:id" => "books#show"
I would prefer to have traces under
https://books.com/:locale/books/:id
But instead we get
https://books.com/en/books/foo
https://books.com/en/books/bar
https://books.com/de/books/foo
etc
The question is - is it by design and shouldn't be fiddled around? For example is there any documentation showing how to work around this problem? Or is there some kind of work on the subject already?
Best,
Leszek
Hey,
Thanks for the feedback! This behavior is done by design, but we gladly accept feature requests. This seems fairly similar to a request in our Python SDK aws/aws-xray-sdk-python#64 (comment)
Would an aggregated wildcard similar to what's stated in that issue encapsulate your use case?
Hi @chanchiem, sorry for long response. Yes something like a wildcard would help, maybe even on the UI part itself if the tracking of full urls is by design
Hi @driv3r,
Unfortunately on downstream HTTP requests as I believe you're describing it is not possible to group all such requests into a single node using wildcard matching. However, you can create a group of nodes on the X-Ray console aggregated with filter expressions using the X-Ray Groups API. This could allow you to see only certain URLs at once on the service map.
Alternatively, you could manually add annotations based on the components of the URL path and group by those.