globus_gra...ol_framing(3)
π globus_gra...ol_framing(3) β Library Functions Manual π
okay bestie, welcome to the <pink>globus_gram_protocol</pink> corner of the manual β this one's literally called Message Framing and it's lowkey the glow-up your GRAM messages have been waiting for β¨
πΈ NAME πΈ
globus_gram_protocol_framing β Message Framing
- Message Framing.
π SYNOPSIS π
Functions
int globus_gram_protocol_frame_request (const char *url, const
globus_byte_t *msg, globus_size_t msgsize, globus_byte_t
**framedmsg, globus_size_t *framedsize)
Create a HTTP-framed copy of a GRAM request.
int globus_gram_protocol_frame_reply (int code, const globus_byte_t
*msg, globus_size_t msgsize, globus_byte_t **framedmsg,
globus_size_t *framedsize)
Create a HTTP-framed copy of a GRAM reply.
π¦ Detailed Description π¦
Message Framing. π
The functions in this section frame a GRAM request, query, or reply message with HTTP headers compatible with the GRAM2 protocol parsers in GT2 GT3, and GT4. no cap, that's the whole point.
These functions should be used when an application wants to control the way that the GRAM Protocol messages are sent, while still using the standard message formatting and framing routines. An alternative set of functions in the Message I/O section of the manual combine message framing with callback-driven I/O. so like, if you want the I/O handled for you with callbacks, that's the other aisle of the manual, iykyk.
π Function Documentation π
int globus_gram_protocol_frame_reply (int code, const globus_byte_t * msg, globus_size_t msgsize, globus_byte_t ** framedmsg, globus_size_t * framedsize)
Create a HTTP-framed copy of a GRAM reply. π The globus_gram_protocol_frame_reply() function adds HTTP 1.1 framing around the input message. The framed message includes HTTP headers relating the the status of the operation being replied to and the length of the message content. The framed message is returned by modifying framedmsg to point to a newly allocated string. The integer pointed to by the framedsize parameter is set to the length of this message.
Parameters
- code β The HTTP response code to send along with this reply.
- msg β A string containing the reply message content to be framed.
- msgsize β The length of the string pointed to by msg.
- framedmsg β An output parameter which will be set to a copy of the msg string with an HTTP reply frame around it.
- framedsize β An output parameter which will be set to the length of the framed reply string pointed to by framedmsg.
Returns
Upon success, globus_gram_protocol_frame_reply() will return GLOBUS_SUCCESS and the framedmsg and framedsize parameters will be modified to point to the new framed message string and its length respectively. When this occurs, the caller is responsible for freeing the string pointed to by framedmsg. π«Ά If an error occurs, its value will returned and the framedmsg and framedsize parameters will be uninitialized.
Return values
GLOBUS_SUCCESSβ Success
int globus_gram_protocol_frame_request (const char * url, const globus_byte_t * msg, globus_size_t msgsize, globus_byte_t ** framedmsg, globus_size_t * framedsize)
Create a HTTP-framed copy of a GRAM request. π¨ The globus_gram_protocol_frame_request() function adds HTTP 1.1 framing around the input message. The framed message includes HTTP headers relating the the destination URL and the length of the message content. The framed message is returned by modifying framedmsg to point to a newly allocated string. The integer pointed to by the framedsize parameter is set to the length of this message.
Parameters
- url β The URL of the GRAM resource to contact. This is parsed and used to generate the HTTP POST operation destination and the Host HTTP header.
- msg β A string containing the message content to be framed.
- msgsize β The length of the string pointed to by msg
- framedmsg β An output parameter which will be set to a copy of the msg string with an HTTP frame around it.
- framedsize β An output parameter which will be set to the length of the framed message.
Returns
Upon success, globus_gram_protocol_frame_request() will return GLOBUS_SUCCESS and the framedmsg and framedsize parameters will be modified to point to the new framed message string and its length respectively. When this occurs, the caller is responsible for freeing the string pointed to by framedmsg. π If an error occurs, its value will returned and the framedmsg and framedsize parameters will be uninitialized.
Return values
GLOBUS_SUCCESSβ SuccessGLOBUS_GRAM_PROTOCOL_ERROR_INVALID_JOB_CONTACTβ Invalid job contact
π Author π
Generated automatically by Doxygen for globus_gram_protocol from the source code. (not me writing my own autobiography, the robot did it π)
and that's the whole page bestie, framing requests and replies like a main character, periodt π β¨
globus_gram_protocol β Version 13.6 β globus_gra...ol_framing(3) π bye ily, go frame something iconic π¦πΈ
π¦ where this page comes from
- epel 10: globus-gram-protocol-doc 13.6-5.el10_0 Β· Apache-2.0
- fedora 43: globus-gram-protocol-doc 13.6-10.fc43 Β· Apache-2.0
- fedora 44: globus-gram-protocol-doc 13.6-11.fc44 Β· Apache-2.0
- ubuntu resolute: libglobus-gram-protocol-doc 13.6-3build2 Β· Apache-2.0
- ubuntu stonking: libglobus-gram-protocol-doc 13.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