Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Struts2 Action mapping problem

Thread Tools

Struts2 Action mapping problem

newbieIn newbieIn is offline
Junior Member
Join Date: Jul 2012
Posts: 2

I am new to struts2 and to this forum.

I have written an action class as follows

public class StartAction extends ActionSupport implements SessionAware{
private Map<String, Object> session;
public String execute() {
return LOGIN;
public void setSession(Map<String, Object> session) {
this.session = session;

public Map<String, Object> getSession(){
return session;

And have placed struts entries as
<action name="Start" class="common.StartAction"
<result name="login" >/finadvisor/jspPages/Login.jsp</result>

And jsp calling Start Action is as
<h1>Hello World!</h1>
<s:form action="Start" method="POST">
<s:submit value="Start" align="center"/>

Not sure where I am going wrong, I am getting below useless ST
Struts Problem Report

Struts has detected an unhandled exception:

There is no Action mapped for namespace / and action name .

There is no Action mapped for namespace / and action name . - [unknown location]
com.opensymphony.xwork2.DefaultActionProxy.prepare (
org.apache.struts2.impl.StrutsActionProxyFactory.c reateActionProxy(
com.opensymphony.xwork2.DefaultActionProxyFactory. createActionProxy( 7)
org.apache.struts2.dispatcher.Dispatcher.serviceAc tion( .executeAction( areAndExecuteFilter.doFilter(StrutsPrepareAndExecu ternalDoFilter( Filter(
org.apache.catalina.core.StandardWrapperValve.invo ke(
org.apache.catalina.core.StandardContextValve.invo keInternal(
org.apache.catalina.core.StandardContextValve.invo ke(
org.apache.catalina.core.StandardPipeline.doInvoke (
org.apache.catalina.core.StandardPipeline.doInvoke (
org.apache.catalina.core.StandardPipeline.doInvoke (
org.apache.catalina.core.StandardPipeline.doInvoke (
org.apache.catalina.core.StandardEngineValve.invok e(
org.apache.catalina.core.StandardPipeline.doInvoke (
org.apache.catalina.core.StandardPipeline.doInvoke (
com.sun.enterprise.web.connector.grizzly.DefaultPr ocessorTask.invokeAdapter(DefaultProcessorTask.jav a:637)
com.sun.enterprise.web.connector.grizzly.DefaultPr ocessorTask.doProcess(
com.sun.enterprise.web.connector.grizzly.DefaultPr ocessorTask.process(
com.sun.enterprise.web.connector.grizzly.DefaultRe adTask.executeProcessorTask( 41)
com.sun.enterprise.web.connector.grizzly.DefaultRe adTask.doTask(
com.sun.enterprise.web.connector.grizzly.DefaultRe adTask.doTask(
com.sun.enterprise.web.portunif.PortUnificationPip eline$PUTask.doTask( 80)
com.sun.enterprise.web.connector.grizzly.TaskBase. run(

You are seeing this page because development mode is enabled. Development mode, or devMode, enables extra debugging behaviors and reports to assist developers. To disable this mode, set:

in your WEB-INF/classes/ file.

Please help!!!
Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
RAD7 and Struts2 404 error timjowers Java 0 10-16-2008 10:04 PM
Struts2 and Freemarker : How do you pass a variable into a struts 2action from a freemarker template theog Java 0 07-07-2008 02:02 AM
struts2 + commons validator + JSF? Elhanan Java 0 12-24-2006 06:54 AM
[struts2] Taglib and freemarker -> insert bodyContent OTB Java 0 12-15-2006 01:43 PM
Struts mapping action to action??? runescience Java 3 02-07-2006 04:07 PM