hi,
i am using struts v2.1.8.1 + spring 3.0 + junit 4.0. it should be
noted that i am using convention plugin for spring.
my action class extends ActionSupport and implements
ServletRequestAware and ServletResponseAware. the method i am testing
inside my action class never returns a string
(response);
String result = action.dummyAction();
Assert.assertNull(result); //should always be null
String json = response.getContentAsString();
Assert.assertNotNull(json); //shouldn't be null
On Fri, May 13, 2011 at 2:58 PM, Jake Vang vangj...@googlemail.com wrote:
hi,
i am using struts v2.1.8.1
Pawel, you know of anything like this but for the convention plugin? I
don't use XML anymore. In fact, I've gotten away a lot with almost a
purely annotation based approach. In fact, my struts.xml is 4-5 lines
only.
2011/4/26 Paweł Wielgus poulw...@gmail.com:
Hi Jake,
maybe this aproach would
...@gmail.com wrote:
My first guess would be to return null so you're not rendering a jsp after
the output stream is closed.
Dave
On Apr 22, 2011 11:49 PM, Jake Vang vangj...@googlemail.com wrote:
what i did to get rid of this message was to add the following line
before i do anything
i am using struts 2 with the convention plugin. i have a bunch of
actions that streams back plain text, json or xml. however, when a
user goes to a certain URL, i keep seeing an IllegalStateException :
Cannot create a session after the response has been committed.
why is this happening?
my
. if anyone has a better suggestion,
please let me know.
On Fri, Apr 22, 2011 at 11:22 PM, Jake Vang vangj...@googlemail.com wrote:
i am using struts 2 with the convention plugin. i have a bunch of
actions that streams back plain text, json or xml. however, when a
user goes to a certain URL, i keep
you so much.
On Sat, Apr 23, 2011 at 12:11 AM, Dave Newton davelnew...@gmail.com wrote:
My first guess would be to return null so you're not rendering a jsp after
the output stream is closed.
Dave
On Apr 22, 2011 11:49 PM, Jake Vang vangj...@googlemail.com wrote:
what i did to get rid
i have a custom field validator that extends FieldValidatorSupport.
inside this class, i need to access some beans as defined in
applicationContext.xml by Spring. how do i access the spring managed
beans? any help is appreciated.
org.springframework.web.context.ContextLoaderListener defined in
web.xml.
Thanks,
On Mon, Nov 1, 2010 at 4:17 AM, Eduard Neuwirt
eduard.neuw...@googlemail.com wrote:
Hello Jake,
It is simple.
Use struts/spring plug in.
Declare your bean within your validator and let spring inject your
validator.
That's all
Regards
Eduard
P.S.: Do
You can use the fieldexpression validator. See
http://struts.apache.org/2.1.8.1/docs/fieldexpression-validator.html for
details.
On Tue, Jul 13, 2010 at 05:39:52AM -0700, kisja wrote:
I have two textfield and I would like to validate that at least one of both
have data.
How I can do?
bean.
oh well, you win some, you lose some. if anyone has a better idea,
please let me know.
thanks.
On Mon, Jul 12, 2010 at 11:26 AM, Jake Vang vangj...@googlemail.com wrote:
hi,
i am trying to validate an integer field (int primitive type) on a
POJO (i.e. MyPojo.integer). i have the validation
hi,
i am trying to validate an integer field (int primitive type) on a
POJO (i.e. MyPojo.integer). i have the validation defined in
ActionClass-alias-validation.xml as follows.
...
field name=myPojo.integer
field-validator type=required
messageInteger is required!/message
/field-validator
beans inside the Prepare method in your
action. That when 'input' is needed, your backing beans will be
loaded.
On 7/10/10, Jake Vang vangj...@googlemail.com wrote:
i have a form that i display. but to display that form, i have to
fetch some data from the database and then place that data
i have a form that i display. but to display that form, i have to
fetch some data from the database and then place that data on the
valuestack (via backing beans). when the form is displayed, it expects
that those backing beans should be populated. the form then posts to a
save action.
i have a
i have an Action class in the package
com.company.web.struts.actions.admin.LoginAction. inside LoginAction,
i use Annotation to specify the Action (i.e. @Action(value=/login)
on a method. according to the documentation at,
http://struts.apache.org/2.1.8.1/docs/convention-plugin.html, this
should
29, 2010 at 7:28 AM, Jake Vang vangj...@googlemail.com wrote:
i have an Action class in the package
com.company.web.struts.actions.admin.LoginAction. inside LoginAction,
i use Annotation to specify the Action (i.e. @Action(value=/login)
on a method. according to the documentation at,
http
i have a User class with two fields, password and confirmPassword. on
a web form, upon post, i am trying to see if they match using the
fieldexpression validator. however, no matter what i try, i keep
getting the message that they don't match. in the Tomcat console, i
can see this message: Got
never mind, i removed # from the OGNL expression and i get the correct
behavior now.
On Tue, Jun 29, 2010 at 12:23 AM, Jake Vang vangj...@googlemail.com wrote:
i have a User class with two fields, password and confirmPassword. on
a web form, upon post, i am trying to see if they match using
ken,
thanks for responding. i got things to work, but i haven't figured out
really why it's working (on a conceptual, philosophical level). here's
what i did to the code above.
1. for the Company class, i removed the @ForeignKey annotation
2. for the Employee class, i removed the companyId
-0400, Jake Vang vangj...@googlemail.com
wrote:
hi, i've been reading and studying
http://struts.apache.org/2.0.14/docs/struts-2-spring-2-jpa-ajax.html.
i want to know what is actually going on in applicationContext.xml.
for example, what do these two lines do? please explain or refer me
: Mon, 21 Jun 2010 10:04:57 -0400
From: stur...@mit.edu
On Mon, 21 Jun 2010 00:56:19 -0400, Jake Vang vangj...@googlemail.com
wrote:
hi, i've been reading and studying
http://struts.apache.org/2.0.14/docs/struts-2-spring-2-jpa-ajax.html.
i want to know what is actually going
MyServiceImplTest extends AbstractJUnit4SpringContextTests
{
�...@autowired(required = true)
private MyService myService = null;
testConfigXML.xml will contain your *test* config..
Then do the do!
-Original Message-
From: Jake Vang [mailto:vangj...@googlemail.com]
Sent: 21 June 2010 05:54
AbstractTransactionalJUnit4SpringContextTests for your unit test and the like
Cheers
James
-Original Message-
From: Jake Vang [mailto:vangj...@googlemail.com]
Sent: 21 June 2010 17:27
To: Struts Users Mailing List
Subject: Re: unit test the service layer (aka data access layer)
james
i am following the example at
http://struts.apache.org/2.1.8.1/docs/struts-2-spring-2-jpa-ajax.html.
in this example, a very simple persistence is given (of which i am
thankful). but, what i am trying to do is slightly more complicated
with persistence. i need to persist a one-to-many
hi, i've been following this code here at
http://struts.apache.org/2.0.14/docs/struts-2-spring-2-jpa-ajax.html.
what i want to know is how to unit test the service layer (or data
access object layer). in the case of the link, it would be the
PersonServiceImpl class.
hi, i've been reading and studying
http://struts.apache.org/2.0.14/docs/struts-2-spring-2-jpa-ajax.html.
i want to know what is actually going on in applicationContext.xml.
for example, what do these two lines do? please explain or refer me to
better documentation.
bean id=transactionManager
i am using struts 2.1.8.1 and the convention plugin. i am also using
spring for dependency injections (DI). my question is if it is
possible to to use struts2 + convention plugin with spring for DI on
my Action classes? i have searched the internet but only seen
examples using struts 1 + spring
service
etc etc
But I have started doing:
public class MyAction extends ActionSupport {
@Autowired
private MyInjectedService service
I am not sure if that alters the way Struts2/Spring does it. But it does
make it a bit clearer to read.
-Original Message-
From: Jake Vang
does it. But it does
make it a bit clearer to read.
-Original Message-
From: Jake Vang [mailto:vangj...@googlemail.com]
Sent: 13 May 2010 10:23
To: user@struts.apache.org
Subject: spring, struts2, convention plugin, how to wire an action
class
i am using struts 2.1.8.1
-
From: Jake Vang [mailto:vangj...@googlemail.com]
Sent: 13 May 2010 11:09
To: Struts Users Mailing List
Subject: Re: spring, struts2, convention plugin, how to wire an action class
well, there's something strange about struts2 (with convention plugin)
+ spring. if your action has a field
).
On Thu, May 13, 2010 at 6:20 AM, James Cook james.c...@wecomm.com wrote:
Yeah sorry, short on time here, didn't see your question at the bottom. Add
the spring jar from the spring project.
-Original Message-
From: Jake Vang [mailto:vangj...@googlemail.com]
Sent: 13 May 2010 11:16
yes. precisely.
On Thu, May 13, 2010 at 6:41 AM, James Cook james.c...@wecomm.com wrote:
Oh, did you want your action as a spring managed bean? Ah I think i massively
miss read you. You want to inject predefined values etc?
-Original Message-
From: Jake Vang [mailto:vangj
If you want Spring to create your action class (as opposed to Struts
creating them) then you need to define your action in the
applicationContext.xml file.
how do you do that? here's a couple of ways i have tried that do NOT work.
1. (normal, naive way that works for defining services)
bean
the @Resource anno as well. Can't think off the top
of my head.
-Original Message-
From: Jake Vang [mailto:vangj...@googlemail.com]
Sent: 13 May 2010 11:44
To: Struts Users Mailing List
Subject: Re: spring, struts2, convention plugin, how to wire an action class
yes. precisely
be most pleased. thanks.
On Thu, May 13, 2010 at 8:24 AM, Denis Cabasson
denis.cabas...@gmail.com wrote:
Jake, the short answer to your problem is : use the struts-spring plugin (
http://struts.apache.org/2.1.8.1/docs/spring-plugin.html ). Include the jar
for that plugin in your classpath, and Struts
into the Action class. The third and fourth lines
confirm that the String and boolean values are injected into the
service class.
thanks.
On Thu, May 13, 2010 at 9:32 AM, RogerV roger.var...@googlemail.com wrote:
Jake Vang wrote:
If you want Spring to create your action class (as opposed to Struts
Hi,
When will there be a GA release of 2.1.9 or above?
Cheers,
Jake
-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org
to do programming (Java or JavaScript) right on the
page.
On Thu, Feb 4, 2010 at 6:10 PM, Stephen Ince stephenpi...@gmail.com wrote:
Jake,
The sx: tags are based on the .4 dojo tags. I would just use the
dojo tags themselves. The dojo plugin is also being depricated. The
new dojo tags are at 1.4
Ince stephenpi...@gmail.com wrote:
Jake,
I actually ran into a lot problems accessing dojo from other
servers. They all went away when I installed it locally. I think you
get some sandbox security issues with some of the packages.
cheers,
Steve
On Fri, Feb 5, 2010 at 8:44 AM, Jake Vang
i'm using the sx:tabbedpanel/ in the struts2-dojo-plugin. i have a
few questions on controlling the display/rendering of this component.
1. can i make the sx:tabbedpanel/ expand 100% in height? i've tried
several things: a) place the sx:tabbedpanel/ inside a table and
set the height of the table
On Sun, Jan 31, 2010 at 9:12 AM, Jake Vang vangj...@googlemail.com wrote:
i am using servlets (HttpServlet) and struts 2. my mapping in web.xml
for the struts filter maps to the url pattern, /*. my servlet maps to
something like this, /test. however, when i try to access my servlet,
http
i was wondering if it was possible to write a custom tag that is able
to access objects in the ActionContext using OGNL? i'm not sure if
this is a correct question.
my problem is that i have a form. the form is posted to an action. the
action has getters/setters for the form fields. i then
several times and do not see the connection. I'm not sure I understand
exactly what you
did solved the problem, but it is clerarer than the documention
--- On Sat, 1/30/10, Jake Vang vangj...@googlemail.com wrote:
From: Jake Vang vangj...@googlemail.com
Subject: Re: interceptor
i found something helpful here. it works.
http://struts.apache.org/2.1.8.1/docs/access-to-valuestack-from-jsps.html
On Mon, Feb 1, 2010 at 7:34 AM, Jake Vang vangj...@googlemail.com wrote:
i was wondering if it was possible to write a custom tag that is able
to access objects
bill, thanks for including the code (especially the import statements
so i will know where these objects/classes are coming from).
On Mon, Feb 1, 2010 at 11:09 AM, Bill Bohnenberger bill98...@gmail.com wrote:
Hi Jake,
I have a custom table tag that needs Value Stack access, too.
Here's how I
i am using servlets (HttpServlet) and struts 2. my mapping in web.xml
for the struts filter maps to the url pattern, /*. my servlet maps to
something like this, /test. however, when i try to access my servlet,
http://localhost:8080/myapp/test, i get the following message:
There is no Action
i have written an interceptor implementation, however, it seems i cannot get
it to work. i have followed the instructions at
http://struts.apache.org/2.x/docs/interceptors.html. i have also followed
the instructions at
what does that have to do with my problem? please enlighten.
On Sat, Jan 30, 2010 at 4:37 PM, Dave Newton newton.d...@yahoo.com wrote:
http://struts.apache.org/2.x/docs/convention-plugin.html#ConventionPlugin-XWorkpackages
- Original Message
From: Jake Vang vangj
, Dave Newton newton.d...@yahoo.com wrote:
http://struts.apache.org/2.x/docs/convention-plugin.html#ConventionPlugin-XWorkpackages
- Original Message
From: Jake Vang vangj...@googlemail.com
To: user@struts.apache.org
Sent: Sat, January 30, 2010 4:10:31 PM
Subject: interceptor
this is such a pain (but then again, i'm not a developer on
the struts2 project, so there may be a lot of complexities to get this
working elegantly that i'm unaware of).
On Sat, Jan 30, 2010 at 4:10 PM, Jake Vang vangj...@googlemail.com wrote:
i have written an interceptor implementation, however, it seems i
, you can remove the @ParentPackage and @InterceptorRef
from the classes and methods.
wow, it was that easy.
On Sat, Jan 30, 2010 at 6:14 PM, Jake Vang vangj...@googlemail.com wrote:
okay, after fiddling around for 2 hours, with the weak documentation out
there, i think i have it figured out
Thanks for the reply, it does work as it should, but I made a silly mistake :(
Nothing like wasting a day!
Jake
On Sat, Oct 17, 2009 at 04:23:05PM -0700, Tommy Pham wrote:
From: j...@researchtogether.com j...@researchtogether.com
To: user
- is the .! part of the problem
here?
and also param name=actionNamedisplayCategory/param does the same as the
more complete action detailed above.
Can anyone provide any insight as to why it isn't working as I expect?
Cheers,
Jake aka _LisWork
Have a look at the implementation of the plugin's interceptor:
http://struts2-ssl-plugin.googlecode.com/svn/trunk/plugin/src/main/java/
com/googlecode/sslplugin/interceptors/SSLInterceptor.java
Just change it so that it looks at something else instead of the
annotation.
-Jake
-Original
What about using s:checkboxlist with a single-item list?
-Jake
-Original Message-
From: bhaarat Sharma [mailto:[EMAIL PROTECTED]
Sent: Wednesday, December 12, 2007 4:36 PM
To: Struts Users Mailing List
Subject: Re: s:checkbox preselect
tried it and doesnt work :(
this is a real
to the action to only the path(s) I want?
Thanks!
-Jake
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
setting of your package?
- Gary
Jake Robb wrote:
I have an action called MainMenu. It's defined as follows:
action name=MainMenu class=mainMenuAction
result name=success type=tilesmainMenu/result
/action
(I'm using the Spring plugin - mainMenuAction
in 2.0.11.
So, how do I accomplish this? I guess I could keep it the old way, but
I'd really rather be consistent.
-Jake
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
I think you're looking for bean:write.
-Jake
-Original Message-
From: Pavel Sapozhnikov [mailto:[EMAIL PROTECTED]
Sent: Friday, October 12, 2007 1:25 PM
To: Struts Users Mailing List
Subject: s:property from S2 in S1
Hi I have a question. So in S2 you have s:property which just takes
is complete in JIRA, what else has
to happen before that version becomes GA?
Thanks,
Jake Robb
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
On 10/10/07, Jake Robb [EMAIL PROTECTED] wrote:
Okay, this might be a question for the dev list, but bear with me for
a
minute.
My application is currently using Struts 2.0.8. I read about some
security and bug fixes in 2.0.9 and 2.0.10. According to the Struts
JIRA server, 2.0.10 has been
didn't test it, I'm just guessing)
-W
On 10/10/07, Jake Robb [EMAIL PROTECTED] wrote:
Pardon me for being totally new to OGNL, but what would be the
equivalent of ${not empty rules}?
-Original Message-
From: Wes Wannemacher [mailto:[EMAIL PROTECTED]
Sent: Wednesday, October 10, 2007
that be? It already works to *populate* a form; I
just can't submit back to the action and have it fill in my object.
Am I the only one that thinks that the current S2 way is a huge pain?
-Jake Robb
-
To unsubscribe, e-mail
in that
message.
I'm thinking this is a typical greenie mistake, and I'm hoping someone here can
set me straight.
Thanks,
Jake Robb
64 matches
Mail list logo