The filter is just for struts2. Struts1 is handled by servlet mapping.
action
*.do
On 03/05/2018 11:52 PM, Lukasz Lenart wrote:
> 2018-03-05 16:19 GMT+01:00 Prasanth Pasala :
>> Yeah, my url pattern is *.action as I do have some struts1 actions.
> Does it mean you use the same filte
2018-03-05 16:19 GMT+01:00 Prasanth Pasala :
> Yeah, my url pattern is *.action as I do have some struts1 actions.
Does it mean you use the same filter to handle Struts 1 and Strut 2?
Regards
--
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/
-
Yeah, my url pattern is *.action as I do have some struts1 actions.
struts2
*.action
REQUEST
FORWARD
On 03/05/2018 12:27 AM, Lukasz Lenart wrote:
> 2018-03-02 17:33 GMT+01:00 Prasanth :
>> https://issues.apache.org/jira/projects/WW/issues/WW-4904
>>
>> Forwarded using reques
2018-03-02 17:33 GMT+01:00 Prasanth :
> https://issues.apache.org/jira/projects/WW/issues/WW-4904
>
> Forwarded using request dispatcher.
>
> ServletContext sContext = context.getContext("/context2");
> RequestDispatcher rd = sContext.getRequestDispatcher(resource);
> rd.forward(request, response);
On 3/1/2018 10:12 PM, Prasanth wrote:
> I will get back to you with the exception I was getting if you don't set the
> valueStack to null.
No, I meant why request.setAttribute("struts.actionMapping", null) not
work there (like your request.setAttribute("struts.valueStack", null))?
Why request.r
https://issues.apache.org/jira/projects/WW/issues/WW-4904
Forwarded using request dispatcher.
ServletContext sContext = context.getContext("/context2");
RequestDispatcher rd = sContext.getRequestDispatcher(resource);
rd.forward(request, response);
Thanks,
Prasanth
On 03/02/2018 09:31 AM, Lukasz
2018-03-02 15:16 GMT+01:00 Prasanth :
> There are two applications on different contexts. Each have their own struts
> jars. The exception happens when a request to one context is forwarded to
> another context.
What do you mean by "forwarded"?
Regards
--
Łukasz
+ 48 606 323 122 http://www.le
There are two applications on different contexts. Each have their own struts
jars. The exception happens when a request to one context is forwarded to
another context.
Thanks,
Prasanth
On 03/02/2018 01:13 AM, Lukasz Lenart wrote:
> 2018-03-01 20:20 GMT+01:00 Prasanth :
>> 13:17:52,070 ERROR [st
2018-03-01 20:20 GMT+01:00 Prasanth :
> 13:17:52,070 ERROR [stderr] (default task-59) Caused by:
> java.lang.ClassCastException: com.opensymphony.xwork2.ognl.OgnlValueStack
> cannot be cast to com.opensymphony.xwork2.util.ValueStack
You have two the same JARs on a class path but in different ver
Below is the exception you would get if the valueStack is not set to null.
Thanks,
Prasanth
13:17:52,070 ERROR [stderr] (default task-59) Caused by:
java.lang.ClassCastException: com.opensymphony.xwork2.ognl.OgnlValueStack
cannot be cast to com.opensymphony.xwork2.util.ValueStack
13:17:52,070
Sorry didn't check the website, I am not getting the emails to my inbox, will
try to subscribe again. I will get back to you with the exception I was
getting if you don't set the valueStack to null.
Thanks, Prasanth
-- [show/hide
On 12/18/2017 8:33 PM, Prasanth Pasala wrote:
> Added it to Struts JIRA (WW-4904)
Thank you very much for your time and report!
> If I set the struts.actionMapping attribute to null it still causes the
> class cast exception. What I have seen is that after setting it to null if
> you call
>
Added it to Struts JIRA (WW-4904) If I set the struts.actionMapping attribute
to null it still causes the class cast exception. What I have seen is that
after setting it to null if you call
getAttribute you would still get the old ActionMapping object, not sure how
that is possible. Thanks, Pras
Could you please register this issue at [1] with title "Support for
cross context request processing" then we will keep it in monitor and
you can track resolution there, thanks for your report!
On 12/16/2017 2:24 AM, Prasanth Pasala wrote:
> Do you see any side effects of this?
I'm not sure. B
Added the below two lines to my filter (before the struts2 filter) in context2
app. That seems to do the trick. Thought it might create a problem as I am
setting a new ActionMapping in the request,
but seems to work fine. Do you see any side effects of this?
request.setAttribute("struts.
It seems like removeAttribute or setAttribute is not getting rid of the
attribute from request. See below. If I set the value to a random string then I
get a String can't be cast to ActionMapping
exception.
Enumeration attrs = request.getAttributeNames();
while(attrs.hasMoreElemen
Thanks for the prompt response. Tried removing the attribute from the request,
but still getting the class cast exception. Is it possible it is being set
after I have called the forward?
request.removeAttribute("struts.actionMapping"); // FORWARD THE REQUEST
ServletContext sContext =
On 12/15/2017 9:47 PM, Prasanth wrote:
> Is this issue just with Struts2, as it works with Struts1.
No it's not a Struts issue. You don't see this in Struts1 because maybe
it doesn't use any object bounded to dispatched request. But Struts2
wants to
ActionMapping mapping =
(ActionMapping)req
Yes, dispatching request to another struts application. I am using Wildfly
which does use different class loaders. Is this issue just with Struts2, as it
works with Struts1.
Thanks,
Prasanth
--
... do you try to dispatch
We have the struts jars in the individual wars. I was actually thinking of
putting it in server lib to see if that would solve the problem.
Thanks,
Prasanth
*
From: *
*Subject: *re: java.lang.ClassCastException:
org.apache.struts2.dispatcher.mapper.ActionMapping
*Date: *2017-12-15 02:20
*List
Yes, dispatching request to another struts application. I am using Wildfly
which does use different class loaders. Is this issue just with Struts2, as it
works with Struts1.
Thanks,
Prasanth
--
... do you try to dispatch
On 12/15/2017 11:45 AM, Yasser Zamani wrote:
>
>
> On 12/15/2017 2:16 AM, Prasanth Pasala wrote:
>> ServletContext sContext = context.getContext("/context2");
>> RequestDispatcher rd = sContext.getRequestDispatcher(resource);
>> rd.forward(request, response);
>>
>> Thanks,
>> Prasanth
>>
>>
> > ServletContext sContext = context.getContext("/context2");
> > RequestDispatcher rd = sContext.getRequestDispatcher(resource);
> > rd.forward(request, response);
> >
> > Thanks,
> > Prasanth
> >
> > Exception: java.lang.RuntimeException: java.lang.RuntimeException:
> java.lang.ClassCastExce
On 12/15/2017 2:16 AM, Prasanth Pasala wrote:
> ServletContext sContext = context.getContext("/context2");
> RequestDispatcher rd = sContext.getRequestDispatcher(resource);
> rd.forward(request, response);
>
> Thanks,
> Prasanth
>
> Exception: java.lang.RuntimeException: java.lang.RuntimeExce
24 matches
Mail list logo