Flash scope in a custom FlowHandler
I would like to be able to put a message into flash scope from the handleExecutionOutcome method of a flow handler (extends AbstractFlowHandler). My initial thought was that I could add RedirectAttributes to the method signature like so:
Code:
public String handleExecutionOutcome(FlowExecutionOutcome outcome, HttpServletRequest request, HttpServletResponse response, RedirectAttributes redirectAttributes){
...
...
...
redirectAttributes.addFlashAttribute("messages", "This is my message");
....
}
Alas, when I do this the handleExecutionOutcome method is ignored.
My question is if anyone knows how to access flow scope from such a handler?