[jira] [Updated] (TS-2656) Determine server connection scheme immediately before connecting.
[ https://issues.apache.org/jira/browse/TS-2656?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-2656: -- Component/s: HTTP Determine server connection scheme immediately before connecting. - Key: TS-2656 URL: https://issues.apache.org/jira/browse/TS-2656 Project: Traffic Server Issue Type: Improvement Components: HTTP Reporter: Ron Barber Assignee: Leif Hedstrom Fix For: 5.0.0 Attachments: TS-2656_2.patch ATS currently sets the server connection scheme (sm-t_state.scheme) after remapping has occurred based on the server URL. Plugin's that desire to modify the connection scheme after remapping (such as in the TS_EVENT_HTTP_OS_DNS event) have no method to do so. I propose adding the following getter/setter API functions: {code} /** Retrieves the server connection scheme for the specified transaction @a txnp. TSHttpTxnServerSchemeGet() places the length of the string in the length argument. If the length is NULL then no attempt is made to dereference it. @note This function is useful if the server connection scheme needs to retrieved post remapping. @param txnp The transaction whose connection scheme to be retrieved @param length length of the returned string. @return The connection scheme for the server connection, as a string, or NULL if not set. */ tsapi const char* TSHttpTxnServerSchemeGet(TSHttpTxn txnp, int *length); /** Set the connection scheme to the server (http or https) for the specified transaction @a txnp to the string value. If length is -1 then TSHttpTxnServerSchemeSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. @note This function is useful if the server connection scheme needs to change post remapping. @param txnp The transaction whose connection scheme to be set @param value value to set the scheme to. @param length string stored in value. @return @c TS_SUCCESS if scheme is recognized, else @c TS_ERROR */ tsapi TSReturnCode TSHttpTxnServerSchemeSet(TSHttpTxn txnp, const char* value, int length); {code} -- This message was sent by Atlassian JIRA (v6.2#6252)
[jira] [Updated] (TS-2656) Determine server connection scheme immediately before connecting.
[ https://issues.apache.org/jira/browse/TS-2656?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ron Barber updated TS-2656: --- Attachment: TS-2656_2.patch Previous patch was incomplete and did not handle the case where the server_request URL was never set. In that case it should take the scheme from the client_request URL. Determine server connection scheme immediately before connecting. - Key: TS-2656 URL: https://issues.apache.org/jira/browse/TS-2656 Project: Traffic Server Issue Type: Improvement Reporter: Ron Barber Assignee: Leif Hedstrom Fix For: 5.0.0 Attachments: TS-2656_2.patch ATS currently sets the server connection scheme (sm-t_state.scheme) after remapping has occurred based on the server URL. Plugin's that desire to modify the connection scheme after remapping (such as in the TS_EVENT_HTTP_OS_DNS event) have no method to do so. I propose adding the following getter/setter API functions: {code} /** Retrieves the server connection scheme for the specified transaction @a txnp. TSHttpTxnServerSchemeGet() places the length of the string in the length argument. If the length is NULL then no attempt is made to dereference it. @note This function is useful if the server connection scheme needs to retrieved post remapping. @param txnp The transaction whose connection scheme to be retrieved @param length length of the returned string. @return The connection scheme for the server connection, as a string, or NULL if not set. */ tsapi const char* TSHttpTxnServerSchemeGet(TSHttpTxn txnp, int *length); /** Set the connection scheme to the server (http or https) for the specified transaction @a txnp to the string value. If length is -1 then TSHttpTxnServerSchemeSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. @note This function is useful if the server connection scheme needs to change post remapping. @param txnp The transaction whose connection scheme to be set @param value value to set the scheme to. @param length string stored in value. @return @c TS_SUCCESS if scheme is recognized, else @c TS_ERROR */ tsapi TSReturnCode TSHttpTxnServerSchemeSet(TSHttpTxn txnp, const char* value, int length); {code} -- This message was sent by Atlassian JIRA (v6.2#6252)
[jira] [Updated] (TS-2656) Determine server connection scheme immediately before connecting.
[ https://issues.apache.org/jira/browse/TS-2656?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ron Barber updated TS-2656: --- Attachment: (was: TS-2656_2.patch) Determine server connection scheme immediately before connecting. - Key: TS-2656 URL: https://issues.apache.org/jira/browse/TS-2656 Project: Traffic Server Issue Type: Improvement Reporter: Ron Barber Assignee: Leif Hedstrom Fix For: 5.0.0 ATS currently sets the server connection scheme (sm-t_state.scheme) after remapping has occurred based on the server URL. Plugin's that desire to modify the connection scheme after remapping (such as in the TS_EVENT_HTTP_OS_DNS event) have no method to do so. I propose adding the following getter/setter API functions: {code} /** Retrieves the server connection scheme for the specified transaction @a txnp. TSHttpTxnServerSchemeGet() places the length of the string in the length argument. If the length is NULL then no attempt is made to dereference it. @note This function is useful if the server connection scheme needs to retrieved post remapping. @param txnp The transaction whose connection scheme to be retrieved @param length length of the returned string. @return The connection scheme for the server connection, as a string, or NULL if not set. */ tsapi const char* TSHttpTxnServerSchemeGet(TSHttpTxn txnp, int *length); /** Set the connection scheme to the server (http or https) for the specified transaction @a txnp to the string value. If length is -1 then TSHttpTxnServerSchemeSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. @note This function is useful if the server connection scheme needs to change post remapping. @param txnp The transaction whose connection scheme to be set @param value value to set the scheme to. @param length string stored in value. @return @c TS_SUCCESS if scheme is recognized, else @c TS_ERROR */ tsapi TSReturnCode TSHttpTxnServerSchemeSet(TSHttpTxn txnp, const char* value, int length); {code} -- This message was sent by Atlassian JIRA (v6.2#6252)
[jira] [Updated] (TS-2656) Determine server connection scheme immediately before connecting.
[ https://issues.apache.org/jira/browse/TS-2656?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-2656: -- Fix Version/s: 5.0.0 Determine server connection scheme immediately before connecting. - Key: TS-2656 URL: https://issues.apache.org/jira/browse/TS-2656 Project: Traffic Server Issue Type: Improvement Reporter: Ron Barber Fix For: 5.0.0 Attachments: TS-2656_2.patch ATS currently sets the server connection scheme (sm-t_state.scheme) after remapping has occurred based on the server URL. Plugin's that desire to modify the connection scheme after remapping (such as in the TS_EVENT_HTTP_OS_DNS event) have no method to do so. I propose adding the following getter/setter API functions: {code} /** Retrieves the server connection scheme for the specified transaction @a txnp. TSHttpTxnServerSchemeGet() places the length of the string in the length argument. If the length is NULL then no attempt is made to dereference it. @note This function is useful if the server connection scheme needs to retrieved post remapping. @param txnp The transaction whose connection scheme to be retrieved @param length length of the returned string. @return The connection scheme for the server connection, as a string, or NULL if not set. */ tsapi const char* TSHttpTxnServerSchemeGet(TSHttpTxn txnp, int *length); /** Set the connection scheme to the server (http or https) for the specified transaction @a txnp to the string value. If length is -1 then TSHttpTxnServerSchemeSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. @note This function is useful if the server connection scheme needs to change post remapping. @param txnp The transaction whose connection scheme to be set @param value value to set the scheme to. @param length string stored in value. @return @c TS_SUCCESS if scheme is recognized, else @c TS_ERROR */ tsapi TSReturnCode TSHttpTxnServerSchemeSet(TSHttpTxn txnp, const char* value, int length); {code} -- This message was sent by Atlassian JIRA (v6.2#6252)
[jira] [Updated] (TS-2656) Determine server connection scheme immediately before connecting.
[ https://issues.apache.org/jira/browse/TS-2656?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ron Barber updated TS-2656: --- Summary: Determine server connection scheme immediately before connecting. (was: Determine server connection scheme immedately before connecting.) Determine server connection scheme immediately before connecting. - Key: TS-2656 URL: https://issues.apache.org/jira/browse/TS-2656 Project: Traffic Server Issue Type: Improvement Reporter: Ron Barber ATS currently sets the server connection scheme (sm-t_state.scheme) after remapping has occurred based on the server URL. Plugin's that desire to modify the connection scheme after remapping (such as in the TS_EVENT_HTTP_OS_DNS event) have no method to do so. I propose adding the following getter/setter API functions: {code} /** Retrieves the server connection scheme for the specified transaction @a txnp. TSHttpTxnServerSchemeGet() places the length of the string in the length argument. If the length is NULL then no attempt is made to dereference it. @note This function is useful if the server connection scheme needs to retrieved post remapping. @param txnp The transaction whose connection scheme to be retrieved @param length length of the returned string. @return The connection scheme for the server connection, as a string, or NULL if not set. */ tsapi const char* TSHttpTxnServerSchemeGet(TSHttpTxn txnp, int *length); /** Set the connection scheme to the server (http or https) for the specified transaction @a txnp to the string value. If length is -1 then TSHttpTxnServerSchemeSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. @note This function is useful if the server connection scheme needs to change post remapping. @param txnp The transaction whose connection scheme to be set @param value value to set the scheme to. @param length string stored in value. @return @c TS_SUCCESS if scheme is recognized, else @c TS_ERROR */ tsapi TSReturnCode TSHttpTxnServerSchemeSet(TSHttpTxn txnp, const char* value, int length); {code} -- This message was sent by Atlassian JIRA (v6.2#6252)
[jira] [Updated] (TS-2656) Determine server connection scheme immediately before connecting.
[ https://issues.apache.org/jira/browse/TS-2656?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ron Barber updated TS-2656: --- Attachment: TS-2656_2.patch Updated patch attached. I ran this for a short while, maybe 30 minutes, with production traffic and didn't see any differences as compared to another production server running an older version. Determine server connection scheme immediately before connecting. - Key: TS-2656 URL: https://issues.apache.org/jira/browse/TS-2656 Project: Traffic Server Issue Type: Improvement Reporter: Ron Barber Attachments: TS-2656_2.patch ATS currently sets the server connection scheme (sm-t_state.scheme) after remapping has occurred based on the server URL. Plugin's that desire to modify the connection scheme after remapping (such as in the TS_EVENT_HTTP_OS_DNS event) have no method to do so. I propose adding the following getter/setter API functions: {code} /** Retrieves the server connection scheme for the specified transaction @a txnp. TSHttpTxnServerSchemeGet() places the length of the string in the length argument. If the length is NULL then no attempt is made to dereference it. @note This function is useful if the server connection scheme needs to retrieved post remapping. @param txnp The transaction whose connection scheme to be retrieved @param length length of the returned string. @return The connection scheme for the server connection, as a string, or NULL if not set. */ tsapi const char* TSHttpTxnServerSchemeGet(TSHttpTxn txnp, int *length); /** Set the connection scheme to the server (http or https) for the specified transaction @a txnp to the string value. If length is -1 then TSHttpTxnServerSchemeSet() assumes that value is null-terminated. Otherwise, the length of the string value is taken to be length. @note This function is useful if the server connection scheme needs to change post remapping. @param txnp The transaction whose connection scheme to be set @param value value to set the scheme to. @param length string stored in value. @return @c TS_SUCCESS if scheme is recognized, else @c TS_ERROR */ tsapi TSReturnCode TSHttpTxnServerSchemeSet(TSHttpTxn txnp, const char* value, int length); {code} -- This message was sent by Atlassian JIRA (v6.2#6252)