code:     protected void submit(StaplerRequest req, StaplerResponse rsp) throws IOException, ServletException, FormException {
          super.submit(req,rsp);
          JSONObject json = req.getSubmittedForm();
  
          makeDisabled(req.getParameter("disable")!=null);
  
          jdk = req.getParameter("jdk");
          if(req.getParameter("hasCustomQuietPeriod")!=null) {
              quietPeriod = Integer.parseInt(req.getParameter("quiet_period"));
          } else {
              quietPeriod = null;
          }
          if(req.getParameter("hasCustomScmCheckoutRetryCount")!=null) {
              scmCheckoutRetryCount = Integer.parseInt(req.getParameter("scmCheckoutRetryCount"));
          } else {
              scmCheckoutRetryCount = null;
          }
          blockBuildWhenDownstreamBuilding = req.getParameter("blockBuildWhenDownstreamBuilding")!=null;
          blockBuildWhenUpstreamBuilding = req.getParameter("blockBuildWhenUpstreamBuilding")!=null;
  
          if(req.hasParameter("customWorkspace")) {
              customWorkspace = Util.fixEmptyAndTrim(req.getParameter("customWorkspace.directory"));
          } else {
              customWorkspace = null;
          }
  
          if (json.has("scmCheckoutStrategy"))
              scmCheckoutStrategy = req.bindJSON(SCMCheckoutStrategy.class,
                  json.getJSONObject("scmCheckoutStrategy"));
          else
              scmCheckoutStrategy = null;
  
          
          if(req.getParameter("hasSlaveAffinity")!=null) {
              assignedNode = Util.fixEmptyAndTrim(req.getParameter("_.assignedLabelString"));
          } else {
              assignedNode = null;
          }
          canRoam = assignedNode==null;
  
          concurrentBuild = req.getSubmittedForm().has("concurrentBuild");
  
          authToken = BuildAuthorizationToken.create(req);
  
          setScm(SCMS.parseSCM(req,this));
  
          for (Trigger t : triggers())
              t.stop();
          triggers = buildDescribable(req, Trigger.for_(this));
          for (Trigger t : triggers)
              t.start(this,true);
  
          for (Publisher _t : Descriptor.newInstancesFromHeteroList(req, json, "publisher", Jenkins.getInstance().getExtensionList(BuildTrigger.DescriptorImpl.class))) {
              BuildTrigger t = (BuildTrigger) _t;
              for (AbstractProject downstream : t.getChildProjects(this)) {
                  downstream.checkPermission(BUILD);
              }
          }
      }
  
      /**
       * @deprecated
       *      As of 1.261. Use {@link #buildDescribable(StaplerRequest, List)} instead.
       */
  