-
Notifications
You must be signed in to change notification settings - Fork 260
Common Problems
Leif Metcalf edited this page Sep 19, 2024
·
5 revisions
This page lists some pitfalls that may not be obvious to users. Feel free to add your own!
- In a request, the value for
:bodyis anInputStream. InputStream is mutable and can only ever be read once. Anything that tries to read theInputStreamafter it has already been read will fail to do so. If you find the value for:bodyempty when it shouldn't be, the most likely cause is some other middleware higher in the stack reading theInputStreambefore it gets to you.- Ex: If you have two sets of routes in the same stack each using the
wrap-paramsmiddleware. Only the first routes would have the params.
- Ex: If you have two sets of routes in the same stack each using the
- Use the remove-trailing-slash middleware.
