[
https://issues.apache.org/jira/browse/TS-4698?focusedWorklogId=26350&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-26350
]
ASF GitHub Bot logged work on TS-4698:
--------------------------------------
Author: ASF GitHub Bot
Created on: 12/Aug/16 04:16
Start Date: 12/Aug/16 04:16
Worklog Time Spent: 10m
Work Description: Github user jpeach commented on a diff in the pull
request:
https://github.com/apache/trafficserver/pull/822#discussion_r74539863
--- Diff: proxy/InkAPI.cc ---
@@ -4982,6 +4982,15 @@ TSHttpTxnInfoIntGet(TSHttpTxn txnp, TSHttpTxnInfoKey
key, TSMgmtInt *value)
return TS_SUCCESS;
}
+int
+TSHttpTxnIsWebsocket(TSHttpTxn txnp)
+{
+ sdk_assert(sdk_sanity_check_txn(txnp) == TS_SUCCESS);
+
+ HttpSM *sm = (HttpSM *)txnp;
+ return sm->t_state.is_upgrade_request && sm->t_state.upgrade_token_wks
== MIME_VALUE_WEBSOCKET;
--- End diff --
Why don't you test ''HttpTransact::State::is_websocket``?
Issue Time Tracking
-------------------
Worklog Id: (was: 26350)
Time Spent: 1h 10m (was: 1h)
> Add an API call to detect websocket connections
> -----------------------------------------------
>
> Key: TS-4698
> URL: https://issues.apache.org/jira/browse/TS-4698
> Project: Traffic Server
> Issue Type: Improvement
> Components: TS API
> Affects Versions: 7.0.0
> Reporter: Oliver Goodman
> Assignee: Oliver Goodman
> Fix For: 7.0.0
>
> Time Spent: 1h 10m
> Remaining Estimate: 0h
>
> It is possible for TS to terminate websocket connections using a server
> intercept plugin but in order to do so the plugin needs a reliable way to
> identify such connections. This information is known and used internally but
> not AFAICT yet exposed via the TS API. It is here proposed that a simple call
> be added to return this information.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)