Ah that could work. Will look at that tonight.
Where is the interceptor order defined in GateIn?
Thanks
Ken
Sent from my iPhone
On Apr 18, 2013, at 16:34, Julien Viet <julien(a)julienviet.com> wrote:
I would rather not do because servlet request attributes as those are
visible then from the portlet request attributes and that's something I prefer to
avoid.
What about having an interceptor in GateIn (it's the place where integration occurs)
placed before the ContextDispatcherInterceptor that setup the information you need
associated with a thread local ?
On Apr 18, 2013, at 10:07 PM, Ken Finnigan <kfinniga(a)redhat.com> wrote:
> Does anyone know if its possible to determine what kind of PortletRequest
(Action/Render/etc) is being triggered from the raw ServletRequest? Before the Portlet
Container interceptors have fired.
>
> If it's not possible, does anyone have any objections to modifying PC to set a
value onto the request to make it identifiable?
>
> An initial thought is to modify ContextDispatcherInterceptor.invoke() from
>
> CallableImpl callable = new CallableImpl(invocation);
> reqCtx.dispatch(targetCtx, invocation.getRequest(), invocation.getResponse(),
callable);
> return callable.response;
>
> to
>
> CallableImpl callable = new CallableImpl(invocation);
> invocation.getRequest().setAttribute("cdi.portlet.invocation",
invocation);
> reqCtx.dispatch(targetCtx, invocation.getRequest(), invocation.getResponse(),
callable);
> return callable.response;
>
> The actual attribute name I've just set to anything to illustrate the code at
present.
>
> If not the invocation itself, then can we set an Enum or integer value to indicate
the portlet request type?
>
> Thanks
> Ken
>
> ========================
> Senior Software Engineer / JBoss Enterprise Middleware Red Hat, Inc.
>
> _______________________________________________
> gatein-dev mailing list
> gatein-dev(a)lists.jboss.org
>
https://lists.jboss.org/mailman/listinfo/gatein-dev