Re: REST plugin and security

2007-12-14 Thread Martin Gilday
Hi Don,
I think we are using WS-Security, but I have not been too involved in
it.  I just wanted to confirm that a reasonable equivalent was
available.  

Is it possible with the S2 plugin to do one of the classical examples of
getting resources by date e.g. /orders/2007/12/13.  It would be great if
you could map that onto something like a Joda MutableDateTime. From the
wiki you just seem to be able to have a single ID parameter set on your
action.  I really like the Django approach of a mapping script where you
define regex expressions which map onto functions with all the defined
parameter placeholders.

Martin.


- Original message -
From: "Don Brown" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Fri, 14 Dec 2007 09:48:03 +1100
Subject: Re: REST plugin and security

If you are putting username and password in the soap headers, why not
just use basic authentication for your REST services, which basically
does the same thing?  If over the wire security is a problem, use
HTTPS.

Don

On Dec 14, 2007 1:44 AM, Martin Gilday <[EMAIL PROTECTED]> wrote:
> Hi,
> We are interested in using the REST plugin to extend customer choice and
> complement our WS-* services.  We are particularly interested in the
> multiple response types (.xml, .json etc).  One thing I am not sure of
> is how we handle security.  Say we have an order (/order/1234.xml), how
> can we protect this so this is only available to the owner of the order?
>  In our current system they would provide their username and password in
> the soap security headers.  We use Acegi/Spring Security.  This is
> probably more of a general REST issue, but I am interested in if the
> plugin helps out at all.
>
> Thanks,
> Martin.
>
> -
> 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]


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



REST plugin and security

2007-12-13 Thread Martin Gilday
Hi,
We are interested in using the REST plugin to extend customer choice and
complement our WS-* services.  We are particularly interested in the
multiple response types (.xml, .json etc).  One thing I am not sure of
is how we handle security.  Say we have an order (/order/1234.xml), how
can we protect this so this is only available to the owner of the order?
 In our current system they would provide their username and password in
the soap security headers.  We use Acegi/Spring Security.  This is
probably more of a general REST issue, but I am interested in if the
plugin helps out at all.  

Thanks,
Martin.

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



Re: [s2] Different Annotated Validations for different action methods

2007-12-04 Thread Martin Gilday
I posted about this a while back.  Nobody seemed to have an annotation
based solution, only going back to XML.


- Original message -
From: "Thilo Ettelt" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Tue, 4 Dec 2007 13:01:15 +0100
Subject: [s2] Different Annotated Validations for different action
methods

Hey all,

I'm trying to figure out how to validate my action methods differently.

For example I've got a modeldriven User bean with the following two  
annotated methods

@Validations(...)
- processLogin

@Validations(...)
- processSignup



Now I want the first annotation to only check for the username and  
password, but the second annotation is supposed to check for other  
things like email too.

However when I call the appropriate action mapping which calls  
processSignup it processes both Validations, which results in a  
invalid email address error for the login in addition to the wrong  
username and password.

So how can I separate the two validatio annotations without needing  
separate classes?


- Thilo

-- 
Mit freundlichen Grüßen,

Thilo Ettelt  Telefon: +49-421-6265-111
Carmunity.com GmbHTelefax: +49-421-6265-100
Mary-Astell-Strasse 2 E-Mail: [EMAIL PROTECTED]
28359 Bremen  http://www.carmunity.de/

Developer (YourVids)

Handelsregisternummer: HRB 19256 beim AG Bremen
Geschäftsführer:
Dipl.-Wirt.-Ing. W. Schlösser
Dipl-Ing. Frank Rothgänger
Bennet Bock


-
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]



Re: Unnecessary onsubmit

2007-11-27 Thread Martin Gilday
Sorry ignore.  Someone had been using a theme written for WebWork which
had this customOnsubmit in.  It seems to have changed in the new
form.ftl in 2.0.11 to be simply "return true;", which is better.


- Original message -----
From: "Martin Gilday" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Tue, 27 Nov 2007 16:29:11 +
Subject: Re: Unnecessary onsubmit

I've not used a validation attribute.  An example:
<@s.form namespace="/" action="registration!save" method="post">

The stack just has the standard interceptor ref 
Is this an old issue, I get the same alert in JIRA all the time
(WebWork?)

- Original message -
From: "Dave Newton" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Tue, 27 Nov 2007 08:16:42 -0800 (PST)
Subject: Re: Unnecessary onsubmit

With the regular  tag without the
"validation" attribute set?!

d.

--- Martin Gilday <[EMAIL PROTECTED]> wrote:

> We are using the validaiton interceptor but not
> client side javascript
> validation.  However we are still seeing lots of
> onsubmit="customOnsubmit_registration(); return
> true;" appearing in the
> views.  On form submission you get a js error as the
> function does not
> exist.  Why is this appearing and is there a simple
> way to prevent it?
> 
> Thanks,
> Martin.
> 
>
-
> 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]


-
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]



Re: Unnecessary onsubmit

2007-11-27 Thread Martin Gilday
I've not used a validation attribute.  An example:
<@s.form namespace="/" action="registration!save" method="post">

The stack just has the standard interceptor ref 
Is this an old issue, I get the same alert in JIRA all the time
(WebWork?)

- Original message -
From: "Dave Newton" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Tue, 27 Nov 2007 08:16:42 -0800 (PST)
Subject: Re: Unnecessary onsubmit

With the regular  tag without the
"validation" attribute set?!

d.

--- Martin Gilday <[EMAIL PROTECTED]> wrote:

> We are using the validaiton interceptor but not
> client side javascript
> validation.  However we are still seeing lots of
> onsubmit="customOnsubmit_registration(); return
> true;" appearing in the
> views.  On form submission you get a js error as the
> function does not
> exist.  Why is this appearing and is there a simple
> way to prevent it?
> 
> Thanks,
> Martin.
> 
>
-
> 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]


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



Unnecessary onsubmit

2007-11-27 Thread Martin Gilday
We are using the validaiton interceptor but not client side javascript
validation.  However we are still seeing lots of
onsubmit="customOnsubmit_registration(); return true;" appearing in the
views.  On form submission you get a js error as the function does not
exist.  Why is this appearing and is there a simple way to prevent it?

Thanks,
Martin.

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



Re: Annotation Validation, per method?

2007-11-06 Thread Martin Gilday
Thanks.  Is this not a severe limitation of the annotation version if it
is more limited than the xml version?


- Original message -
From: "Fátima Silveira" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Mon, 5 Nov 2007 17:58:32 +0100
Subject: Re: Annotation Validation, per method?

i dont know to use anotation but with xml is
ClassName-actionAlias_method-
validation.xml

On 11/5/07, Martin Gilday <[EMAIL PROTECTED]> wrote:
>
> Can you have annotation validation per method?  I have put @Validations
> on both my display and update methods (display shows the record from
> input), but all of the validation seems to be run at once.  Can you
> achieve this with xml or annotation validation, or am I back to
> validateInput methods?
>
> Thanks,
> Martin.
>
> -
> 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]



Annotation Validation, per method?

2007-11-05 Thread Martin Gilday
Can you have annotation validation per method?  I have put @Validations
on both my display and update methods (display shows the record from
input), but all of the validation seems to be run at once.  Can you
achieve this with xml or annotation validation, or am I back to
validateInput methods?

Thanks,
Martin.

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



Re: Velocity dependency

2007-09-24 Thread Martin Gilday
Hi Leon,
Sorry I think I wasn't clear.  I do not wish to use Velocity, all my
views are Freemarker or JSP based.  I have found that it seems to be the
Struts2 Sitemesh plugin that causes problems.  As soon as I declare it
then I get NoClassDefFound problems until I manually add the Velocity
dependencies?  Are they needed to run the Sitemesh plugin?  They are
marked as optional in the plugin POM and I would rather not have to
include them.

Thanks,
Martin.


- Original message -
From: "Leonidas Papadakis" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Mon, 24 Sep 2007 17:38:16 +0300
Subject: Re: Velocity dependency

Hi there,

i had to do the following things in order to add full velocity support. 
The issue is that in struts2 even if you have to parse a velocity file, 
it has to be a result of an action. So in order to be able to parse 
velocity files even if they are not result of an action :

Add the following to web.xml:


velocity

org.apache.velocity.tools.view.servlet.VelocityViewServlet
 

1




velocity
*.shtml


Add the following jar files to lib folder :

velocity-dep-1.4.jar
velocity-tools-1.1.jar

Regards,

Leon

Martin Gilday wrote:
> I am porting a WebWork application over to Struts2.  I have added a
> dependency to struts2-core to my Maven POM.
> 
>   org.apache.struts
>   struts2-core
>   2.0.9
> 
>
> In my struts.xml I extend struts-default.  When I try and start my
> application I get a ClassDefNotFoundException.  Is Velocity required
> when extending struts-default?  This was not the case in WW where
> Freemaker was always the default.  If it is required is there a reason
> it is not a dependency in the struts-core POM?
>
> 2007-09-24 13:14:06.993::WARN:  Error starting handlers
> java.lang.NoClassDefFoundError: org/apache/velocity/app/VelocityEngine
> at java.lang.Class.getDeclaredFields0(Native Method)
> at java.lang.Class.privateGetDeclaredFields(Class.java:2291)
>
> -
> 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]


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



Velocity dependency

2007-09-24 Thread Martin Gilday
I am porting a WebWork application over to Struts2.  I have added a
dependency to struts2-core to my Maven POM.

  org.apache.struts
  struts2-core
  2.0.9


In my struts.xml I extend struts-default.  When I try and start my
application I get a ClassDefNotFoundException.  Is Velocity required
when extending struts-default?  This was not the case in WW where
Freemaker was always the default.  If it is required is there a reason
it is not a dependency in the struts-core POM?

2007-09-24 13:14:06.993::WARN:  Error starting handlers
java.lang.NoClassDefFoundError: org/apache/velocity/app/VelocityEngine
at java.lang.Class.getDeclaredFields0(Native Method)
at java.lang.Class.privateGetDeclaredFields(Class.java:2291)

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



Extended conversation/Wizards

2007-09-15 Thread Martin Gilday
Hi,
I am currently maintaining a WebWork 2 based web application.  A change
in requirements has come about which requires a fairly long wizard to be
added.  This will take in a fair amount of data entry, at least 6
screens long, with some ajax form population based on selections.  The
final database manipulation would only occur once the final screen has
been completed successfully.  The rest of the application is based on
Spring services with Hibernate 3.

We have been planning to upgrade, so to speak, the application to Struts
2 for some time.  This seems like the right time.  What I a looking at
is if there anything inside Struts 2 or an approach to take to achieve
this long conversation and delayed database commmit?  I think something
like JBoss Seam's conversation scope would be ideal for this, but I
would really rather not change frameworks for this (as WebWork/Struts2
has worked fantastically well).  In WebWork 2 there is some continuation
support borrowed from Rife, but has been marked experimental since the
start of the year.  I can see no mention of this on the Struts2 wiki. 
Is there any continuation support?  My other idea has been to look at
Spring Web Flow.  There seems to be a plugin to make this work with
Struts 2 http://code.google.com/p/struts2webflow/.  has anyone used this
in production?

Has anyone acheieved something like this in the past?  Any advice or
pointers very much appreciated.

Thanks,
Martin.

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



Re: Struts 2 performance

2007-07-11 Thread Martin Gilday
I have dropped 2.7 into a WW app which has been live for the past week
with zero (new) errors.  However, as has been stated, it needs to be
reworked to get the speed improvments.


- Original message -
From: "Musachy Barroso" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Wed, 11 Jul 2007 15:03:51 -0400
Subject: Re: Struts 2 performance

Struts tests pass with OGNL 2.7

musachy

On 7/11/07, James Holmes <[EMAIL PROTECTED]> wrote:
>
> It's not a simple JAR drop. The core XWork and Struts 2 libraries have to
> be
> updated to compile expressions. This will take some work, but I believe it
> is
> badly needed. I'm up for helping to do this work, but don't have much
> experience
> with the OGNL code. I also don't have commit access to the XWork code.
>
> What's the process for getting commit access to XWork for Struts
> committers?
>
> James
>
>
> On Wed Jul 11  9:39 , 'Guillaume Carré' <[EMAIL PROTECTED]> sent:
>
> >2007/7/11, Musachy Barroso [EMAIL PROTECTED]>:
> >> I think so far a couple of people have tried to decouple Struts 2 from
> OGNL,
> >> (so other libs like MVEL could be used), so far no patch has made it
> through
> >> :)
> >
> >have you considered upgrading to OGNL 2.7?
> >
> >Tapestry 4 did, there seems to be some performance improvement in this
> release:
> >http://blog.opencomponentry.com/2007/06/26/tapestry-412-ognl-27-released/
> >
> >is it a simple JAR drop?
> >--
> >Guillaume Carré
> >
> >-
> >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]
>
>


-- 
"Hey you! Would you help me to carry the stone?" Pink Floyd

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



ExecuteAndWaitInterceptor with round robin load balancing

2007-06-26 Thread Martin Gilday
Has anyone attempted to use the ExecuteAndWaitInterceptor with a load
balancer on round robin?  

I am having problems getting it to work with WebWork 2.2.5.  Seeing as
the interceptor looks unchanged in Struts 2 I thought it might be
worthwhile also asking here.  My problem is detailed
http://forums.opensymphony.com/thread.jspa?messageID=161853

My general concern is whether it is possible for this interceptor to
work with replicated sessions across a cluster?  Looking at the source
the BackgroundProcess created by the interceptor would need to be
replicated, along with the action inside it.  If you were then sent to a
different node would the interceptor correctly be able to determine if
the job had completed?

Thanks for any help,
Martin.

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



Re: [S2] + Spring - WebApplicationContext?

2007-06-24 Thread Martin Gilday
I might be missing the point here.  But why do you want to get hold of
an application contect directly?  You just want to pull out beans from
it to use in your actions?
You would be much better off using the Struts 2 Spring integration to
have it populate your actions for you.  No messy util classes pulling
things in.  Just put the setters on your action and let them be wired
in.

http://cwiki.apache.org/WW/spring-plugin.html

Martin.


- Original message -
From: "Zarar Siddiqi" <[EMAIL PROTECTED]>
To: user@struts.apache.org
Date: Sun, 24 Jun 2007 12:02:30 -0700 (PDT)
Subject: Re: [S2] + Spring - WebApplicationContext?


That'll work but if you want to use one line to get it, use this:

http://www.springframework.org/docs/api/org/springframework/web/context/support/WebApplicationContextUtils.html#getRequiredWebApplicationContext(javax.servlet.ServletContext)
WebApplicationContextUtils.getRequiredWebApplicationContext(servletContext) 

Zarar


Shibing.Chen wrote:
> 
> Let your Action implements ApplicationContextAware interface.
> 
> On 6/22/07, Paul <[EMAIL PROTECTED]> wrote:
>> Probably a dumb question but does anyone have an example of the best way
>> of obtaining the web application context within a Struts 2 action?
>>
>> I need to lookup and get a bean that I've configured in my spring
>> context.
>>
>> Thanks in advance!
>> Regards,
>> Paul
> 
> 
> -- 
> Think different.
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context:
http://www.nabble.com/-S2--%2B-Spring---WebApplicationContext--tf3965475.html#a11277442
Sent from the Struts - User mailing list archive at Nabble.com.


-
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]



Re: [S2] Tutorial with Eclipse

2007-06-13 Thread Martin Gilday
Hi.
You probably need to install the WTP (Web Tools Project) into your
Eclipse.

MArtin.


- Original message -
From: "hezjing" <[EMAIL PROTECTED]>
To: "struts-users" 
Date: Thu, 14 Jun 2007 00:20:04 +0800
Subject: [S2] Tutorial with Eclipse

Hi!

I have a fresh Eclipse installed and I'm following the "Struts 2 +
Spring 2 + JPA + AJAX" tutorial.

In the "Doing it yourself" section, it mentioned about File -> New ->
Project and select Dynamic Web Project under Web folder. Unfortunately
I'm don't see the Web folder ...

Did I miss out any step here?


-- 

Hez

-
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]



Re: Hibernate headache with struts 2

2007-05-19 Thread Martin Gilday
Looks like you are trying to access Hibernate managed objects or perform
session manipultion in your view.  Spring makes this easier but you can
do it manually easily. You just need to keep your session open longer. 
Have a google for things like open session in view filter. 


- Original message -
From: "Mansour" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Sat, 19 May 2007 12:36:51 -0300
Subject: Hibernate headache with struts 2

I am trying to use hibernate with my struts project. The problem I keep 
on getting :


javax.servlet.ServletException: org.hibernate.SessionException: Session
is closed!

org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:518)

org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:421)

com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:119)

com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:55)


This occurs when: session.commit(something);


Is this a struts 2 issue ? IF yes, then how to get s2 to work with 
hibernate. I have googled this, and every thing suggest using spring. 
This is not an option for me.

Can any one help ?


-
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]



Re: Looking for source to com.opensymphony.xwork2.ActionContext

2007-05-08 Thread Martin Gilday
http://www.opensymphony.com/xwork/download.action


- Original message -
From: "Al Sutton" <[EMAIL PROTECTED]>
To: "'Struts Users Mailing List'" 
Date: Tue, 8 May 2007 11:45:41 +0100
Subject: Looking for source to com.opensymphony.xwork2.ActionContext

Can anyone tell me where the source is for
com.opensymphony.xwork2.ActionContext?
 
I've got the following exception;
 
java.lang.NullPointerException
at
com.opensymphony.xwork2.ActionContext.setContext(ActionContext.java:142)
at
org.apache.struts2.dispatcher.ActionContextCleanUp.cleanUp(ActionContextClea
nUp.java:128)
at
org.apache.struts2.dispatcher.ActionContextCleanUp.doFilter(ActionContextCle
anUp.java:104)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:215)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:188)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:210)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:174)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127
)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117
)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:108)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
at
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processC
onnection(Http11BaseProtocol.java:665)
at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.jav
a:528)
at
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWo
rkerThread.java:81)
at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:685)
at java.lang.Thread.run(Unknown Source)

and I'm trying to track back to the cause.

Thanks,

Al.



-
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]



Re: [S2] Error in "File Download" in struts-showcase application

2007-05-07 Thread Martin Gilday
I've attached a patch to the JIRA issue.  The file paths were using \
rather than / in the filedownload.xml.
Could someone try it on Windows.

Thanks,
Martin.


- Original message -
From: "Martin Gilday" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" 
Date: Mon, 07 May 2007 15:03:12 +0100
Subject: Re: [S2] Error in "File Download" in struts-showcase
application

Just to confirm I have tried it on the SVN head and had the same error
using Jetty.


- Original message -
From: "Struts2 Fan" <[EMAIL PROTECTED]>
To: user@struts.apache.org
Date: Mon, 7 May 2007 06:52:10 -0700 (PDT)
Subject: Re: [S2] Error in "File Download" in struts-showcase
application


Ok I created the issue

https://issues.apache.org/struts/browse/WW-1915


Musachy Barroso wrote:
> 
> If you create an issue here:
> 
> https://issues.apache.org/struts/
> 
> it probably will. Thanks for reporting it.
> 
> musachy
> 
> On 5/7/07, Struts2 Fan <[EMAIL PROTECTED]> wrote:
>>
>>
>> Hi all,
>>
>> I checked out the struts2 source codes and run struts2-showcase app but
>> /struts2-showcase/filedownload/download.action is not working. It gives
>> the
>> following error.
>>
>> Can not find a java.io.InputStream with the name [inputStream] in the
>> invocation stack. Check the  tag specified for
>> this
>> action.
>>
>> RequestURI=/struts2-showcase/filedownload/download.action
>> Caused by:
>>
>> java.lang.IllegalArgumentException: Can not find a
>> java.io.InputStreamwith
>> the name [inputStream] in the invocation stack. Check the
>>
>> tag specified for this action. at
>> org.apache.struts2.dispatcher.StreamResult.doExecute(StreamResult.java
>> :189)
>> at
>> org.apache.struts2.dispatcher.StrutsResultSupport.execute(
>> StrutsResultSupport.java:178)
>> at
>> com.opensymphony.xwork2.DefaultActionInvocation.executeResult(
>> DefaultActionInvocation.java:348)
>> at
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke(
>> DefaultActionInvocation.java:253)
>> at
>> com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept
>> (DefaultWorkflowInterceptor.java:219)
>> at
>> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(
>> MethodFilterInterceptor.java:86)
>> at
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(
>> DefaultActionInvocation.java:224)
>> at
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(
>> DefaultActionInvocation.java:223)
>> at
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(
>> UtilTimerStack.java:455)
>> at
>>
>> Is there a way to correct it or should I wait for the next release?
>>
>> Thanks in advance.
>> --
>> View this message in context:
>> http://www.nabble.com/-S2--Error-in-%22File-Download%22-in-struts-showcase-application-tf3703170.html#a10355673
>> Sent from the Struts - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> 
> -- 
> "Hey you! Would you help me to carry the stone?" Pink Floyd
> 
> 

-- 
View this message in context:
http://www.nabble.com/-S2--Error-in-%22File-Download%22-in-struts-showcase-application-tf3703170.html#a10357747
Sent from the Struts - User mailing list archive at Nabble.com.


-
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]


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



Re: [S2] Error in "File Download" in struts-showcase application

2007-05-07 Thread Martin Gilday
Just to confirm I have tried it on the SVN head and had the same error
using Jetty.


- Original message -
From: "Struts2 Fan" <[EMAIL PROTECTED]>
To: user@struts.apache.org
Date: Mon, 7 May 2007 06:52:10 -0700 (PDT)
Subject: Re: [S2] Error in "File Download" in struts-showcase
application


Ok I created the issue

https://issues.apache.org/struts/browse/WW-1915


Musachy Barroso wrote:
> 
> If you create an issue here:
> 
> https://issues.apache.org/struts/
> 
> it probably will. Thanks for reporting it.
> 
> musachy
> 
> On 5/7/07, Struts2 Fan <[EMAIL PROTECTED]> wrote:
>>
>>
>> Hi all,
>>
>> I checked out the struts2 source codes and run struts2-showcase app but
>> /struts2-showcase/filedownload/download.action is not working. It gives
>> the
>> following error.
>>
>> Can not find a java.io.InputStream with the name [inputStream] in the
>> invocation stack. Check the  tag specified for
>> this
>> action.
>>
>> RequestURI=/struts2-showcase/filedownload/download.action
>> Caused by:
>>
>> java.lang.IllegalArgumentException: Can not find a
>> java.io.InputStreamwith
>> the name [inputStream] in the invocation stack. Check the
>>
>> tag specified for this action. at
>> org.apache.struts2.dispatcher.StreamResult.doExecute(StreamResult.java
>> :189)
>> at
>> org.apache.struts2.dispatcher.StrutsResultSupport.execute(
>> StrutsResultSupport.java:178)
>> at
>> com.opensymphony.xwork2.DefaultActionInvocation.executeResult(
>> DefaultActionInvocation.java:348)
>> at
>> com.opensymphony.xwork2.DefaultActionInvocation.invoke(
>> DefaultActionInvocation.java:253)
>> at
>> com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept
>> (DefaultWorkflowInterceptor.java:219)
>> at
>> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(
>> MethodFilterInterceptor.java:86)
>> at
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(
>> DefaultActionInvocation.java:224)
>> at
>> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(
>> DefaultActionInvocation.java:223)
>> at
>> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(
>> UtilTimerStack.java:455)
>> at
>>
>> Is there a way to correct it or should I wait for the next release?
>>
>> Thanks in advance.
>> --
>> View this message in context:
>> http://www.nabble.com/-S2--Error-in-%22File-Download%22-in-struts-showcase-application-tf3703170.html#a10355673
>> Sent from the Struts - User mailing list archive at Nabble.com.
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
> 
> 
> -- 
> "Hey you! Would you help me to carry the stone?" Pink Floyd
> 
> 

-- 
View this message in context:
http://www.nabble.com/-S2--Error-in-%22File-Download%22-in-struts-showcase-application-tf3703170.html#a10357747
Sent from the Struts - User mailing list archive at Nabble.com.


-
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]



Re: Is it possible to unit test validatiors in xml?

2007-05-07 Thread Martin Gilday
http://wiki.opensymphony.com/display/WW/Testing+Validation describes how
to do it for WebWork.  The process should be very similar for Struts 2.

Thanks,
Martin.


- Original message -
From: [EMAIL PROTECTED]
To: user@struts.apache.org
Date: Mon, 7 May 2007 12:52:40 +0200
Subject: Is it possible to unit test validatiors in xml?

Hi,

Is it possible to unit test validations created in xml? I.e. like this:


   

myPurchaseCode
10
10
true
Your purchase code needs to be 10 characters
long  
  
   

10
true
Your purchase code needs to be 10 characters
long



Regards
Gunnar



-
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]