As per your suggestion, changing struts2 version to 2.1.8 fix the problem.
Thanks!
On Sun, Nov 12, 2017 at 12:29 PM, Yasser Zamani
wrote:
>
>
> On 11/12/2017 2:28 AM, albert kao wrote:
> > java.lang.NullPointerException
> > com.opensymphony.xwork2.util.FileManager$FileRevision.
> needsReloading(
On 11/12/2017 2:28 AM, albert kao wrote:
> java.lang.NullPointerException
> com.opensymphony.xwork2.util.FileManager$FileRevision.needsReloading(FileManager.java:209)
I just googled "needsReloading(FileManager.java:209)" and found [1] :)
it seems has been a bug and has fixed in 2.1.8.
[1] http
Please create a GitHub repo with your code and I'll take a look. Note that
the examples from the book were tested only on Tomcat, and a pretty long
time ago. I'll need any server details you're using.
Also note that S2 is fairly different now than when the book was written.
On Sun, Nov 12, 2017 a
struts2 version: 2.1.6
On Sat, Nov 11, 2017 at 9:47 PM, Dave Newton wrote:
> What version of Struts 2 are you attempting to use?
>
> On Sat, Nov 11, 2017 at 5:58 PM albert kao wrote:
>
> > I downloaded the source code of the book "Apache Struts 2 Web Application
> > Development" by Dave Newton
What version of Struts 2 are you attempting to use?
On Sat, Nov 11, 2017 at 5:58 PM albert kao wrote:
> I downloaded the source code of the book "Apache Struts 2 Web Application
> Development" by Dave Newton from the
> https://www.packtpub.com/books/content/support.
>
> Chapter 2 had compile err
StrutsSpringTestCase extends StrutsTestCase which extends another class that
depends on JUnit 3 not JUnit 4.
So you cannot use JUnit 4 annotations and the SpringJUnit4ClassRunner.
You may find this blog article helpful:
http://www.brucephillips.name/blog/index.cfm/2009/12/2/Using-JUnit-To-Test
1. Yes. The LoginAction is annotated with @Namespace("/login"), and
the register() action is annotated with @Action(value="register").
2. I'm not sure what you're saying. Since StrutsTestCase initializes
this to a new object, why do I need to check for null?
On Sat, Mar 12, 2011 at 7:43 PM, Marti
1)does /login/register exist in your struts webapp?
2)in StrutsTestCase
protected void initServletMockObjects() {
request = new MockHttpServletRequest();
//check request for null before referencing the request object later on
Martin Gainty
___
On 8/26/10 7:04 AM, Rohit wrote:
Yes I have done that, it's not that every time I am getting the null pointer
exception. It's happening randomly.
First I'd track down the code in question and see just what objects are
getting dereferenced on that line. If you have any problem that is not
det
Yes I have done that, it's not that every time I am getting the null pointer
exception. It's happening randomly.
Regards,
Rohit
-Original Message-
From: Jan T. Kim [mailto:j@uea.ac.uk]
Sent: 26 August 2010 16:31
To: user@struts.apache.org
Subject: Re: NullPointerExcep
On Thu, Aug 26, 2010 at 10:24:41AM +0100, Rohit wrote:
> Hi,
>
> I am facing a strange error in Struts2, I am getting a null pointer
> exception when trying to set attribute into request scope,
>
> Struts Problem Report
>
> Struts has detected an unhandled exception: Messages:
> File: org/apache
Hi Musachy,
Thanks for the reply. I debugged and just found that the select tag could
not render "children[i]" as a list element.As I mentioned before if I change
children[i] to children(i), just to try whats happening, the page loads
fine.
Since we work on Agile and had a deadline of an hr or so,
can you debug it and see what is actually null? It seems like a bug.
That being said, I am building 2.1.8 as we speak, so if you are
planning to upgrade, it might be worth waiting a bit.
musachy
On Tue, Sep 22, 2009 at 3:44 PM, Anandkris wrote:
> OgnlValueStack
--
"Hey you! Would you help me
Apologies, I had my a copy of FilterDispatcher in my source code which
was erroneous!
Sorry for the inconvenience caused!
Regards.
W.SayJon
Email Disclaimer:
The information contained in or attached to this email is confidential and
solely for the use of the individual or entity to whom it is add
Thanks for replying, Pawel.
However, I get the same error message when viewing the config browser. Any
ideas?
Regards.
W.SayJon
Email Disclaimer:
The information contained in or attached to this email is confidential and
solely for the use of the individual or entity to whom it is addressed.
If y
Hi Say,
have You looked at
http://localhost:8080/CONTEXT/config-browser/index.action where
CONTEXT is your app context? That might give You some clues, also to
see this page You need to have config-browser plugin.
Best greetings,
Paweł Wielgus.
2009/1/25 Say Jon :
> Hi everyone,
> I have recentl
Hi everyone,
I have recently upgraded to 2.1.6 from 2.0.11. Startup is OK but when I
tried accessing my action class, I get the following error:
2009-01-25 18:45:25,158 ERROR FilterDispatcher:391 - error getting
ActionMapping
java.lang.NullPointerException
at
org.apache.struts2.dispatcher.FilterDi
GREAT! That fixed it! I'll update the Jira. Thanks for your help!!!
Mark
On 10/09/2008, at 10:50 AM, Dave Newton wrote:
--- On Tue, 9/9/08, Mark wrote:
Ok, that makes sense. How would I set that up? Right now,
I have an index.jsp with the following: . This is so that someone accessing
th
--- On Tue, 9/9/08, Mark wrote:
> Ok, that makes sense. How would I set that up? Right now,
> I have an index.jsp with the following: page="login.jsp"/>. This is so that someone accessing
> the site via http://localhost/ will be presented with the
> login page.
I generally just use a redirec
Ok, that makes sense. How would I set that up? Right now, I have an
index.jsp with the following: . This
is so that someone accessing the site via http://localhost/ will be
presented with the login page.
Mark
On 10/09/2008, at 10:20 AM, Dave Newton wrote:
Ah; there we go. The attached
Ah; there we go. The attached validation file in JIRA didn't have the "key"
attribute; threw me off.
You're accessing the login page via the JSP, right? That won't work. You should
access it through an action so there's an action on the stack so the getText()
can be called on something that exi
--- On Tue, 9/9/08, Mark wrote:
> No, I'm not using an tag. Should I be?
Not if you don't need it.
Does it work if you have the validation XML file's DOCTYPE w/o the trailing
space after ".dtd "?
How are you accessing the login page the first time--through an action?
Dave
-
so wondering if there's anything else on the value stack. Are
you using an tag?
Dave
--- On Tue, 9/9/08, Mark <[EMAIL PROTECTED]> wrote:
From: Mark <[EMAIL PROTECTED]>
Subject: Re: NullPointerException with Validation Messages
To: "Struts Users Mailing List"
Date: Tue
You're extending ActionSupport, right?
I'm also wondering if there's anything else on the value stack. Are you using
an tag?
Dave
--- On Tue, 9/9/08, Mark <[EMAIL PROTECTED]> wrote:
> From: Mark <[EMAIL PROTECTED]>
> Subject: Re: NullPointerException with
I changed to , refreshed,
and I still get the NPE :-(
If this help, I've also run into another problem which is related.
If I implement the Validatable interface in my action, and then add a
Field error (ie. addFieldError("userName", "requiredString");) in the
validate method, the messa
I can zip up my complete maven directory and post it in the Jira. Is
that an appropriate place for it? Or should I email it to you directly?
Mark
On 10/09/2008, at 8:45 AM, Dave Newton wrote:
--- On Tue, 9/9/08, Mark wrote:
Thank you for the suggestion. Yes, I have and it still
produces
Here's something to try, although I still can't get the NPE, which is
irritating and scary:
Your 's action is "login", which means the DOM's id will
also be "login". Because the markup is arguably somewhat brittle, your element is colliding with the .
Try changing the id to something like "l
--- On Tue, 9/9/08, Mark wrote:
> Thank you for the suggestion. Yes, I have and it still
> produces the NullPointerException.
You may want to try putting the complete webapp up somewhere, or post a
minimal, but complete, source example on something like pastebin/etc. I tried
several different t
--- On Tue, 9/9/08, Mark wrote:
> Thank you for the suggestion. Yes, I have and it still
> produces the NullPointerException.
You may want to try putting the complete webapp up somewhere, or post a
minimal, but complete, source example on something like pastebin/etc. I tried
several different t
Thank you for the suggestion. Yes, I have and it still produces the
NullPointerException.
Mark
On 09/09/2008, at 10:45 PM, Pascal Lalonde wrote:
Have you tried this ?
- Pascal
Mark wrote:
Hi all:
I'm
Have you tried this ?
- Pascal
Mark wrote:
Hi all:
I'm using Struts 2 validation and I'm getting a NullPointerException
when the page is being displayed (before it is even being submitted or
validated).
Sorry, what does AFAICT mean? :-)
I'm running Tomcat 6.0.16. No, it doesn't work with default stack.
Any other ideas?
Mark
On 09/09/2008, at 12:13 PM, Dave Newton wrote:
--- On Mon, 9/8/08, Mark wrote:
I'm using Struts 2 validation and I'm getting a NullPointerException
when the page is b
--- On Mon, 9/8/08, Mark wrote:
> I'm using Struts 2 validation and I'm getting a NullPointerException
> when the page is being displayed (before it is even being submitted
> or validated). I did some searches and found this Jira:
> https:// issues.apache.org/struts/browse/WW-2150.
AFAICT th
Hi Dave.
I found the problem is because this logon page has been configured
externally for jboss server. The jboss server dosn't know the S2.
Thanks,
Yan
panpan wrote:
>
> Hi Dave,
>
> Thanks for your reply and time.
> In the web.xml, I have both S1 and S2 configuration inside. So S1 and S2
Hi Dave,
Thanks for your reply and time.
In the web.xml, I have both S1 and S2 configuration inside. So S1 and S2 tag
should function together well. I have other page which has mixed s1 tag nad
s2 tag and works very well.
The reason is like what WW response mentioned: FilterDispatcher is never
b
--- panpan <[EMAIL PROTECTED]> wrote:
> They're served throught S1 and S2 since I'm in the
> middle for migration from S1 to S2.
It is not clear to me that an S2 tag would function
under an S1 mapping because there won't be a value
stack, which is what the stack trace implies.
The WW response cla
They're served throught S1 and S2 since I'm in the middle of migrating from
S1 to S2.
I got a replay from WebWork forum:
Hi Newuser,
>From the stack trace it looks like FilterDispatcher is never being applied
to the request resulting ValueStack being null, hence NPE. How does the
mapping of w
--- panpan <[EMAIL PROTECTED]> wrote:
> Don't understand this one.
*Please* just say whether or not the page you're
serving is being served through S1 or S2.
> If you see the below struts JIRA link:
>
> http://issues.apache.org/struts/browse/WW-1388
>
> It has the almost same exception as mine.
Hi Dave,
I'm doing migration from S1 to S2. S1 and S2 should work together
peacefully. I add those required configuration in web.xml and jars in the
classpath. I've done other pages sucessfully with mixed S1 tag and S2 tag.
Don't understand this one.
I found the problem is that
org.apache.struts
--- panpan <[EMAIL PROTECTED]> wrote:
> This page is originally served through struts1.
> During the migration to struts 2, I need to add a
new
> feature to this page using struts 2 tag to
> invoke the struts 2 action.
Well... if the page isn't being served through the S2
filter I'm not sure which
Hi Dave,
Thanks for your reply and sorry for the confusion!
This page is originally served through struts1. During the migration to
struts 2, I need to add a new feature to this page using struts 2 tag to
invoke the struts 2 action.
Please help me!
pp
Dave Newton-4 wrote:
>
> I'm confused.
I'm confused.
--- panpan <[EMAIL PROTECTED]> wrote:
> This logon.jsp page doesn't use sitemesh and I only
> add one struts2 tag line . I don't
> know what happend.
Is the page being served through S2?
d.
__
Musachi,
I like that src link you included. I looked at it then found the
Dispatcher.java class to look at the getInstance() method. It's
getting a threadlocal of struts2 instance. So I realized sitemesh
must be calling that header.jsp page before struts2 get's a chance to
put it's instance in
Musachy --
Not exactly sure what an "OP" is, but I am trying to save my brother from
banging his head on the keyboard. I have found S2's Ajax support to be
harder to actually write than the docs would otherwise suggest. Understand
this comment does not apply generally to S2, but rather a slice
--- [EMAIL PROTECTED] wrote:
> I honestly think you are barking up the wrong tree
> using S2 for Ajaxy UI.
Just to provide a counter-example, I am using many of
the S2 tags in multiple applications to provide a fair
amount of Ajaxification very successfully.
There are definitely many use-cases t
How exactly does your comment help the OP?
musachy
On 3/19/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
Musachy --
I have given up on the AJAX theme and moved exclusively to Prototype.jsfor
asynch behaviors. There is no mystery prototype.js and it is very clear
to
code/read. I had been
Musachy --
I have given up on the AJAX theme and moved exclusively to Prototype.js for
asynch behaviors. There is no mystery prototype.js and it is very clear to
code/read. I had been using XHR directly and thought S2's tags would make
my life simpler. However, even coding with XmlHttpRequest
Looking at that line here:
http://svn.apache.org/viewvc/struts/struts2/tags/STRUTS_2_0_6/core/src/main/java/org/apache/struts2/views/jsp/ComponentTagSupport.java?annotate=509057
Container container = Dispatcher.getInstance().getContainer();
it seems like Dispatcher.getInstance() is returning
Actually I am using same version of tiles: 2.0 as you said i.e
for tiles.xml:
http://struts.apache.org/dtds/tiles-config_2_0.dtd";>
My jsps are simple and don't use tiles tags. I am using tiles just as a
forward result type.
You can look at my configuration given below
1. tiles.xml--
Hi,
Yesterday I got the same problem,
and here is the solution:
Use new version of tiles: 2.0
for tiles.xml:
http://struts.apache.org/dtds/tiles-config_2_0.dtd";>
for jsps:
<%@ taglib uri="http://tiles.apache.org/tags-tiles"; prefix="tiles" %>
tags are a little bit changed but it's easy to upg
very silly mistake.
used java.lang.ArrayList instead of java.util.ArrayList.
Thanks for your help.
From: "fea jabi" <[EMAIL PROTECTED]>
Reply-To: "Struts Users Mailing List"
To: user@struts.apache.org
Subject: Re: NullPointerException when using DynaActionForm
Da
ue is?
Thanks.
From: "fea jabi" <[EMAIL PROTECTED]>
Reply-To: "Struts Users Mailing List"
To: user@struts.apache.org
Subject: Re: NullPointerException when using DynaActionForm
Date: Tue, 09 May 2006 14:50:42 -0400
sorry about that. here it is.
;Michael Jouravlev" <[EMAIL PROTECTED]>
Reply-To: "Struts Users Mailing List"
To: "Struts Users Mailing List"
Subject: Re: NullPointerException when using DynaActionForm
Date: Tue, 9 May 2006 11:36:56 -0700
On 5/9/06, fea jabi <[EMAIL P
On 5/9/06, fea jabi <[EMAIL PROTECTED]> wrote:
public class NewEligibilityForm extends DynaActionForm implements
Serializable {
public NewEligibilityForm() {
}
/**
* Resets the f
Hi Ganesh,
thanks for your reply. But my properties file is directly under the
WEB-INF/classes folder, not under any package.
regs,
Ramkumar
On 4/4/06, RathinaGanesh MeenakshiSundaram <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> You should specify the full package location of the message-resour
Hi,
You should specify the full package location of the message-resource file..
The parameter should be like this..
Hope this helps..!
Thanks,
Ganesh.
On 4/4/06, Ramkumar Krishnan <[EMAIL PROTECTED]> wrote:
>
> Hi All,
> I am getting Null PointerException when i tried to view my login page.
The two lines I think you want to validate first are:
String sqlQuery = ((ExecuteQueryForm) form).getSQLQuery();
and
session.setAttribute("query",form);
Since they are not within your catch, they could cause problems. If your form
is null, as someone else said, you'd be in trouble.
Also, i
uts Users Mailing List
> Subject: Re: NullPointerException, how to determine cause?
>
>
> I am sure this part works, because if comment out try block
> everything
> works fine. But If the cause of exception is the code in try
> block, how
> come catch does not work?
I am sure this part works, because if comment out try block everything
works fine. But If the cause of exception is the code in try block, how
come catch does not work?
Pavel Kolesnikov wrote:
I guess the only plase where NPE may occure is the line:
String sqlQuery = ((ExecuteQueryForm)
I guess the only plase where NPE may occure is the line:
String sqlQuery = ((ExecuteQueryForm) form).getSQLQuery();
Are you sure there's a form definition available for this action?
It means, is there a "name" attribute defined in an appropriate
element in your struts-config.xml?
Pavel
t a blank page?
Uma
-Original Message-
From: Sunny [mailto:[EMAIL PROTECTED]
Sent: Friday, December 24, 2004 9:17 AM
To: Struts Users Mailing List
Subject: Re: NullPointerException
Hey Uma,
Kindly attach your logs when you face any exceptions. That'll really
help in debugging.
regards,
Sunny.
Hey Uma,
Kindly attach your logs when you face any exceptions. That'll really
help in debugging.
regards,
Sunny.
uma.k wrote:
Hi,
The solution is perfect. I forgot initialization. Now I dont get any error
but nothing is displayed when the error is actually to be thrown. I get
blank page and it do
IF the exception is actually being thrown here, then I'm guessing that you
haven't instantiated a instance of ActionErrors e.g. ActionErrors errors =
new ActionErrors();
Dennis
"uma.k" <[EMAIL PROTECTED]>
12/23/2004 07:40 AM
Please respond to
"Struts Users Mailing List"
To
"'Struts Users
Friday, December 17, 2004 11:52 AM
Subject: [SOLVED] RE: NullPointerException
> Thanks all for your replies. I created another context and copied all of
my
> files from the existing context to the new context and its working fine.
But
> I still do not understand why it didn't work in
EMAIL PROTECTED]
Sent: Thursday, December 16, 2004 9:43 PM
To: Struts Users Mailing List
Subject: Re: NullPointerException
Struts does not support multiple mappings. See the first warning at
the bottom of
http://struts.apache.org/userGuide/configuration.html#dd_config_mapping
Hubert
On Thu, 16 Dec 20
rks in another context.
>
> -Original Message-
> From: news [mailto:[EMAIL PROTECTED] Behalf Of Bill Siggelkow
> Sent: Thursday, December 16, 2004 9:12 PM
> To: [EMAIL PROTECTED]
> Subject: Re: NullPointerException
>
> Hmm -- I do see that you have two servlet mappin
Hi,
I have not fully understood the context in which you
get this error. However, I noticed that in your action
mapping in struts-config.xml,
you do not specify the complete path for your input
JSP - input="/Template.jsp". I guess it should be:
path="/articles/T
It doesn't make any difference as the same works in another context.
-Original Message-
From: news [mailto:[EMAIL PROTECTED] Behalf Of Bill Siggelkow
Sent: Thursday, December 16, 2004 9:12 PM
To: [EMAIL PROTECTED]
Subject: Re: NullPointerException
Hmm -- I do see that you hav
Of Bill Siggelkow
Sent: Thursday, December 16, 2004 8:34 PM
To: [EMAIL PROTECTED]
Subject: Re: NullPointerException
Wierd -- it looks to me from the original message that you are getting
the error on line 1219 of TagUtils which is:
resources =
(MessageR
F/struts-nested.tld
/WEB-INF/struts-tiles
/WEB-INF/struts-tiles.tld
jstl/c
/WEB-INF/c.tld
-Original Message-
From: news [mailto:[EMAIL PROTECTED] Behalf Of Bill Siggelkow
Sent: Thursday, December 16, 2004 8:34 PM
To: [EMAIL PROTECTED]
Sub
Wierd -- it looks to me from the original message that you are getting
the error on line 1219 of TagUtils which is:
resources =
(MessageResources) pageContext.getAttribute(
bundle + moduleConfig.getPrefix(),
P
Bill,
yes that file is in web-inf/classes folder only.
Uma
-Original Message-
From: news [mailto:[EMAIL PROTECTED] Behalf Of Bill Siggelkow
Sent: Thursday, December 16, 2004 7:34 PM
To: [EMAIL PROTECTED]
Subject: Re: NullPointerException
I am going way out on a limb here, but I might
Subject: Re: NullPointerException
i am not a fundu in struts but still ..:)
please go through the below link and check whether it make sense. Null
pointer exception usually arises when we are trying to extract some values
from variables which are "null". Please check whether the v
I am going way out on a limb here, but I might have something to do with
retrieving your message resources. Make sure you have your
ApplicationResources.properties file located in your WEB-INF/classes.
uma.k wrote:
I get NullPointerException when I access this index.jsp page. I also have
Applica
If you look at the error message, I get NullPointer at this line in the
generated java file
int _jspx_eval_bean_message_0 = _jspx_th_bean_message_0.doStartTag();
//NULLPOINTER
package org.apache.jsp;
import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.jsp.*;
import org.apac
i am not a fundu in struts but still ..:)
please go through the below link and check whether it make sense. Null
pointer exception usually arises when we are trying to extract some values
from variables which are "null". Please check whether the variables u r
calling when the action is perfor
I have double checked that the signin/Welcome.jsp is
at the application root. Therefore, the forward
statement should not cause the NullPointerException
problem.
What confuses me is that I have done something similar
before; i.e. I have other java class extends Action.
And upon completio
Where is signin/Welcome.jsp?
if located under WEB-INF/signin then modify forward statement to
Martin
- Original Message -
From: "Caroline Jen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, May 14, 2004 10:54 AM
Subject: NullPointerException - findSuccess(Unknown Source)
> Nee
The stack trace indicates that you are extending
org.apache.struts.scaffold.BaseAction rather than just Action.
I'm not familiar with the scaffold package - perhaps the forward "success"
has a special meaning within scaffold?
Paul
> -Original Message-
> From: Caroline Jen [mailto:[EMAIL
79 matches
Mail list logo