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

libprocess io does not support peek()

    XMLWordPrintableJSON

Details

    • Mesosphere Sprint 15, Mesosphere Sprint 16, Mesosphere Sprint 17
    • 3

    Description

      Finally, I so wish we could just do:

      io::peek(request->socket, 6)
        .then([request](const string& data) {
          // Comment about the rules ...
          if (data.length() < 2) { // Rule 1
          
          } else if (...) { // Rule 2.
          
          } else if (...) { // Rule 3.
          
          }
          
          if (ssl) {
            accept_SSL_callback(request);
          } else {
            ...;
          }
        });
      

      from:
      https://reviews.apache.org/r/31207/

      Attachments

        Activity

          People

            hartem Artem Harutyunyan
            hartem Artem Harutyunyan
            Benjamin Hindman Benjamin Hindman
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: