Title: Throw proper exception when request parsing fails · Issue #31 · JavaWebStack/http-router · GitHub
Open Graph Title: Throw proper exception when request parsing fails · Issue #31 · JavaWebStack/http-router
X Title: Throw proper exception when request parsing fails · Issue #31 · JavaWebStack/http-router
Description: Currently calling the .body method (or injecting it) and sending invalid content to the endpoint throws a generic java.text.ParseException or MapperWrongTypeException from abstract-data. The stacktrace is hard to debug since it doesn't c...
Open Graph Description: Currently calling the .body method (or injecting it) and sending invalid content to the endpoint throws a generic java.text.ParseException or MapperWrongTypeException from abstract-data. The stackt...
X Description: Currently calling the .body method (or injecting it) and sending invalid content to the endpoint throws a generic java.text.ParseException or MapperWrongTypeException from abstract-data. The stackt...
Opengraph URL: https://github.com/JavaWebStack/http-router/issues/31
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Throw proper exception when request parsing fails","articleBody":"Currently calling the .body method (or injecting it) and sending invalid content to the endpoint throws a generic java.text.ParseException or MapperWrongTypeException from abstract-data. The stacktrace is hard to debug since it doesn't contain any context (endpoint, invalid data, etc.)\r\n\r\nInstead we should throw an exception that contains more context and can be properly handled in the exception handler and responded to.\r\n\r\n1. Invalid request body throws a specific exception\r\n2. The default exception handler, responds with 400","author":{"url":"https://github.com/JanHolger","@type":"Person","name":"JanHolger"},"datePublished":"2024-08-30T12:31:13.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/31/http-router/issues/31"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:e56ad066-7895-8535-79ca-edbc50b3aaea |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | AD6C:366F6:9030F2:BD8A9E:697D2E79 |
| html-safe-nonce | 26411f1e81eeca6ff2b0d7df2beeed0b0a42418fa8ffa46b7f0bc499d6c40483 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBRDZDOjM2NkY2OjkwMzBGMjpCRDhBOUU6Njk3RDJFNzkiLCJ2aXNpdG9yX2lkIjoiMjQ0MzQ2MTYzNTgyMjM5OTA5NyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 694be782a7d9d4fd9717f46088e42f66186f383688b2e78d1e0ba80ab5f10a40 |
| hovercard-subject-tag | issue:2497103215 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/JavaWebStack/http-router/31/issue_layout |
| twitter:image | https://opengraph.githubassets.com/726531de8166c29c9829ad81765b04fdf1433d88c8d5e1365ed6fa9c17383a5c/JavaWebStack/http-router/issues/31 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/726531de8166c29c9829ad81765b04fdf1433d88c8d5e1365ed6fa9c17383a5c/JavaWebStack/http-router/issues/31 |
| og:image:alt | Currently calling the .body method (or injecting it) and sending invalid content to the endpoint throws a generic java.text.ParseException or MapperWrongTypeException from abstract-data. The stackt... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | JanHolger |
| hostname | github.com |
| expected-hostname | github.com |
| None | 947d30920225f8abb17692477afd5992252045b901780d1bc8fa47c03b5fde64 |
| turbo-cache-control | no-preview |
| go-import | github.com/JavaWebStack/http-router git https://github.com/JavaWebStack/http-router.git |
| octolytics-dimension-user_id | 73674659 |
| octolytics-dimension-user_login | JavaWebStack |
| octolytics-dimension-repository_id | 308482890 |
| octolytics-dimension-repository_nwo | JavaWebStack/http-router |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 308482890 |
| octolytics-dimension-repository_network_root_nwo | JavaWebStack/http-router |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 92fcc0e25bb4da7fe9a458840cb7f3cafa272eb8 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width