File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes Struts2 and Eclipse: No configuration found for the specified action in namespace: '' Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts2 and Eclipse: No configuration found for the specified action in namespace: Watch "Struts2 and Eclipse: No configuration found for the specified action in namespace: New topic
Author

Struts2 and Eclipse: No configuration found for the specified action in namespace: ''

eddy johns
Ranch Hand

Joined: Feb 16, 2010
Posts: 67
Hi everyone. I'm running the struts2 simple HelloWorld app from http://www.vaannila.com/struts-2/struts-2-example/struts-2-hello-world-example-1.html, and getting this error: "No configuration found for the specified action: 'HelloWorld' in namespace: ''. Form action defaulting to 'action' attribute's literal value." Then, when I run the first jsp, it doesn't even call the HelloWorld.java.

I think the reason is that the app -- in Eclipse -- doesn't even find my struts.xml, because if I change the namespace property to something like this:



it still gives the same error, with namespace:''

My struts.xml is in the java src folder and it definitely in the project's classpath. Why isn't it getting found?

Thanks!
Venkata Kumar
Ranch Hand

Joined: Apr 16, 2008
Posts: 110

Hi Johns,

Please post the contents of Jsp that you are accessing.

<package name="default" extends="struts-default" namespace="asdfasdfadsfasdf">

Default namespace is "/". You have to append "/" to the new namespace string

Are you able to access the page when you don't specify any namespace?

How are you accessing the action class. If you are using namespace then action url should be accessed using namespace
for example http://<IPADDRESS>:<PORT>/<ApplicationContextRoot>/<Namespace>/<Action>;


SCJP 5.0, SCWCD 5, preparing for SCDJWS
Sita Marivada
Greenhorn

Joined: Apr 01, 2010
Posts: 14
I am also facing the same error with the same example.Can some body help me on this?


Sita Putta
Lalit Negi
Greenhorn

Joined: Aug 06, 2012
Posts: 1
The Vannila example posted has various dtd and other tags on the top of various jsp file index.jsp , success.jsp, struts.xml etc or try to compare your app code with the Example1 posted in the same site. it should work then.
wking qing
Greenhorn

Joined: Nov 10, 2012
Posts: 2
this problem is easy.you can do this:
new a folder named "namespace" in WebRoot ,then drag success.jsp in it.
the action result url will be change into <ApplicationContextRoot>/<Namespace>/<result location>;
for example :
your url will be change into <ApplicationContextRoot>/asdfasdfadsfasdf/success.jsp
obviously,it's wrong url.because you don't have a jsp in the folder named asdfasdfadsfasd
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Struts2 and Eclipse: No configuration found for the specified action in namespace: ''