title: Java servlets - stop executing and redirect on error
body: <p>I have the following bit of code in my java servlet:</p>
  
  <pre><code>if(passenger == null){
              response.sendError(400, "The specified passenger does not exist.");
          }
  </code></pre>
  
  <p>The page does redirect to the error page, however, the rest of the servlet code is still executed. How do I redirect and sort of 'break' out of the servlet?</p>