You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by "Oknet Xu (JIRA)" <ji...@apache.org> on 2016/09/28 07:32:20 UTC

[jira] [Commented] (TS-4539) The mutex of server_vc is not set while server_session reuse

    [ https://issues.apache.org/jira/browse/TS-4539?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15528725#comment-15528725 ] 

Oknet Xu commented on TS-4539:
------------------------------

This is not a bug, but I found another bug in ServerSessionPool and HttpSessionManager.

A VC cannot be migrated to other EThreads while it is allocated.
It is managed by NetHandler running in the same EThread.
The NetHandler own the VC and the VC is only freed by the NetHandler.

InactivityCop is a part of NetHandler due to they are share same mutex therefore, similar to NetHandler, it could free the VC.

> The mutex of server_vc is not set while server_session reuse
> ------------------------------------------------------------
>
>                 Key: TS-4539
>                 URL: https://issues.apache.org/jira/browse/TS-4539
>             Project: Traffic Server
>          Issue Type: Bug
>          Components: HTTP
>            Reporter: Oknet Xu
>            Assignee: Oknet Xu
>             Fix For: 7.1.0
>
>
> 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.
>  
> {code}
> 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;
> {code}
> 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.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)