title: How to continue past a failing stage in Jenkins declarative pipeline syntax
body: <p>I want to define multiple stages in Jenkins declarative pipeline syntax which can continue past any one of them failing. I cannot find any existing questions which are true duplicates, because they all assume or allow scripted syntax.</p>
  
  <pre><code>pipeline {
      agent any
      stages {
          stage('stage 1') {
              steps {
                  echo "I need to run every time"
              }
          }
          stage('stage 2') {
              steps {
                  echo "I need to run every time, even if stage 1 fails"
              }
          }
          stage('stage 3') {
              steps {
                  echo "Bonus points if the solution is robust enough to allow me to continue *or* be halted based on previous stage status"
              }
          }
      }
  }
  </code></pre>
  
  <p>To clarify, I'm not looking for how to do accomplish this in scripted syntax. I'm trying to understand if this kind of flow control is actually supported and formalized in declarative syntax. To that end, I'll try to define exactly what I'm looking for:</p>
  
  <h3>Required</h3>
  
  <ul>
  <li>No try/catch. I don't want to drop down into scripted mode, or "wrap" my declarative pipeline in another shared library or scripted block.</li>
  <li>No <code>post step</code> shenanigans. I want true multiple stages, not one stage with a <code>post always</code> step that contains all my other logic</li>
  </ul>
  
  <h3>Optional</h3>
  
  <ul>
  <li>The failing stage should be recognized as failed; I don't want a failed stage showing up as green because it was "skipped" or "continued".</li>
  <li>A build with any failed stage should be marked as red (or yellow, or anything that is not green).</li>
  </ul>
  
  <h3> Related but Not Sufficient </h3>
  
  <ul>
  <li><a href="https://stackoverflow.com/questions/40942178/how-to-continue-a-stage-in-jenkins-pipeline-even-if-the-build-fails">How to continue a stage in jenkins pipeline even if the build fails</a></li>
  <li><a href="https://stackoverflow.com/questions/43439093/determine-failed-stage-in-jenkins-declaritive-pipeline">Determine Failed Stage in Jenkins Declaritive Pipeline</a></li>
  <li><a href="https://stackoverflow.com/questions/40600621/continue-jenkins-pipeline-past-failed-stage">Continue Jenkins pipeline past failed stage</a></li>
  <li><a href="https://stackoverflow.com/questions/36852310/show-a-jenkins-pipeline-stage-as-failed-without-failing-the-whole-job?rq=1">Show a Jenkins pipeline stage as failed without failing the whole job</a></li>
  <li><a href="https://stackoverflow.com/questions/41038079/jenkins-continue-pipeline-on-failed-stage?rq=1">Jenkins continue pipeline on failed stage</a></li>
  </ul>