title: Servlet RequestDispatcher is not forwarding
body: <p>I'm learning Java Servlets and JSP.</p>
  
  <p>I have the following code:</p>
  
  <p><code>HelloServlet.jsp</code></p>
  
  <pre><code>public class HelloServlet extends HttpServlet {
      private static final long serialVersionUID=1;
  
      protected void doGet(HttpServletRequest request,
         HttpServletResponse response)
         throws ServletException, IOException {
  
          response.setContentType("text/html");
          response.setCharacterEncoding("utf-8);
  
          RequestDispatcher aDispatcher = request.getRequestDispatcher("file.jsp");
          aDispatcher.forward(request,response);
     }
  }
  </code></pre>
  
  <p><code>file.jsp</code></p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;%@ page language="java" contentType="text/html; charset=UTF-8" 
     pageEncoding="UTF-8"%&gt;
  &lt;%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %&gt;
  
  &lt;html&gt;
      &lt;head&gt;
          &lt;title&gt;First JSP&lt;/title&gt;
      &lt;/head&gt;
      &lt;body&gt;
          Hello!!
      &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>My <code>web.xml</code> looks like this:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;web-app xmlns:xsi="http://w3.org/2001/XMLSchema-instance" 
     xmlns="http://java.sun.com/xml/ns/javaee" 
     xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
     xmlns:schemaLocation="http://java.sun.som/xml/ns/javaee 
        http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
     id="WebApp_ID" version="2.5"&gt;
  
      &lt;display-name&gt;Hello&lt;/display-name&gt;
  
      &lt;welcome-file-list&gt;
          &lt;welcome-file&gt;index.jsp&lt;/welcome-file&gt;
      &lt;/welcome-file-list&gt;
  
      &lt;servlet&gt;
          &lt;description&gt;&lt;/description&gt;
          &lt;display-name&gt;Hello Servlet&lt;/display-name&gt;
          &lt;servlet-name&gt;hello&lt;/servlet-name&gt;
          &lt;servlet-class&gt;be.howest.HelloServlet&lt;/servlet-class&gt;
      &lt;/servlet&gt;
  
      &lt;servlet-mapping&gt;
          &lt;servlet-name&gt;hello&lt;/servlet-name&gt;
          &lt;url-pattern&gt;/urlpattern&lt;/url-pattern&gt;
      &lt;/servlet-mapping&gt;
  
  &lt;/web-app&gt;
  </code></pre>
  
  <p>When I'm running the file on Tomcat, I get the following error: <br>
  <code>HTTP Status 404 - /Projectname/file.jsp</code></p>
  
  <pre><code>type - Status report
  message - Projectname/file.jsp
  description - The requested resource is not available.
  </code></pre>
  
  <p>What did I do wrong? because I can't find the solution by myself</p>