Questions tagged [exceptionhandler]
186 questions
1
vote
0 answers
How do I make my "failed requests" appear in the Application Insights charts and analysis?
How do I make my "failed requests" appear in the Application Insights charts and analysis?
Microsoft Azure | Application Insights print1
Microsoft Azure | Application Insights print2
I have a website in WordPress with multisite, inside a server in…

Kaue Alves
- 123
- 5
1
vote
1 answer
ExceptionHandler invokes but doesn't affect http response
I have the following method:
@ExceptionHandler(InvalidPriceUpdateException.class)
@ResponseStatus(HttpStatus.BAD_REQUEST)
public String handleInvalidPriceUpdateException(InvalidPriceUpdateException e) throws JsonProcessingException {
…

gstackoverflow
- 36,709
- 117
- 359
- 710
1
vote
1 answer
Fire off angular $exceptionHandler from chrome repl
I am overriding the default $exceptionHandler, similar to what is seen here on angular's site: https://docs.angularjs.org/api/ng/service/$exceptionHandler
works great.
However, I am semi-unclear as to how to 'watch' this process when not $emit'ing a…

Brandt Solovij
- 2,124
- 13
- 24
1
vote
1 answer
Custom ExceptionHandler in Angular 2
I´m trying to implement a central ExceptionHandler in Angular 2. I searched in SO and found several topics about this subject, like those bellow:
Module '"angular2/angular2"' has no exported member 'ExceptionHandler'
How to properly overwrite the…

etc
- 83
- 2
- 9
1
vote
1 answer
Angular2 ExceptionHandler not working
I've searched around quite a bit and haven't found anything that is helping me get over the hump. I think that I have implemented the Angular2 ExceptionHandler as required, but it is never getting called.
Main.ts:
import { bootstrap } from…

ibejo
- 67
- 1
- 6
1
vote
1 answer
Spring MVC ExceptionHandler and the controller context
This should be a common problem with a solution but I haven't managed to find it anywhere.
I am defining a global exception handler using @ControllerAdvice, I define a new ModelAndView and redirect to my error page. Works great EXCEPT for the fact…

funnyman7878
- 29
- 2
1
vote
0 answers
Exception handling in primefaces not working
I am facing an issue with p:ajaxExceptionHandler. The p:ajaxExceptionHandler code does not seem to get invoked at all.. I have the configuration in web.xml as per primefaces documentation. Basically When an exception occurs, I want to show a pop…

user5161658
- 11
- 3
1
vote
0 answers
How to handle multiple exceptions in @exeptionhandler and response body?
Should I create an extra method with org.springframework.security.access.AccessDeniedException as parameter?
@ControllerAdvice
public class AccessDeniedExceptionAdvice {
private final Logger log = LoggerFactory.getLogger(getClass());
…

Viktor Mellgren
- 4,318
- 3
- 42
- 75
1
vote
1 answer
Custom json response for internal exception in spring
While implementing a global exception handler in Spring, I noticed that in case of a not recognized Accept header, Spring would throw it's own internal error. What I need is to return a custom JSON error structure instead. Works fine for application…

Leo
- 1,016
- 1
- 13
- 32
1
vote
0 answers
@ExceptionHandler Unsupported argument
I'm using Spring's @ExceptionHandler annotation to catch exceptions in my controllers.
When there are no arguments in the signature of the method, it's working fine (the method is called),…

pedron4
- 11
- 3
1
vote
1 answer
FullAjaxExceptionHandler doesnt redirect to error page on omnifaces 1.7
I have a problem with the FullAjaxExceptionHandler on ajax requests using the Omnifaces.
Environment:
Tomcat 7.0.50
Mojarra 2.1.27
Omnifaces 1.7
I declared the error pages in my web.xml:
Faces Servlet
…

Gustavo Ehrhardt
- 13
- 2
- 4
1
vote
2 answers
Handling exceptions in Spring MVC along with Rest API
I am using @ControllerAdvice annotation for defining exceptions at application level. Now the problem is I am having two @ControllerAdvice classes, one for REST and one for the normal web app. When I define @ExceptionHandler for Exception.class in…

Satya
- 1,239
- 2
- 11
- 15
0
votes
1 answer
Kafka StreamsUncaughtExceptionHandler REPLACE_THREAD vs SHUTDOWN_CLIENT
I have an old topic which contains corrupted messages and I need to fully reprocess this topic ignoring the unprocessable messages. Which is the right uncaught exception handling strategy for this scenario?
I'm not able to fully understand the…

frblazquez
- 115
- 1
- 10
0
votes
1 answer
@RestControllerAdvice overriding @ResponseStatus of CustomException
My spring boot @RestControllerAdvice is overriding the @ResponseStatus of my Exception class (that extends RuntimeException).
It is defaulting to 200.
But it works when it put the @ResponseStatus over the handler…

sagar
- 79
- 3
- 8
0
votes
1 answer
FastAPI: how to test exception handler logic
I am implementing exception handler logic to intercept RetryErrors occurring at service level.
For context, in that specific case, the second argument of the handler's signature: async def my_handler(request: Request, call_next) is, in fact, not a…

Mena
- 47,782
- 11
- 87
- 106