GitHub user clearswift opened an issue:

    https://github.com/apache/trafficserver/issues/1598

    Assertion failing when calling TSHttpTxnReenable from another thread.

    See the attached example plugin. This hooks onto the 
`TS_HTTP_READ_RESPONSE_HDR_HOOK` hook and, on that event, launches a thread 
that re-enables the transaction. This fails the assertion 
`ink_release_assert(!server_vc || !client_vc || server_vc->thread == 
client_vc->thread);` on line 5933 in HttpSM.cc when making multiple connections.
    
    A simple test of this is to browse any reasonably substantial web page (I 
used bbc.co.uk) through the proxy with this plugin enabled. Removing the 
assertion allows the page to load successfully.
    
    So why is the assertion there? What's the issue with the client and server 
threads being different? As I said, removing the assertion makes things work 
but is there some corner case where this matters?
    
    Alternatively, is the plugin wrong? Is it allowed to call TSHttpTxnReenable 
from a different thread? Is there a better way to do this?
    
    
[ThreadTestPlugin.zip](https://github.com/apache/trafficserver/files/855468/ThreadTestPlugin.zip)


----

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to