• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

problem in configuring interceptor in struts.xml

 
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


Here i have class "SessionInterceptor" for session management.
In above i have created interceptor stack and included in all action where i need with the navigation for session expired as




If i have more actions then i do have to include interceptor-ref and <result name="session">/sessionexpired.jsp</result> in all which seems time consuming. Is there any approach so that i don't have to include this in all actions ?

thank you in advance.
 
Sheriff
Posts: 9708
43
Android Google Web Toolkit Hibernate IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Check the interceptor configuration to see how to configure a default interceptor stack and result configuration to see how to define global results...
 
rajiv shrestha
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Ankit Garg wrote:Check the interceptor configuration to see how to configure a default interceptor stack and result configuration to see how to define global results...



hi ankit, thank you for the response.

i modified like this.


Is this the right process to use default interceptor and global result?
But its not working.
I need some assist.
 
Ankit Garg
Sheriff
Posts: 9708
43
Android Google Web Toolkit Hibernate IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

But its not working.


Please be more specific about the problem...
 
rajiv shrestha
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Ankit Garg wrote:

But its not working.


Please be more specific about the problem...




my problem is i want the interceptor stack , "sessionStack" that i made to be included in all necessary actions and the result for sessionexpired.jsp.
As this can be done by default-interceptor-ref for interceptor and global results for the results. i have tried like the above code in the struts.xml. i want to maintain the session with this, but its not working. i directly goes to sessionexpired.jsp. i think it is due to global results.

i have implemented like the above code using default-interceptor-ref and global result. is this the right approach that i implemented like above ?


 
I carry this gun in case a vending machine doesn't give me my fritos. This gun and this tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic