struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jasper Rosenberg <jasper_rosenb...@yahoo.com.INVALID>
Subject How to add a global interceptor
Date Tue, 13 Oct 2015 11:26:38 GMT
Hi,


 
I work on a project with hundreds of struts actions manywith their own custom interceptor
stacks specified.  


 
We have recently internationalized the site, and so I had aneed to add an i18n interceptor
to the top of every action stack.  It would have been impractical (and difficultto enforce
for future actions) to add the new interceptor to every actiondefinition.


 
My solution was to override the ActionProxyFactory to returnour own ActionInvocation, which
in turn always prepends the i18n interceptor tothe interceptor stack during initialization. 


 
I submitted a patch to make this extension simpler: https://issues.apache.org/jira/browse/WW-4553


 
However, it was suggested in the comments for this JIRA thatthere might be alternative methods
to achieve my goal and to ask on this emaillist.  Thanks in advance for any advice!


 
-Jasper


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message