Uploaded image for project: 'Mesos'
  1. Mesos
  2. MESOS-3055

Master doesn't properly handle SUBSCRIBE call

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 0.23.0
    • 0.23.0
    • None
    • None

    Description

      Master::subscribe() incorrectly handles re-registration. It handles it as a registration request (not "re-registration") because of a bug in the if loop (should have been !frameworkInfo.has_id()).

      void Master::subscribe(
          const UPID& from,
          const scheduler::Call::Subscribe& subscribe)
      {
        const FrameworkInfo& frameworkInfo = subscribe.framework_info();
      
        // TODO(vinod): Instead of calling '(re-)registerFramework()' from
        // here refactor those methods to call 'subscribe()'.
        if (frameworkInfo.has_id() || frameworkInfo.id() == "") {
          registerFramework(from, frameworkInfo);
        } else {
          reregisterFramework(from, frameworkInfo, subscribe.force());
        }
      }
      
      

      Attachments

        Activity

          People

            vinodkone Vinod Kone
            vinodkone Vinod Kone
            Benjamin Mahler Benjamin Mahler
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: