title: There is no Action mapped for namespace / and action name CreateTicket
body: <p>I am getting the below error, I have googled lot and got many different types of solutions but not able to resolve it.</p>
  
  <p>My Stacktrace</p>
  
  <pre><code>    SEVERE: Could not find action or result
  There is no Action mapped for namespace / and action name CreateTicket. - [unknown location]
      at com.opensymphony.xwork2.DefaultActionProxy.prepare(DefaultActionProxy.java:186)
      at org.apache.struts2.impl.StrutsActionProxyFactory.createActionProxy(StrutsActionProxyFactory.java:41)
      at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:494)
      at org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:419)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
      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:174)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:873)
      at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
      at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
      at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
      at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
      at java.lang.Thread.run(Thread.java:595)
  </code></pre>
  
  <p>My Struts.xml</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;!DOCTYPE struts PUBLIC
      "-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
      "http://struts.apache.org/dtds/struts-2.0.dtd"&gt;
  &lt;struts&gt;
      &lt;constant name="struts.devMode" value="true" /&gt;
      &lt;constant name="struts.multipart.maxSize" value="20480000" /&gt;
      &lt;constant name="struts.enable.DynamicMethodInvocation" value="false" /&gt;
  
      &lt;package name="default" extends="struts-default"&gt;
          &lt;action name="CreateTicket" class="com.ticketservice.CreateTicket"&gt;
              &lt;result name="success"&gt;Welcome.jsp&lt;/result&gt;
              &lt;result name="error"&gt;Login.jsp&lt;/result&gt;
          &lt;/action&gt;
  
  
      &lt;/package&gt;
  &lt;/struts&gt; 
  </code></pre>
  
  <p>My Directory Structure</p>
  
  <p><img src="https://i.stack.imgur.com/qr3nA.jpg" alt="enter image description here"></p>
  
  <p>CreateTicket.java</p>
  
  <pre><code>package com.ticketservice;
  
  import com.opensymphony.xwork2.ActionSupport;
  
  public class CreateTicket extends ActionSupport {
  
      public String execute() {
  
         return "success";
      }
  }
  </code></pre>
  
  <p>Welcome.jsp</p>
  
  <pre><code>&lt;p&gt;done&lt;/p&gt;
  </code></pre>
  
  <p>Login.jsp</p>
  
  <pre><code>&lt;p&gt;not done&lt;/p&gt;
  </code></pre>
  
  <p>I have create this project to learn Struts so only wanted to see how mapping of struts.xml to action class done</p>
  
  <p>I am successfully able to run localhost:8080/TicketSystem/index.html.<br>
  But when I run localhost:8080/TicketSystem/CreateTicket.action. I got the above error..</p>
  
  <p>Kindly help me to resolve it.</p>
  
  <p>Regards,
  Mahesh</p>