Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spring Pet Clinic AppMaps show HTTP server requests separate from the request processing code #263

Open
kgilpin opened this issue Mar 5, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@kgilpin
Copy link
Contributor

kgilpin commented Mar 5, 2024

I'm adding some authentication logic to the Spring Pet Clinic. I've pushed the code here:

The AppMaps show the Spring doFilter logic in a kind of separate context from the request. It's hard to explain, here's what I mean:

Screen Shot 2024-03-05 at 8 46 16 AM

AppMap attached:

1709612302_179__login.appmap.json

@kgilpin kgilpin added the bug Something isn't working label Mar 5, 2024
@kgilpin kgilpin assigned kgilpin and apotterri and unassigned kgilpin Mar 5, 2024
@apotterri
Copy link
Contributor

My comment from Slack thread:

Ok, I took a look at this. There's no thread-related weirdness here. The AppMap looks a little weird because you've asked to instrument some of the Spring internals. So, the agent starts recording when Spring tells it that an HTTP request is starting. Next, the call to Spring's org.springframework.security.web.authentication.logout.LogoutFilter.doFilter gets added to the recording. Finally, the call to javax.servlet.http.HttpServlet.service adds the http_server_request event.
It's possible we could fix this by moving the creation of the http_server_request event into the listener that starts the recording. I'd need to do some investigation to be sure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants