globus_xio...iver_cntls(3)
β¨ globus_xio_http_driver_cntls π (aka globus_xio...iver_cntls(3))
πΈ NAME πΈ
globus_xio_http_driver_cntls β Attributes and Cntls π
okay so bestie, it's Attributes and Cntls. that's literally the whole vibe. periodt.
π¦ SYNOPSIS π¦
π Enumerations
enum globus_xio_http_handle_cmd_t {
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_HEADER,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_STATUS_CODE,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_REASON_PHRASE,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_HTTP_VERSION,
GLOBUS_XIO_HTTP_HANDLE_SET_END_OF_ENTITY,
GLOBUS_XIO_HTTP_HANDLE_SET_REQUEST_HEADER }
enum globus_xio_http_attr_cmd_t {
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_METHOD,
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_HTTP_VERSION,
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_HEADER,
GLOBUS_XIO_HTTP_ATTR_DELAY_WRITE_HEADER,
GLOBUS_XIO_HTTP_GET_REQUEST, GLOBUS_XIO_HTTP_GET_RESPONSE }
π Functions
globus_result_t globus_xio_handle_cntl (handle, driver,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_HEADER, const char *header_name,
const char *header_value)
globus_result_t globus_xio_handle_cntl (handle, driver,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_STATUS_CODE, int status)
globus_result_t globus_xio_handle_cntl (handle, driver,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_REASON_PHRASE, const char
*reason)
globus_result_t globus_xio_handle_cntl (handle, driver,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_HTTP_VERSION,
globus_xio_http_version_t version)
globus_result_t globus_xio_handle_cntl (handle, driver,
GLOBUS_XIO_HTTP_HANDLE_SET_END_OF_ENTITY)
globus_result_t globus_xio_attr_cntl (attr, driver,
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_METHOD, const char *method)
globus_result_t globus_xio_attr_cntl (attr, driver,
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_HTTP_VERSION,
globus_xio_http_version_t version)
globus_result_t globus_xio_attr_cntl (attr, driver,
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_HEADER, const char *header_name,
const char *header_value)
π Detailed Description π
Attributes and Cntls.
so these are the HTTP driver specific attrs and cntls β like, the little knobs that only the HTTP driver knows about. iykyk. π
See also π
globus_xio_attr_cntl()globus_xio_handle_cntl()
π Enumeration Type Documentation π
π enum globus_xio_http_attr_cmd_t
HTTP driver specific attribute and data descriptor cntls β¨
Enumerator
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_METHODβ See usage for:globus_xio_attr_cntlπ«ΆGLOBUS_XIO_HTTP_ATTR_SET_REQUEST_HTTP_VERSIONβ See usage for:globus_xio_attr_cntlπ«ΆGLOBUS_XIO_HTTP_ATTR_SET_REQUEST_HEADERβ See usage for:globus_xio_attr_cntlπ«ΆGLOBUS_XIO_HTTP_ATTR_DELAY_WRITE_HEADERβ See usage for:globus_xio_attr_cntlπ«ΆGLOBUS_XIO_HTTP_GET_REQUESTβ See usage for:globus_xio_data_descriptor_cntlπ«ΆGLOBUS_XIO_HTTP_GET_RESPONSEβ See usage for:globus_xio_data_descriptor_cntlπ«Ά
π§ enum globus_xio_http_handle_cmd_t
HTTP driver specific cntls β¨
Enumerator
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_HEADERβ See usage for:globus_xio_handle_cntlπ«ΆGLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_STATUS_CODEβ See usage for:globus_xio_handle_cntlπ«ΆGLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_REASON_PHRASEβ See usage for:globus_xio_handle_cntlπ«ΆGLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_HTTP_VERSIONβ See usage for:globus_xio_handle_cntlπ«ΆGLOBUS_XIO_HTTP_HANDLE_SET_END_OF_ENTITYβ See usage for:globus_xio_handle_cntlπ«Ά
okay bestie that's part one, don't go anywhere, there's more coming π
π₯ Function Documentation π₯
π globus_xio_attr_cntl() β set a request header π
globus_result_t globus_xio_attr_cntl (attr , driver ,
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_HEADER , const char * header_name,
const char * header_value)
Okay so bestie, heads up: this is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Its whole job? Set the value of an HTTP request header. Slay. π
Parameters π
header_nameβ Name of the HTTP header to set.header_valueβ Value of the HTTP header.
Certain headers will cause the HTTP driver to behave differently than normal. This must be called before
Transfer-Encoding: {identity|chunked}β Override the default transfer encoding. If a server knows the exact length of the message body, or does not intend to support persistent connections, it may set this header to be"identity".
If this is set to "identity" and any of the following are true, then the connection will be closed after the end of the message is sent:
- A
Content-Lengthheader is not present - The HTTP version is set to
"HTTP/1.0" - The
Connectionheader is set to"close"Attempts to set this to"chunked"with an"HTTP/1.0"client will fail with aGLOBUS_XIO_ERROR_HTTP_INVALID_HEADERerror.
Content-Length: 1*Digit- Provide a content length for the response message. If the
"chunked"transfer encoding is being used, then this header will be silently ignored by the HTTP driver.
- Provide a content length for the response message. If the
Connection: close- If present in the server response, the connection will be closed after the end of the data response is written. Otherwise, when persistent connections are enabled, the connection may be left open by the driver. Persistent connections are not yet implemented.
ngl that last "This must be called before" sentence just... ends in the source, bestie. Not me finishing it for you β the facts stay exactly as they are. π
β¨ globus_xio_attr_cntl() β set the request HTTP version β¨
globus_result_t globus_xio_attr_cntl (attr , driver ,
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_HTTP_VERSION ,
globus_xio_http_version_t version)
Again: overloaded member function, provided for convenience, differs from the above function only in what argument(s) it accepts. This one sets the HTTP version to use for a client request. π«
Parameters π¦
versionβ The HTTP version to use for the client request.
If the client is using HTTP/1.0 in a request which will send a request message body (such as a POST or PUT), then the client MUST set the "Content-Length" HTTP header to be the length of the message. If this attribute is not present, then the default of GLOBUS_XIO_HTTP_VERSION_1_1 will be used.
This attribute is ignored when opening the server side of an HTTP connection.
πΈ globus_xio_attr_cntl() β set the request method πΈ
globus_result_t globus_xio_attr_cntl (attr , driver ,
GLOBUS_XIO_HTTP_ATTR_SET_REQUEST_METHOD , const char * method)
Yep, another overloaded member function, provided for convenience, differing from the above function only in what argument(s) it accepts. Sets the HTTP method to use for a client request. Iconic behaviour, honestly. π
Parameters π
methodβ The request method string ("GET","PUT","POST", etc) that will be used in the HTTP request.
If this is not set on the target before it is opened, it will default to GET.
This attribute is ignored when opening the server side of an HTTP connection.
Setting this attribute may fail with
GLOBUS_XIO_ERROR_MEMORYGLOBUS_XIO_ERROR_PARAMETER
π globus_xio_handle_cntl() β end-of-entity for an HTTP body π
globus_result_t globus_xio_handle_cntl (handle , driver ,
GLOBUS_XIO_HTTP_HANDLE_SET_END_OF_ENTITY )
Overloaded member function, provided for convenience, differs from the above function only in what argument(s) it accepts. Indicate end-of-entity for an HTTP body. π«Ά
HTTP clients and servers must call this command to indicate to the driver that the entity-body which is being sent is completed. Subsequent attempts to write data on the handle will fail.
This handle command MUST be called on the client side of an HTTP connection when the HTTP method isOPTIONS,POST, orPUT, or when the open attributes indicate that an entity will be sent. This handle command MUST be called on the server side of an HTTP request connection when the HTTP method wasOPTIONS,GET,POST, orTRACE. Like, MUST must. Not optional, bestie. π
π
globus_xio_handle_cntl() β set a response header π
globus_result_t globus_xio_handle_cntl (handle , driver ,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_HEADER , const char * header_name,
const char * header_value)
Overloaded member function, provided for convenience, differs from the above function only in what argument(s) it accepts. Set the value of a response HTTP header. β¨
Parameters π
header_nameβ Name of the HTTP header to set.header_valueβ Value of the HTTP header.
Certain headers will cause changes in how the HTTP protocol will be handled. These include:
Transfer-Encoding: {identity|chunked}β Override the default transfer encoding. If a server knows the exact length of the message body, or does not intend to support persistent connections, it may set this header to be"identity".
If this is set to "identity" and any of the following are true, then the connection will be closed after the end of the response is sent:
- A
Content-Lengthheader is not present - The HTTP version is set to
"HTTP/1.0" - The
Connectionheader is set to"close"Attempts to set this to"chunked"with an"HTTP/1.0"client will fail with aGLOBUS_XIO_ERROR_HTTP_INVALID_HEADERerror.
Content-Length: 1*Digit- Provide a content length for the response message. If the
"chunked"transfer encoding is being used, then this header will be silently ignored by the HTTP driver.
- Provide a content length for the response message. If the
Connection: close- The HTTP connection will be closed after the end of the data response is written.
Returns π
This handle control function can fail with
GLOBUS_XIO_ERROR_MEMORYGLOBUS_XIO_ERROR_PARAMETERGLOBUS_XIO_ERROR_HTTP_INVALID_HEADER
π§ globus_xio_handle_cntl() β set the response HTTP version π§
globus_result_t globus_xio_handle_cntl (handle , driver ,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_HTTP_VERSION ,
globus_xio_http_version_t version)
Overloaded member function, provided for convenience, differs from the above function only in what argument(s) it accepts. Set the response HTTP version. β
Parameters π¦
versionβ The HTTP version to be used in the server response line.
If this cntl is not called by a server, then the default of GLOBUS_XIO_HTTP_VERSION_1_1 will be used, though no HTTP/1.1 features (chunking, persistent connections, etc) will be assumed if the client request was an HTTP/1.0 request. If this is called on the client-side of an HTTP connection, the handle control will fail with GLOBUS_XIO_ERROR_PARAMETER.
Returns π
This handle control function can fail with
GLOBUS_XIO_ERROR_MEMORYGLOBUS_XIO_ERROR_PARAMETER
π globus_xio_handle_cntl() β set the response reason phrase π
globus_result_t globus_xio_handle_cntl (handle , driver ,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_REASON_PHRASE , const char * reason)
Overloaded member function, provided for convenience, differs from the above function only in what argument(s) it accepts. Set the response reason phrase. π«
Parameters π
reasonβ The value of the HTTP response string, as per RFC 2616.
If this cntl is not called by a server, then a default value based on the handle's response status code will be generated. If this is called on the client-side of an HTTP connection, the handle control will fail with a GLOBUS_XIO_ERROR_PARAMETER error.
Returns πΈ
This handle control function can fail with
GLOBUS_XIO_ERROR_MEMORYGLOBUS_XIO_ERROR_PARAMETER
π globus_xio_handle_cntl() β set the response status code π
globus_result_t globus_xio_handle_cntl (handle , driver ,
GLOBUS_XIO_HTTP_HANDLE_SET_RESPONSE_STATUS_CODE , int status)
Overloaded member function, provided for convenience, differs from the above function only in what argument(s) it accepts. Set the response status code. π₯
Parameters π
statusβ Value in the range100-599which will be used as the HTTP response code, as per RFC 2616.
If this cntl is not called by a server, then the default value of 200 ("Ok") will be used. If this is called on the client-side of an HTTP connection, the handle control will fail with a GLOBUS_XIO_ERROR_PARAMETER error.
Returns π¦
This handle control function can fail with
GLOBUS_XIO_ERROR_PARAMETER
π Author π
Generated automatically by Doxygen for globus_xio from the source code.
and that's a wrap, bestie πβ¨ This was globus_xio Version 6.6, the <cyan>globus_xio...iver_cntls(3)</cyan> page, straight from the source code β go forth and set those headers, you absolute main character π«Άππ¦
π¦ where this page comes from
- fedora 43: globus-xio-doc 6.6-9.fc43 Β· Apache-2.0
- fedora 44: globus-xio-doc 6.6-10.fc44 Β· Apache-2.0
- ubuntu resolute: libglobus-xio-doc 6.6-3build2 Β· Apache-2.0
- ubuntu stonking: libglobus-xio-doc 6.6-4 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms