diff --git a/spring-webflow/src/main/java/org/springframework/webflow/executor/mvc/PortletFlowController.java b/spring-webflow/src/main/java/org/springframework/webflow/executor/mvc/PortletFlowController.java index e8499143..7f770a3c 100644 --- a/spring-webflow/src/main/java/org/springframework/webflow/executor/mvc/PortletFlowController.java +++ b/spring-webflow/src/main/java/org/springframework/webflow/executor/mvc/PortletFlowController.java @@ -58,6 +58,25 @@ import org.springframework.webflow.executor.support.ResponseInstructionHandler; * It is also possible to customize the {@link FlowExecutorArgumentHandler} * strategy to allow for different types of controller parameterization, for * example perhaps in conjunction with a REST-style request mapper. + *

+ * Integrating Spring Web Flow into a Portlet environment puts some minor + * contraints on your flows. These constraints result from technical limitations + * in the Portlet API, for instance the fact that a render request cannot + * issue a redirect. Keep the following in mind when developing Portlets + * using Spring Web Flow: + *

* * @see org.springframework.webflow.executor.FlowExecutor * @see org.springframework.webflow.executor.support.FlowExecutorArgumentHandler @@ -276,6 +295,10 @@ public class PortletFlowController extends AbstractController implements Initial return null; } else { + // we can't render any of the redirect responses since 'sendRedirect' is only + // available on ActionResponse during the action phase + // furthermore, a FlowExecutionRedirect doesn't really makes sense since the + // portlet container handles refreshes with the render phase throw new IllegalArgumentException( "Don't know how to render response instruction " + responseInstruction); }