struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ben Mati, Abdelkader" <>
Subject Apache rewrite/reverse proxy
Date Mon, 15 Oct 2012 13:22:52 GMT
Hello Listers,

I have back end website running on Tomcat using struts with the following url
External user access the website through apache  proxy with the following url
(user1, user2, etc... It’s uri specific to each user). I want to use apache  rewrite or/
and reverse proxy  directive to translate the url like into
Can some apache guru help me please?



-----Original Message-----
From: Lukasz Lenart [] 
Sent: October 15, 2012 2:31 AM
To: Struts Users Mailing List
Subject: Re: person.getId() not set with url paramter using NamedVariablePatternMatcher

2012/10/15 pirzada rashid <>:
> Thanks for the reply. I have commented person = 
> personDAO.get(this.getId());. To make things more clear. Just wanted 
> to see Method prints "id" passed in URL. Below are changes.
> See this line below 10:56:05,583 DEBUG PersonAction:62 - 
> getPersonById() = null executed---->>>> . I get id value null. Thats the
> URL : http://localhost:8000/1_Struts2_Tiles_mvn/person/edit/8
> JSP Page:
> <s:url id="editURL" action="edit/%{id}" /> <s:a href="%{editURL}"><i 
> class="icon-edit"></i></s:a>
> struts.xml
> <action name="edit/*" class="com.myapp.action.PersonAction"
> method="getPersonById" >
>             <param name="id">{1}</param>
>             <interceptor-ref name="byPassValidation"/>
>             <result name="success" type="tiles">/person.edit.tiles</result>
>         </action>
> Action Class method
> public String getPersonById() throws Exception {
>         LOG.debug("getPersonById() = {} executed---->>>>", this.getId());
>         return SUCCESS;
>     }
> CONSOLE -> Stacktrace
> 10:56:05,578 DEBUG DefaultActionProxy:68 - Creating an 
> DefaultActionProxy for namespace /person and action name edit/8
> 10:56:05,581 DEBUG AbstractMatcher:68 - Attempting to match 'edit/8' 
> to a wildcard pattern, 2 available
> 10:56:05,581 DEBUG AbstractMatcher:68 - Value matches pattern 'edit/*'
> 10:56:05,582 DEBUG ParametersInterceptor:68 - Setting params
> 10:56:05,582 DEBUG DefaultWorkflowInterceptor:68 - Skipping Interceptor...
> Method [getPersonById] found in exclude list.
> 10:56:05,582 DEBUG DefaultActionInvocation:68 - Executing action 
> method = getPersonById
> 10:56:05,583 DEBUG PersonAction:62 - getPersonById() = null 
> executed---->>>>

I think the problem is how you defined your stack - it's missing a lot of other interceptors.
Take a look how it is defined in Showcase App [1]


+ 48 606 323 122

To unsubscribe, e-mail:
For additional commands, e-mail:

CONFIDENTIALITÉ : Ce document est destiné uniquement à la personne ou à l'entité à qui il
est adressé. 
L'information apparaissant dans ce document est de nature légalement privilégiée et confidentielle.
Si vous n'êtes pas 
le destinataire visé ou la personne chargée de le remettre à son destinataire, vous êtes,
par la présente, avisé que toute 
lecture, usage, copie ou communication du contenu de ce document est strictement interdit.
De plus, vous êtes prié de 
communiquer avec l'expéditeur sans délai ou d'écrire à et de détruire
ce document 

CONFIDENTIALITY: This document is intended solely for the individual or entity to whom it
is addressed. The 
information contained in this document is legally privileged and confidential. If you are
not the intended recipient or the 
person responsible for delivering it to the intended recipient, you are hereby advised that
you are strictly prohibited from 
reading, using, copying or disseminating the contents of this document. Please inform the
sender immediately or write 
to and delete this document immediately. 

View raw message