Uploaded image for project: 'Traffic Server'
  1. Traffic Server
  2. TS-4539

The mutex of server_vc is not set while server_session reuse

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Not A Bug
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: HTTP
    • Labels:
      None

      Description

      NetAccept got a client_vc and call new_ProxyMutex() to assign a mutex.
      And the HttpClientSession, HttpSM, HttpServerSession, server_vc also share the same mutex.

      The HttpServerSession and server_vc will put into ServerSessionPool and may assign to next new client_vc.

      The HttpSM::attach_server_session() only set the mutex of HttpServerSession to the mutex of HttpSM after get a HttpServerSession from ServerSessionPool.
      But it forget to set the mutex of server_vc to the mutex of HttpSM.

      void
      HttpSM::attach_server_session(HttpServerSession *s)
      {
        hsm_release_assert(server_session == NULL);
        hsm_release_assert(server_entry == NULL);
        hsm_release_assert(s->state == HSS_ACTIVE);
        server_session = s; 
        server_session->transact_count++;
      
        // Set the mutex so that we have something to update
        //   stats with
        server_session->mutex = this->mutex;
      

      But I can not found any issue, Is it by design?
      Or it is hard to locate the problem, due to my limited knowedge on HttpSM.

        Attachments

          Activity

            People

            • Assignee:
              oknet Oknet Xu
              Reporter:
              oknet Oknet Xu
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: