See the following thread:
http://www.nabble.com/-S2--Duty-now-for-the-future--%28was-Re%3A-Question-ab
out-struts2%29-tf2559552.html#a7132875

Struts2 also depends on a beta(snapshot) release of XWork2.

Hth,
Peter

-----Original Message-----
From: Tarek Nabil [mailto:[EMAIL PROTECTED] 
Sent: den 26 november 2006 06:41
To: Struts Users Mailing List
Subject: RE: Parameters not being set on Action in Struts 2

Thanks Ted.

I renamed my method to "execute" and changed the URL to remove the "!setup"
part.

I also changed the struts.xml file accordingly, so now it's like that (note
that I removed the input result, just in case it's causing any problems).


        <action
            name="dod1"
            class="packagename.ActionClassName">
            <result name="page">/jsp/billCreation/PageName.jsp</result>
        </action>

I was pretty sure that the correct method was being executed, because I had
some logging statements inside. One of those statements is the one that
attempts to log the parameter Map and it's still giving the same result; an
empty Map.

I know you guys are doing a great effort trying to get this framework out,
but if I have a project starting in one month and delivering four months
later, would you recommend Struts 2 for that?

Please note that means that most development will be done using a
pre-release version, so do you think this version is stable enough to be
used by a team of 30 to 40 people where delays could cause a great damage?

And, although I know this question is very difficult to answer for OS
projects, do you think this framework will be ready for prime time in 5
months? The application is a heavy transactional one and is required to
scale for thousands of transactions per day.

Your advice is greatly appreciated.


-----Original Message-----
From: Ted Husted [mailto:[EMAIL PROTECTED]
Sent: Saturday, November 25, 2006 5:25 PM
To: Struts Users Mailing List
Subject: Re: Parameters not being set on Action in Struts 2

First, simplify the problem. Right now, the code seems to be calling an
alternative method, setup. What happens if you try the same thing with the
default execute method?

If your application is based on the blank application, it may turned the "!"
syntax off, since it can conflict with using wildcards. To use the Check the
struts.properties file for the line "struts.enable.DynamicMethodInvocation",
and set it to true.

We're working on some new code for Struts 2 that will extend the "!"
syntax so that it can happily coexist with wildcards.

-Ted.

On 11/23/06, Tarek Nabil <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I'm experimenting with Struts 2, and I'm facing a problem with request 
> parameters being populated on the Action. I checked out the source to 
> make sure that the behavior I expect is the correct one, and judging
by
> the source, it is, but it's not happening.
>
>
> I have an action that has a method
>
> public void setType(Integer type) {
>         // some code
> }
>
> I declared the action in Struts.xml as follows
>
>         <action
>             name="dod1"
>             method="setup"
>             class="somePackageName.someClassName">
>             <result name="page">/jsp/someFolder/someJSP.jsp</result>
>             <result name="input" type="chain">dod1!setup</result>
>         </action>
>
> In the setup method, I put the following line
>
>             logger.debug(getContext().getParameters());
>
> In the URL, I call the following
>
> http://server/application/namespace/dod1!setup.action?type=1
>
> The result is that the parameters map is logged as {} and in my method 
> when I attempt to access the type field, I find it to be null!
>
> Could someone please point me to what could be wrong?
>
> Thanks,
> Tarek Nabil
********************************************DISCLAIMER**********************
**********************
This email and any files transmitted with it are confidential and contain
privileged or copyright information. If you are not the intended recipient
you must not copy, distribute or use this email or the information contained
in it for any purpose other than to notify us of the receipt thereof.
If you have received this message in error, please notify the sender
immediately, and delete this email from your system.

Please note that e-mails are susceptible to change.The sender shall not be
liable for the improper or incomplete transmission of the information
contained in this communication,nor for any delay in its receipt or damage
to your system.The sender does not guarantee that this material is free from
viruses or any other defects although due care has been taken to minimise
the risk.
****************************************************************************
**********************

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to