How to use sendRedirect or redirect technic in Vaddin Application

I am not able to get the response and request objects in my vaddin framework application

After submit the form i want to send that response to another server using response.sendRedirect(“PATH”). method . But i didn’t find any method .


Has anybody ever got a solution for that one? I basically would like to present a form where customers can enter their credit card information. Once they click submit, I want to send the values (plus a bunch of hidden fields) to a payment gateway for processing.

Any help is greatly appreciated.



You could consider using the
FormSender add-on

Vaadin forms are not really HTML forms, so you need a server roundtrip to process what was on the form, and when it is being processed, it might not be possible to do a response.sendRedirect() anymore (not quite certain), so yet another server roundtrip and custom handling in AbstractApplicationServlet.service() might be needed for a true redirect response (tricky to implement).

Thanks, that was exactly what I was looking for.

I’m not at a point where I can send a request to the payment gateway. This request is received and successfully processed. However, the callback to the defined URL in my Vaadin app fails (according to log entries I see on the payment gateway side).

I can access the callback URL with parameters without any problems. Hence, I think the callback failure might not be related to Vaadin. Still a bit puzzled as in why I can access it through the browser address bar, but the payment gateway script is not able to reach the URL.

Thanks anyways, I’m a step further :).