You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by A Stephen <st...@attbi.com> on 2003/01/19 21:06:25 UTC

Re: [PATCH] LookupDispatchAction

[PATCH]
Index: LocalStrings.properties
===================================================================
RCS file:
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LocalStri
ngs.properties,v
retrieving revision 1.5
diff -r1.5 LocalStrings.properties
5a6
> dispatch.parameter.error=Request[{0}] does not contain method mapping  for
{1}

Index: LookupDispatchAction.java
===================================================================
RCS file:
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LookupDis
patchAction.java,v
retrieving revision 1.10
diff -r1.10 LookupDispatchAction.java
231d230
<
233c232,235
<
---
>         if (methodName==null){
>             String message =
messages.getMessage("dispatch.parameter.error", mapping.getPath(), name);
>             throw new ServletException(message);
>         }

<comment>
Please don't get me wrong I'm a big fan/advocate of struts and wasn't trying
to say it was Strut's fault.
I was merely trying to submit a patch; and avoid hours of frustration for
the people that use resin/ struts

If it works on platform and not the other , we all might as well be
developing Microsoft applications.
</comment>

----- Original Message -----
From: "Wendy Smoak" <We...@asu.edu>
To: "'Struts Developers List'" <st...@jakarta.apache.org>
Sent: Friday, January 17, 2003 6:56 AM
Subject: RE: [PATCH] Re: Nasty Error when use LookupDispatchAction


> > Everything works beautifully until you try and mess the query string
> > for e.g  /edit.do?submit=initchanged&key=10
> > there is no mapping for initx, hence there is no method name and null is
> > passed into the
> > return dispatchMethod(mapping, form, request, response, methodName)
> > which finally calls getMethod(String name, Class[] parameterTypes)
> > The end result is that application shuts down with VM error
>
> This has been discussed before and I believe the general consensus is that
> there's a bug in Resin.  If you try the same thing in Tomcat, you will
only
> get an exception.
>
> Still, I don't like the behavior of LookupDispatchAction so I override the
> execute() method in which I examine the request parameters.  If the
"action"
> is present, I just call super.execute().  Otherwise I try to figure out
what
> would be appropriate (add?  edit?) before giving up and throwing an
> exception.
>
> I would like to add a "default" attribue to the tag in struts-config so
you
> can specify which method to call if the parameter isn't present in the
> request.
>
> In short, I don't think that VM Error is the fault of Struts.
>
> --
> Wendy Smoak
> Applications Systems Analyst, Sr.
> Arizona State University PA Information Resources Management
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: [PATCH] LookupDispatchAction

Posted by Mohan Kishore <mo...@yahoo.com>.
Was having the same problem myself.

The trivial solution is to type in 'cvs diff -u XXX' in the command window.
But, the better solution is to create a file called .cvsrc in the directory you
store your cvs password file. This file should have the line 'diff -u'. Now,
when you invoke 'diff' from wincvs menus, it automatically calls 'diff -u'

regards,
Mohan.

--- A Stephen <st...@attbi.com> wrote:
> Greetings,
> I use wincvs to work with CVS , am not sure how to save cvs diff -u format
> 
> David Graham, thx for accepting the patch and providing a more elegant
> solution.
> Thank you,
> -S
> 
> 
> 
> ----- Original Message -----
> From: "A Stephen" <st...@attbi.com>
> To: "Struts Developers List" <st...@jakarta.apache.org>
> Sent: Sunday, February 02, 2003 11:55 AM
> Subject: Re: [PATCH] LookupDispatchAction
> 
> 
> > Thank you very much for the tip.
> > I posted the bug and attached the proposed patch
> > <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16678>.
> >
> > Thanks again,
> > cheers,
> > -S
> >
> > ----- Original Message -----
> > From: "James Mitchell" <jm...@apache.org>
> > To: "Struts Developers List" <st...@jakarta.apache.org>
> > Sent: Monday, January 20, 2003 8:03 AM
> > Subject: Re: [PATCH] LookupDispatchAction
> >
> >
> > > It means that you should use bugzilla to upload the patch as a text file
> > (to
> > > the bug report it fixes), that way it won't get lost in the mailing
> list.
> > > The biggest reason though is that it let's struts developers try out and
> > > test the path instead of wasting time recreating what you've already
> done.
> > >
> > > Thanks for the patch!!
> > >
> > >
> > > --
> > > James Mitchell
> > >
> > >
> > >
> > >
> > >
> > > ----- Original Message -----
> > > From: "A Stephen" <st...@attbi.com>
> > > To: "Struts Developers List" <st...@jakarta.apache.org>
> > > Sent: Sunday, January 19, 2003 4:16 PM
> > > Subject: Re: [PATCH] LookupDispatchAction
> > >
> > >
> > > > I'm sorry but I don't understand
> > > > <quote>
> > > > Contrary to the general advice on the Bugzilla page, we actually like
> > > > these attached to the corresponding ticket =:0)
> > > > </quote>
> > > >
> > > > Do I have to do something? I'm new to this process.
> > > > Thanks for your help,
> > > > -S
> > > >
> > > > ----- Original Message -----
> > > > From: "Ted Husted" <hu...@apache.org>
> > > > To: "Struts Developers List" <st...@jakarta.apache.org>
> > > > Sent: Sunday, January 19, 2003 12:46 PM
> > > > Subject: Re: [PATCH] LookupDispatchAction
> > > >
> > > >
> > > > > Contrary to the general advice on the Bugzilla page, we actually
> like
> > > > > these attached to the corresponding ticket =:0)
> > > > >
> > > > > -Ted.
> > > > >
> > > > > A Stephen wrote:
> > > > > > [PATCH]
> > > > > > Index: LocalStrings.properties
> > > > > >
> ===================================================================
> > > > > > RCS file:
> > > > > >
> > > >
> > >
> >
> /home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LocalStri
> > > > > > ngs.properties,v
> > > > > > retrieving revision 1.5
> > > > > > diff -r1.5 LocalStrings.properties
> > > > > > 5a6
> > > > > >
> > > > > >>dispatch.parameter.error=Request[{0}] does not contain method
> > mapping
> > > > for
> > > > > >
> > > > > > {1}
> > > > > >
> > > > > > Index: LookupDispatchAction.java
> > > > > >
> ===================================================================
> > > > > > RCS file:
> > > > > >
> > > >
> > >
> >
> /home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LookupDis
> > > > > > patchAction.java,v
> > > > > > retrieving revision 1.10
> > > > > > diff -r1.10 LookupDispatchAction.java
> > > > > > 231d230
> > > > > > <
> > > > > > 233c232,235
> > > > > > <
> > > > > > ---
> > > > > >
> > > > > >>        if (methodName==null){
> > > > > >>            String message =
> > > > > >
> > > > > > messages.getMessage("dispatch.parameter.error", mapping.getPath(),
> > > > name);
> > > > > >
> > > > > >>            throw new ServletException(message);
> > > > > >>        }
> > > > > >
> > > > > >
> > > > > > <comment>
> > > > > > Please don't get me wrong I'm a big fan/advocate of struts and
> > wasn't
> > > > trying
> > > > > > to say it was Strut's fault.
> > > > > > I was merely trying to submit a patch; and avoid hours of
> > frustration
> > > > for
> > > > > > the people that use resin/ struts
> > > > > >
> > > > > > If it works on platform and not the other , we all might as well
> be
> > > > > > developing Microsoft applications.
> > > > > > </comment>
> > > > > >
> > > > > > ----- Original Message -----
> > > > > > From: "Wendy Smoak" <We...@asu.edu>
> > > > > > To: "'Struts Developers List'" <st...@jakarta.apache.org>
> > > > > > Sent: Friday, January 17, 2003 6:56 AM
> > > > > > Subject: RE: [PATCH] Re: Nasty Error when use LookupDispatchAction
> > > > > >
> > > > > >
> > > > > >
> > > > > >>>Everything works beautifully until you try and mess the query
> > string
> > > > > >>>for e.g  /edit.do?submit=initchanged&key=10
> > > > > >>>there is no mapping for initx, hence there is no method name and
> > null
> > > > is
> > > > > >>>passed into the
> > > > > >>>return dispatchMethod(mapping, form, request, response,
> methodName)
> > > > > >>>which finally calls getMethod(String name, Class[]
> parameterTypes)
> > > > > >>>The end result is that application shuts down with VM error
> > > > > >>
> > > > > >>This has been discussed before and I believe the general consensus
> > is
> > > > that
> > > > > >>there's a bug in Resin.  If you try the same thing in Tomcat, you
> > will
> > > > > >
> > > > > > only
> > > > > >
> > > > > >>get an exception.
> > > > > >>
> > > > > >>Still, I don't like the behavior of LookupDispatchAction so I
> > override
> > > > the
> > > > > >>execute() method in which I examine the request parameters.  If
> the
> > > > > >
> > > > > > "action"
> > > > > >
> > > > > >>is present, I just call super.execute().  Otherwise I try to
> figure
> > > out
> > > > > >
> > > > > > what
> > > > > >
> > > > > >>would be appropriate (add?  edit?) before giving up and throwing
> an
> > > > > >>exception.
> > > > > >>
> > > > > >>I would like to add a "default" attribue to the tag in
> struts-config
> > > so
> > > > > >
> > > > > > you
> > > > > >
> > > > > >>can specify which method to call if the parameter isn't present in
> > the
> > > > > >>request.
> > > > > >>
> > > > > >>In short, I don't think that VM Error is the fault of Struts.
> > > > > >>
> > > > > >>--
> > > > > >>Wendy Smoak
> > > > > >>Applications Systems Analyst, Sr.
> > > > > >>Arizona State University PA Information Resources Management
> > > > > >>
> > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > > To unsubscribe, e-mail:
> > > > <ma...@jakarta.apache.org>
> > > > > > For additional commands, e-mail:
> > > > <ma...@jakarta.apache.org>
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Ted Husted,
> > > > > Struts in Action <http://husted.com/struts/book.html>
> > > > >
> > > > >
> > > > > --
> > > > > To unsubscribe, e-mail:
> > > > <ma...@jakarta.apache.org>
> > > > > For additional commands, e-mail:
> > > > <ma...@jakarta.apache.org>
> > > > >
> > > >
> > > >
> > > > --
> > > > To unsubscribe, e-mail:
> > > <ma...@jakarta.apache.org>
> > > > For additional commands, e-mail:
> > > <ma...@jakarta.apache.org>
> > > >
> > > >
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > <ma...@jakarta.apache.org>
> > > For additional commands, e-mail:
> > <ma...@jakarta.apache.org>
> > >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: struts-dev-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: struts-dev-help@jakarta.apache.org
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: struts-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: struts-dev-help@jakarta.apache.org
> 


__________________________________________________
Do you Yahoo!?
Yahoo! Shopping - Send Flowers for Valentine's Day
http://shopping.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-dev-help@jakarta.apache.org


Re: [PATCH] LookupDispatchAction

Posted by A Stephen <st...@attbi.com>.
Greetings,
I use wincvs to work with CVS , am not sure how to save cvs diff -u format

David Graham, thx for accepting the patch and providing a more elegant
solution.
Thank you,
-S



----- Original Message -----
From: "A Stephen" <st...@attbi.com>
To: "Struts Developers List" <st...@jakarta.apache.org>
Sent: Sunday, February 02, 2003 11:55 AM
Subject: Re: [PATCH] LookupDispatchAction


> Thank you very much for the tip.
> I posted the bug and attached the proposed patch
> <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16678>.
>
> Thanks again,
> cheers,
> -S
>
> ----- Original Message -----
> From: "James Mitchell" <jm...@apache.org>
> To: "Struts Developers List" <st...@jakarta.apache.org>
> Sent: Monday, January 20, 2003 8:03 AM
> Subject: Re: [PATCH] LookupDispatchAction
>
>
> > It means that you should use bugzilla to upload the patch as a text file
> (to
> > the bug report it fixes), that way it won't get lost in the mailing
list.
> > The biggest reason though is that it let's struts developers try out and
> > test the path instead of wasting time recreating what you've already
done.
> >
> > Thanks for the patch!!
> >
> >
> > --
> > James Mitchell
> >
> >
> >
> >
> >
> > ----- Original Message -----
> > From: "A Stephen" <st...@attbi.com>
> > To: "Struts Developers List" <st...@jakarta.apache.org>
> > Sent: Sunday, January 19, 2003 4:16 PM
> > Subject: Re: [PATCH] LookupDispatchAction
> >
> >
> > > I'm sorry but I don't understand
> > > <quote>
> > > Contrary to the general advice on the Bugzilla page, we actually like
> > > these attached to the corresponding ticket =:0)
> > > </quote>
> > >
> > > Do I have to do something? I'm new to this process.
> > > Thanks for your help,
> > > -S
> > >
> > > ----- Original Message -----
> > > From: "Ted Husted" <hu...@apache.org>
> > > To: "Struts Developers List" <st...@jakarta.apache.org>
> > > Sent: Sunday, January 19, 2003 12:46 PM
> > > Subject: Re: [PATCH] LookupDispatchAction
> > >
> > >
> > > > Contrary to the general advice on the Bugzilla page, we actually
like
> > > > these attached to the corresponding ticket =:0)
> > > >
> > > > -Ted.
> > > >
> > > > A Stephen wrote:
> > > > > [PATCH]
> > > > > Index: LocalStrings.properties
> > > > >
===================================================================
> > > > > RCS file:
> > > > >
> > >
> >
>
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LocalStri
> > > > > ngs.properties,v
> > > > > retrieving revision 1.5
> > > > > diff -r1.5 LocalStrings.properties
> > > > > 5a6
> > > > >
> > > > >>dispatch.parameter.error=Request[{0}] does not contain method
> mapping
> > > for
> > > > >
> > > > > {1}
> > > > >
> > > > > Index: LookupDispatchAction.java
> > > > >
===================================================================
> > > > > RCS file:
> > > > >
> > >
> >
>
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LookupDis
> > > > > patchAction.java,v
> > > > > retrieving revision 1.10
> > > > > diff -r1.10 LookupDispatchAction.java
> > > > > 231d230
> > > > > <
> > > > > 233c232,235
> > > > > <
> > > > > ---
> > > > >
> > > > >>        if (methodName==null){
> > > > >>            String message =
> > > > >
> > > > > messages.getMessage("dispatch.parameter.error", mapping.getPath(),
> > > name);
> > > > >
> > > > >>            throw new ServletException(message);
> > > > >>        }
> > > > >
> > > > >
> > > > > <comment>
> > > > > Please don't get me wrong I'm a big fan/advocate of struts and
> wasn't
> > > trying
> > > > > to say it was Strut's fault.
> > > > > I was merely trying to submit a patch; and avoid hours of
> frustration
> > > for
> > > > > the people that use resin/ struts
> > > > >
> > > > > If it works on platform and not the other , we all might as well
be
> > > > > developing Microsoft applications.
> > > > > </comment>
> > > > >
> > > > > ----- Original Message -----
> > > > > From: "Wendy Smoak" <We...@asu.edu>
> > > > > To: "'Struts Developers List'" <st...@jakarta.apache.org>
> > > > > Sent: Friday, January 17, 2003 6:56 AM
> > > > > Subject: RE: [PATCH] Re: Nasty Error when use LookupDispatchAction
> > > > >
> > > > >
> > > > >
> > > > >>>Everything works beautifully until you try and mess the query
> string
> > > > >>>for e.g  /edit.do?submit=initchanged&key=10
> > > > >>>there is no mapping for initx, hence there is no method name and
> null
> > > is
> > > > >>>passed into the
> > > > >>>return dispatchMethod(mapping, form, request, response,
methodName)
> > > > >>>which finally calls getMethod(String name, Class[]
parameterTypes)
> > > > >>>The end result is that application shuts down with VM error
> > > > >>
> > > > >>This has been discussed before and I believe the general consensus
> is
> > > that
> > > > >>there's a bug in Resin.  If you try the same thing in Tomcat, you
> will
> > > > >
> > > > > only
> > > > >
> > > > >>get an exception.
> > > > >>
> > > > >>Still, I don't like the behavior of LookupDispatchAction so I
> override
> > > the
> > > > >>execute() method in which I examine the request parameters.  If
the
> > > > >
> > > > > "action"
> > > > >
> > > > >>is present, I just call super.execute().  Otherwise I try to
figure
> > out
> > > > >
> > > > > what
> > > > >
> > > > >>would be appropriate (add?  edit?) before giving up and throwing
an
> > > > >>exception.
> > > > >>
> > > > >>I would like to add a "default" attribue to the tag in
struts-config
> > so
> > > > >
> > > > > you
> > > > >
> > > > >>can specify which method to call if the parameter isn't present in
> the
> > > > >>request.
> > > > >>
> > > > >>In short, I don't think that VM Error is the fault of Struts.
> > > > >>
> > > > >>--
> > > > >>Wendy Smoak
> > > > >>Applications Systems Analyst, Sr.
> > > > >>Arizona State University PA Information Resources Management
> > > > >>
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > To unsubscribe, e-mail:
> > > <ma...@jakarta.apache.org>
> > > > > For additional commands, e-mail:
> > > <ma...@jakarta.apache.org>
> > > > >
> > > > >
> > > >
> > > >
> > > > --
> > > > Ted Husted,
> > > > Struts in Action <http://husted.com/struts/book.html>
> > > >
> > > >
> > > > --
> > > > To unsubscribe, e-mail:
> > > <ma...@jakarta.apache.org>
> > > > For additional commands, e-mail:
> > > <ma...@jakarta.apache.org>
> > > >
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > <ma...@jakarta.apache.org>
> > > For additional commands, e-mail:
> > <ma...@jakarta.apache.org>
> > >
> > >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: struts-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: struts-dev-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-dev-help@jakarta.apache.org


Re: [PATCH] LookupDispatchAction

Posted by A Stephen <st...@attbi.com>.
Thank you very much for the tip.
I posted the bug and attached the proposed patch
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16678>.

Thanks again,
cheers,
-S

----- Original Message -----
From: "James Mitchell" <jm...@apache.org>
To: "Struts Developers List" <st...@jakarta.apache.org>
Sent: Monday, January 20, 2003 8:03 AM
Subject: Re: [PATCH] LookupDispatchAction


> It means that you should use bugzilla to upload the patch as a text file
(to
> the bug report it fixes), that way it won't get lost in the mailing list.
> The biggest reason though is that it let's struts developers try out and
> test the path instead of wasting time recreating what you've already done.
>
> Thanks for the patch!!
>
>
> --
> James Mitchell
>
>
>
>
>
> ----- Original Message -----
> From: "A Stephen" <st...@attbi.com>
> To: "Struts Developers List" <st...@jakarta.apache.org>
> Sent: Sunday, January 19, 2003 4:16 PM
> Subject: Re: [PATCH] LookupDispatchAction
>
>
> > I'm sorry but I don't understand
> > <quote>
> > Contrary to the general advice on the Bugzilla page, we actually like
> > these attached to the corresponding ticket =:0)
> > </quote>
> >
> > Do I have to do something? I'm new to this process.
> > Thanks for your help,
> > -S
> >
> > ----- Original Message -----
> > From: "Ted Husted" <hu...@apache.org>
> > To: "Struts Developers List" <st...@jakarta.apache.org>
> > Sent: Sunday, January 19, 2003 12:46 PM
> > Subject: Re: [PATCH] LookupDispatchAction
> >
> >
> > > Contrary to the general advice on the Bugzilla page, we actually like
> > > these attached to the corresponding ticket =:0)
> > >
> > > -Ted.
> > >
> > > A Stephen wrote:
> > > > [PATCH]
> > > > Index: LocalStrings.properties
> > > > ===================================================================
> > > > RCS file:
> > > >
> >
>
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LocalStri
> > > > ngs.properties,v
> > > > retrieving revision 1.5
> > > > diff -r1.5 LocalStrings.properties
> > > > 5a6
> > > >
> > > >>dispatch.parameter.error=Request[{0}] does not contain method
mapping
> > for
> > > >
> > > > {1}
> > > >
> > > > Index: LookupDispatchAction.java
> > > > ===================================================================
> > > > RCS file:
> > > >
> >
>
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LookupDis
> > > > patchAction.java,v
> > > > retrieving revision 1.10
> > > > diff -r1.10 LookupDispatchAction.java
> > > > 231d230
> > > > <
> > > > 233c232,235
> > > > <
> > > > ---
> > > >
> > > >>        if (methodName==null){
> > > >>            String message =
> > > >
> > > > messages.getMessage("dispatch.parameter.error", mapping.getPath(),
> > name);
> > > >
> > > >>            throw new ServletException(message);
> > > >>        }
> > > >
> > > >
> > > > <comment>
> > > > Please don't get me wrong I'm a big fan/advocate of struts and
wasn't
> > trying
> > > > to say it was Strut's fault.
> > > > I was merely trying to submit a patch; and avoid hours of
frustration
> > for
> > > > the people that use resin/ struts
> > > >
> > > > If it works on platform and not the other , we all might as well be
> > > > developing Microsoft applications.
> > > > </comment>
> > > >
> > > > ----- Original Message -----
> > > > From: "Wendy Smoak" <We...@asu.edu>
> > > > To: "'Struts Developers List'" <st...@jakarta.apache.org>
> > > > Sent: Friday, January 17, 2003 6:56 AM
> > > > Subject: RE: [PATCH] Re: Nasty Error when use LookupDispatchAction
> > > >
> > > >
> > > >
> > > >>>Everything works beautifully until you try and mess the query
string
> > > >>>for e.g  /edit.do?submit=initchanged&key=10
> > > >>>there is no mapping for initx, hence there is no method name and
null
> > is
> > > >>>passed into the
> > > >>>return dispatchMethod(mapping, form, request, response, methodName)
> > > >>>which finally calls getMethod(String name, Class[] parameterTypes)
> > > >>>The end result is that application shuts down with VM error
> > > >>
> > > >>This has been discussed before and I believe the general consensus
is
> > that
> > > >>there's a bug in Resin.  If you try the same thing in Tomcat, you
will
> > > >
> > > > only
> > > >
> > > >>get an exception.
> > > >>
> > > >>Still, I don't like the behavior of LookupDispatchAction so I
override
> > the
> > > >>execute() method in which I examine the request parameters.  If the
> > > >
> > > > "action"
> > > >
> > > >>is present, I just call super.execute().  Otherwise I try to figure
> out
> > > >
> > > > what
> > > >
> > > >>would be appropriate (add?  edit?) before giving up and throwing an
> > > >>exception.
> > > >>
> > > >>I would like to add a "default" attribue to the tag in struts-config
> so
> > > >
> > > > you
> > > >
> > > >>can specify which method to call if the parameter isn't present in
the
> > > >>request.
> > > >>
> > > >>In short, I don't think that VM Error is the fault of Struts.
> > > >>
> > > >>--
> > > >>Wendy Smoak
> > > >>Applications Systems Analyst, Sr.
> > > >>Arizona State University PA Information Resources Management
> > > >>
> > > >
> > > >
> > > >
> > > > --
> > > > To unsubscribe, e-mail:
> > <ma...@jakarta.apache.org>
> > > > For additional commands, e-mail:
> > <ma...@jakarta.apache.org>
> > > >
> > > >
> > >
> > >
> > > --
> > > Ted Husted,
> > > Struts in Action <http://husted.com/struts/book.html>
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > <ma...@jakarta.apache.org>
> > > For additional commands, e-mail:
> > <ma...@jakarta.apache.org>
> > >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> >
> >
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-dev-help@jakarta.apache.org


Re: [PATCH] LookupDispatchAction

Posted by James Mitchell <jm...@apache.org>.
It means that you should use bugzilla to upload the patch as a text file (to
the bug report it fixes), that way it won't get lost in the mailing list.
The biggest reason though is that it let's struts developers try out and
test the path instead of wasting time recreating what you've already done.

Thanks for the patch!!


--
James Mitchell





----- Original Message -----
From: "A Stephen" <st...@attbi.com>
To: "Struts Developers List" <st...@jakarta.apache.org>
Sent: Sunday, January 19, 2003 4:16 PM
Subject: Re: [PATCH] LookupDispatchAction


> I'm sorry but I don't understand
> <quote>
> Contrary to the general advice on the Bugzilla page, we actually like
> these attached to the corresponding ticket =:0)
> </quote>
>
> Do I have to do something? I'm new to this process.
> Thanks for your help,
> -S
>
> ----- Original Message -----
> From: "Ted Husted" <hu...@apache.org>
> To: "Struts Developers List" <st...@jakarta.apache.org>
> Sent: Sunday, January 19, 2003 12:46 PM
> Subject: Re: [PATCH] LookupDispatchAction
>
>
> > Contrary to the general advice on the Bugzilla page, we actually like
> > these attached to the corresponding ticket =:0)
> >
> > -Ted.
> >
> > A Stephen wrote:
> > > [PATCH]
> > > Index: LocalStrings.properties
> > > ===================================================================
> > > RCS file:
> > >
>
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LocalStri
> > > ngs.properties,v
> > > retrieving revision 1.5
> > > diff -r1.5 LocalStrings.properties
> > > 5a6
> > >
> > >>dispatch.parameter.error=Request[{0}] does not contain method mapping
> for
> > >
> > > {1}
> > >
> > > Index: LookupDispatchAction.java
> > > ===================================================================
> > > RCS file:
> > >
>
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LookupDis
> > > patchAction.java,v
> > > retrieving revision 1.10
> > > diff -r1.10 LookupDispatchAction.java
> > > 231d230
> > > <
> > > 233c232,235
> > > <
> > > ---
> > >
> > >>        if (methodName==null){
> > >>            String message =
> > >
> > > messages.getMessage("dispatch.parameter.error", mapping.getPath(),
> name);
> > >
> > >>            throw new ServletException(message);
> > >>        }
> > >
> > >
> > > <comment>
> > > Please don't get me wrong I'm a big fan/advocate of struts and wasn't
> trying
> > > to say it was Strut's fault.
> > > I was merely trying to submit a patch; and avoid hours of frustration
> for
> > > the people that use resin/ struts
> > >
> > > If it works on platform and not the other , we all might as well be
> > > developing Microsoft applications.
> > > </comment>
> > >
> > > ----- Original Message -----
> > > From: "Wendy Smoak" <We...@asu.edu>
> > > To: "'Struts Developers List'" <st...@jakarta.apache.org>
> > > Sent: Friday, January 17, 2003 6:56 AM
> > > Subject: RE: [PATCH] Re: Nasty Error when use LookupDispatchAction
> > >
> > >
> > >
> > >>>Everything works beautifully until you try and mess the query string
> > >>>for e.g  /edit.do?submit=initchanged&key=10
> > >>>there is no mapping for initx, hence there is no method name and null
> is
> > >>>passed into the
> > >>>return dispatchMethod(mapping, form, request, response, methodName)
> > >>>which finally calls getMethod(String name, Class[] parameterTypes)
> > >>>The end result is that application shuts down with VM error
> > >>
> > >>This has been discussed before and I believe the general consensus is
> that
> > >>there's a bug in Resin.  If you try the same thing in Tomcat, you will
> > >
> > > only
> > >
> > >>get an exception.
> > >>
> > >>Still, I don't like the behavior of LookupDispatchAction so I override
> the
> > >>execute() method in which I examine the request parameters.  If the
> > >
> > > "action"
> > >
> > >>is present, I just call super.execute().  Otherwise I try to figure
out
> > >
> > > what
> > >
> > >>would be appropriate (add?  edit?) before giving up and throwing an
> > >>exception.
> > >>
> > >>I would like to add a "default" attribue to the tag in struts-config
so
> > >
> > > you
> > >
> > >>can specify which method to call if the parameter isn't present in the
> > >>request.
> > >>
> > >>In short, I don't think that VM Error is the fault of Struts.
> > >>
> > >>--
> > >>Wendy Smoak
> > >>Applications Systems Analyst, Sr.
> > >>Arizona State University PA Information Resources Management
> > >>
> > >
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> > > For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> > >
> > >
> >
> >
> > --
> > Ted Husted,
> > Struts in Action <http://husted.com/struts/book.html>
> >
> >
> > --
> > To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> >
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: [PATCH] LookupDispatchAction

Posted by A Stephen <st...@attbi.com>.
I'm sorry but I don't understand
<quote>
Contrary to the general advice on the Bugzilla page, we actually like
these attached to the corresponding ticket =:0)
</quote>

Do I have to do something? I'm new to this process.
Thanks for your help,
-S

----- Original Message -----
From: "Ted Husted" <hu...@apache.org>
To: "Struts Developers List" <st...@jakarta.apache.org>
Sent: Sunday, January 19, 2003 12:46 PM
Subject: Re: [PATCH] LookupDispatchAction


> Contrary to the general advice on the Bugzilla page, we actually like
> these attached to the corresponding ticket =:0)
>
> -Ted.
>
> A Stephen wrote:
> > [PATCH]
> > Index: LocalStrings.properties
> > ===================================================================
> > RCS file:
> >
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LocalStri
> > ngs.properties,v
> > retrieving revision 1.5
> > diff -r1.5 LocalStrings.properties
> > 5a6
> >
> >>dispatch.parameter.error=Request[{0}] does not contain method mapping
for
> >
> > {1}
> >
> > Index: LookupDispatchAction.java
> > ===================================================================
> > RCS file:
> >
/home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LookupDis
> > patchAction.java,v
> > retrieving revision 1.10
> > diff -r1.10 LookupDispatchAction.java
> > 231d230
> > <
> > 233c232,235
> > <
> > ---
> >
> >>        if (methodName==null){
> >>            String message =
> >
> > messages.getMessage("dispatch.parameter.error", mapping.getPath(),
name);
> >
> >>            throw new ServletException(message);
> >>        }
> >
> >
> > <comment>
> > Please don't get me wrong I'm a big fan/advocate of struts and wasn't
trying
> > to say it was Strut's fault.
> > I was merely trying to submit a patch; and avoid hours of frustration
for
> > the people that use resin/ struts
> >
> > If it works on platform and not the other , we all might as well be
> > developing Microsoft applications.
> > </comment>
> >
> > ----- Original Message -----
> > From: "Wendy Smoak" <We...@asu.edu>
> > To: "'Struts Developers List'" <st...@jakarta.apache.org>
> > Sent: Friday, January 17, 2003 6:56 AM
> > Subject: RE: [PATCH] Re: Nasty Error when use LookupDispatchAction
> >
> >
> >
> >>>Everything works beautifully until you try and mess the query string
> >>>for e.g  /edit.do?submit=initchanged&key=10
> >>>there is no mapping for initx, hence there is no method name and null
is
> >>>passed into the
> >>>return dispatchMethod(mapping, form, request, response, methodName)
> >>>which finally calls getMethod(String name, Class[] parameterTypes)
> >>>The end result is that application shuts down with VM error
> >>
> >>This has been discussed before and I believe the general consensus is
that
> >>there's a bug in Resin.  If you try the same thing in Tomcat, you will
> >
> > only
> >
> >>get an exception.
> >>
> >>Still, I don't like the behavior of LookupDispatchAction so I override
the
> >>execute() method in which I examine the request parameters.  If the
> >
> > "action"
> >
> >>is present, I just call super.execute().  Otherwise I try to figure out
> >
> > what
> >
> >>would be appropriate (add?  edit?) before giving up and throwing an
> >>exception.
> >>
> >>I would like to add a "default" attribue to the tag in struts-config so
> >
> > you
> >
> >>can specify which method to call if the parameter isn't present in the
> >>request.
> >>
> >>In short, I don't think that VM Error is the fault of Struts.
> >>
> >>--
> >>Wendy Smoak
> >>Applications Systems Analyst, Sr.
> >>Arizona State University PA Information Resources Management
> >>
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> > For additional commands, e-mail:
<ma...@jakarta.apache.org>
> >
> >
>
>
> --
> Ted Husted,
> Struts in Action <http://husted.com/struts/book.html>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: [PATCH] LookupDispatchAction

Posted by Ted Husted <hu...@apache.org>.
Contrary to the general advice on the Bugzilla page, we actually like 
these attached to the corresponding ticket =:0)

-Ted.

A Stephen wrote:
> [PATCH]
> Index: LocalStrings.properties
> ===================================================================
> RCS file:
> /home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LocalStri
> ngs.properties,v
> retrieving revision 1.5
> diff -r1.5 LocalStrings.properties
> 5a6
> 
>>dispatch.parameter.error=Request[{0}] does not contain method mapping  for
> 
> {1}
> 
> Index: LookupDispatchAction.java
> ===================================================================
> RCS file:
> /home/cvspublic/jakarta-struts/src/share/org/apache/struts/actions/LookupDis
> patchAction.java,v
> retrieving revision 1.10
> diff -r1.10 LookupDispatchAction.java
> 231d230
> <
> 233c232,235
> <
> ---
> 
>>        if (methodName==null){
>>            String message =
> 
> messages.getMessage("dispatch.parameter.error", mapping.getPath(), name);
> 
>>            throw new ServletException(message);
>>        }
> 
> 
> <comment>
> Please don't get me wrong I'm a big fan/advocate of struts and wasn't trying
> to say it was Strut's fault.
> I was merely trying to submit a patch; and avoid hours of frustration for
> the people that use resin/ struts
> 
> If it works on platform and not the other , we all might as well be
> developing Microsoft applications.
> </comment>
> 
> ----- Original Message -----
> From: "Wendy Smoak" <We...@asu.edu>
> To: "'Struts Developers List'" <st...@jakarta.apache.org>
> Sent: Friday, January 17, 2003 6:56 AM
> Subject: RE: [PATCH] Re: Nasty Error when use LookupDispatchAction
> 
> 
> 
>>>Everything works beautifully until you try and mess the query string
>>>for e.g  /edit.do?submit=initchanged&key=10
>>>there is no mapping for initx, hence there is no method name and null is
>>>passed into the
>>>return dispatchMethod(mapping, form, request, response, methodName)
>>>which finally calls getMethod(String name, Class[] parameterTypes)
>>>The end result is that application shuts down with VM error
>>
>>This has been discussed before and I believe the general consensus is that
>>there's a bug in Resin.  If you try the same thing in Tomcat, you will
> 
> only
> 
>>get an exception.
>>
>>Still, I don't like the behavior of LookupDispatchAction so I override the
>>execute() method in which I examine the request parameters.  If the
> 
> "action"
> 
>>is present, I just call super.execute().  Otherwise I try to figure out
> 
> what
> 
>>would be appropriate (add?  edit?) before giving up and throwing an
>>exception.
>>
>>I would like to add a "default" attribue to the tag in struts-config so
> 
> you
> 
>>can specify which method to call if the parameter isn't present in the
>>request.
>>
>>In short, I don't think that VM Error is the fault of Struts.
>>
>>--
>>Wendy Smoak
>>Applications Systems Analyst, Sr.
>>Arizona State University PA Information Resources Management
>>
> 
> 
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
> 
> 


-- 
Ted Husted,
Struts in Action <http://husted.com/struts/book.html>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>