# How to Trace Subrequests of my Middleware?

**URL:** <https://community.traefik.io/t/how-to-trace-subrequests-of-my-middleware/27725>\
**Category:** Traefik v3 (latest)\
**Tags:** tracing, middleware\
**Created:** [June 11, 2025, 8:31pm UTC](https://community.traefik.io/t/how-to-trace-subrequests-of-my-middleware/27725 "2025-06-11T20:31:25Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![johannges](https://avatars.discourse-cdn.com/v4/letter/j/f04885/32.png) [@johannges](https://community.traefik.io/u/johannges)\
**Post date:** [June 11, 2025, 8:31pm UTC](https://community.traefik.io/t/how-to-trace-subrequests-of-my-middleware/27725/1 "2025-06-11T20:31:25Z")

</div>

Simply but, how do i do Subrequests inside a Middleware, so they are shown in the Trace of the Request?

If this is not possible jet, it would be a very important feature, so the visibility of middlewares will be greatly improved.

For our context:  
We are creating a middleware to resolve SSI (Server Side includes) very similar to ESI (Edge Side Includes). The middleware is doing a lot of subrequests to get all the HTML Snippets. To be able to identify slow HTML Snippets, we need to have them inside the Trace of the User Request.
