GNUnet  0.19.5
GNUNET_ATS_Session Struct Reference

Session handle for connections. More...

#include </home/buildbot/bb-worker/worker/gnunet_firefly/build/src/transport/plugin_transport_http.h>

Collaboration diagram for GNUNET_ATS_Session:
[legend]

Data Fields

struct GNUNET_PeerIdentity target
 To whom are we talking to. More...
 
struct GNUNET_ATS_Sessionnext
 Stored in a linked list. More...
 
struct GNUNET_ATS_Sessionprev
 Stored in a linked list. More...
 
struct Pluginplugin
 Pointer to the global plugin struct. More...
 
void * addr
 Address. More...
 
size_t addrlen
 Address length. More...
 
uint32_t ats_address_network_type
 ATS network type in NBO. More...
 
struct HTTP_Messagemsg_head
 next pointer for double linked list More...
 
struct HTTP_Messagemsg_tail
 previous pointer for double linked list More...
 
struct GNUNET_SERVER_MessageStreamTokenizermsg_tk
 Message stream tokenizer for incoming data. More...
 
struct GNUNET_TIME_Absolute next_receive
 Absolute time when to receive data again Used for receive throttling. More...
 
int inbound
 Inbound or outbound connection Outbound: GNUNET_NO (client is used to send and receive) Inbound : GNUNET_YES (server is used to send and receive) More...
 
uint32_t tag
 Unique HTTP/S connection tag for this connection. More...
 
void * client_put
 Client send handle. More...
 
void * client_get
 Client receive handle. More...
 
struct GNUNET_SCHEDULER_Taskrecv_wakeup_task
 Task to wake up client receive handle when receiving is allowed again. More...
 
struct GNUNET_SCHEDULER_Tasktimeout_task
 Session timeout task. More...
 
int client_put_paused
 Is client send handle paused since there are no data to send? GNUNET_YES or GNUNET_NO. More...
 
struct ServerRequestserver_recv
 Client send handle. More...
 
struct ServerRequestserver_send
 Client send handle. More...
 
char * url
 The URL to connect to. More...
 
struct GNUNET_HELLO_Addressaddress
 Address. More...
 
struct HTTP_Client_Pluginplugin
 Pointer to the global plugin struct. More...
 
struct RequestHandle put
 Handle for the HTTP PUT request. More...
 
struct RequestHandle get
 Handle for the HTTP GET request. More...
 
struct GNUNET_MessageStreamTokenizermsg_tk
 Message stream tokenizer for incoming data. More...
 
struct GNUNET_SCHEDULER_Taskput_disconnect_task
 Session timeout task. More...
 
struct GNUNET_TIME_Absolute timeout
 When does this session time out. More...
 
unsigned long long bytes_in_queue
 Number of bytes waiting for transmission to this peer. More...
 
size_t overhead
 Outbound overhead due to HTTP connection Add to next message of this session when calling callback. More...
 
unsigned int msgs_in_queue
 Number of messages waiting for transmission to this peer. More...
 
enum GNUNET_NetworkType scope
 ATS network type. More...
 
struct HTTP_Server_Pluginplugin
 Pointer to the global plugin struct. More...
 
int known_to_service
 GNUNET_YES if this session is known to the service. More...
 
struct GNUNET_SERVER_Clientclient
 The client (used to identify this connection) More...
 
struct GNUNET_SCHEDULER_Tasknat_connection_timeout
 Task cleaning up a NAT client connection establishment attempt;. More...
 
struct PendingMessagepending_messages_head
 Messages currently pending for transmission to this peer, if any. More...
 
struct PendingMessagepending_messages_tail
 Messages currently pending for transmission to this peer, if any. More...
 
struct GNUNET_SERVER_TransmitHandletransmit_handle
 Handle for pending transmission request. More...
 
struct GNUNET_SCHEDULER_Taskreceive_delay_task
 ID of task used to delay receiving more to throttle sender. More...
 
struct GNUNET_TIME_Absolute receive_delay
 When will we continue to read from the socket? (used to enforce inbound quota). More...
 
struct GNUNET_TIME_Absolute last_activity
 Last activity on this connection. More...
 
int expecting_welcome
 Are we still expecting the welcome message? (GNUNET_YES/GNUNET_NO) More...
 
int is_nat
 Was this session created using NAT traversal? More...
 
struct GNUNET_PeerIdentity sender
 To whom are we talking to (set to our identity if we are still waiting for the welcome message) More...
 
GNUNET_TRANSPORT_TransmitContinuation transmit_cont
 The client (used to identify this connection) More...
 
void * transmit_cont_cls
 Closure for transmit_cont. More...
 
struct GNUNET_TIME_Absolute last_quota_update
 At what time did we reset last_received last? More...
 
uint64_t last_received
 How many bytes have we received since the last_quota_update timestamp? More...
 
uint32_t quota
 Number of bytes per ms that this peer is allowed to send to us. More...
 
struct GNUNET_MessageStreamTokenizermst
 Tokenizer for inbound messages. More...
 
struct UDP_FragmentationContextfrag_ctx
 Context for dealing with fragments. More...
 
struct GNUNET_TIME_Relative flow_delay_for_other_peer
 Desired delay for next sending we send to other peer. More...
 
struct GNUNET_TIME_Relative flow_delay_from_other_peer
 Desired delay for transmissions we received from other peer. More...
 
struct GNUNET_TIME_Absolute last_transmit_time
 What time did we last transmit? More...
 
struct GNUNET_TIME_Relative last_expected_ack_delay
 expected delay for ACKs More...
 
struct GNUNET_TIME_Relative last_expected_msg_delay
 desired delay between UDP messages More...
 
unsigned int rc
 Reference counter to indicate that this session is currently being used and must not be destroyed; setting in_destroy will destroy it as soon as possible. More...
 
int in_destroy
 Is this session about to be destroyed (sometimes we cannot destroy a session immediately as below us on the stack there might be code that still uses it; in this case, rc is non-zero). More...
 
struct MacEndpointmac
 MAC endpoint with the address of this peer. More...
 

Detailed Description

Session handle for connections.

Session handle for connections with other peers.

Handle for a session.

Session with another peer.

Session handle for TCP connections.

Definition at line 347 of file plugin_transport_http.h.

Field Documentation

◆ target

◆ next

struct GNUNET_ATS_Session * GNUNET_ATS_Session::next

Stored in a linked list.

We keep all sessions in a DLL at their respective struct MACEndpoint *.

Sessions with pending messages (!) are kept in a DLL.

Stored in a linked list (or a peer map, or ...)

Definition at line 357 of file plugin_transport_http.h.

Referenced by lookup_session(), wlan_plugin_disconnect_peer(), and wlan_plugin_setup_monitor().

◆ prev

struct GNUNET_ATS_Session * GNUNET_ATS_Session::prev

Stored in a linked list.

We keep all sessions in a DLL at their respective struct MACEndpoint *.

Sessions with pending messages (!) are kept in a DLL.

Definition at line 362 of file plugin_transport_http.h.

◆ plugin [1/3]

◆ addr

void* GNUNET_ATS_Session::addr

Address.

Definition at line 372 of file plugin_transport_http.h.

◆ addrlen

size_t GNUNET_ATS_Session::addrlen

Address length.

Definition at line 377 of file plugin_transport_http.h.

◆ ats_address_network_type

uint32_t GNUNET_ATS_Session::ats_address_network_type

ATS network type in NBO.

Definition at line 382 of file plugin_transport_http.h.

◆ msg_head

struct HTTP_Message * GNUNET_ATS_Session::msg_head

◆ msg_tail

struct HTTP_Message * GNUNET_ATS_Session::msg_tail

◆ msg_tk [1/2]

struct GNUNET_MessageStreamTokenizer * GNUNET_ATS_Session::msg_tk

Message stream tokenizer for incoming data.

Definition at line 397 of file plugin_transport_http.h.

Referenced by client_delete_session(), client_receive(), server_access_cb(), and server_delete_session().

◆ next_receive

struct GNUNET_TIME_Absolute GNUNET_ATS_Session::next_receive

Absolute time when to receive data again Used for receive throttling.

Absolute time when to receive data again.

Used for receive throttling.

Definition at line 397 of file plugin_transport_http.h.

Referenced by client_receive(), client_receive_mst_cb(), http_client_plugin_update_inbound_delay(), http_server_plugin_update_inbound_delay(), notify_session_monitor(), server_access_cb(), server_lookup_connection(), and server_receive_mst_cb().

◆ inbound

int GNUNET_ATS_Session::inbound

Inbound or outbound connection Outbound: GNUNET_NO (client is used to send and receive) Inbound : GNUNET_YES (server is used to send and receive)

Definition at line 410 of file plugin_transport_http.h.

◆ tag

uint32_t GNUNET_ATS_Session::tag

Unique HTTP/S connection tag for this connection.

Definition at line 415 of file plugin_transport_http.h.

Referenced by server_lookup_connection(), and session_tag_it().

◆ client_put

void* GNUNET_ATS_Session::client_put

Client send handle.

Definition at line 420 of file plugin_transport_http.h.

◆ client_get

void* GNUNET_ATS_Session::client_get

Client receive handle.

Definition at line 425 of file plugin_transport_http.h.

◆ recv_wakeup_task

struct GNUNET_SCHEDULER_Task * GNUNET_ATS_Session::recv_wakeup_task

Task to wake up client receive handle when receiving is allowed again.

Task to resume MHD handling when receiving is allowed again.

Definition at line 430 of file plugin_transport_http.h.

Referenced by client_delete_session(), client_receive(), client_wake_up(), http_client_plugin_update_inbound_delay(), http_server_plugin_update_inbound_delay(), server_access_cb(), server_delete_session(), and server_wake_up().

◆ timeout_task

◆ client_put_paused

int GNUNET_ATS_Session::client_put_paused

Is client send handle paused since there are no data to send? GNUNET_YES or GNUNET_NO.

Definition at line 441 of file plugin_transport_http.h.

◆ server_recv

struct ServerRequest * GNUNET_ATS_Session::server_recv

◆ server_send

◆ url

char* GNUNET_ATS_Session::url

◆ address

◆ plugin [2/3]

struct HTTP_Client_Plugin* GNUNET_ATS_Session::plugin

Pointer to the global plugin struct.

Definition at line 200 of file plugin_transport_http_client.c.

◆ put

◆ get

struct RequestHandle GNUNET_ATS_Session::get

Handle for the HTTP GET request.

Definition at line 200 of file plugin_transport_http_client.c.

Referenced by client_connect(), client_connect_get(), client_delete_session(), client_receive(), client_run(), and client_wake_up().

◆ msg_tk [2/2]

struct GNUNET_MessageStreamTokenizer* GNUNET_ATS_Session::msg_tk

Message stream tokenizer for incoming data.

Definition at line 225 of file plugin_transport_http_client.c.

◆ put_disconnect_task

struct GNUNET_SCHEDULER_Task* GNUNET_ATS_Session::put_disconnect_task

◆ timeout

◆ bytes_in_queue

◆ overhead

size_t GNUNET_ATS_Session::overhead

Outbound overhead due to HTTP connection Add to next message of this session when calling callback.

Definition at line 262 of file plugin_transport_http_client.c.

Referenced by client_delete_session(), and client_send_cb().

◆ msgs_in_queue

◆ scope

◆ plugin [3/3]

struct HTTP_Server_Plugin* GNUNET_ATS_Session::plugin

Pointer to the global plugin struct.

Definition at line 197 of file plugin_transport_http_server.c.

◆ known_to_service

int GNUNET_ATS_Session::known_to_service

GNUNET_YES if this session is known to the service.

Definition at line 273 of file plugin_transport_http_server.c.

Referenced by server_delete_session(), server_lookup_connection(), and server_receive_mst_cb().

◆ client

struct GNUNET_SERVER_Client* GNUNET_ATS_Session::client

◆ nat_connection_timeout

struct GNUNET_SCHEDULER_Task* GNUNET_ATS_Session::nat_connection_timeout

Task cleaning up a NAT client connection establishment attempt;.

Definition at line 782 of file plugin_transport_tcp.c.

Referenced by handle_tcp_nat_probe(), nat_connect_timeout(), tcp_plugin_disconnect_session(), and tcp_plugin_get_session().

◆ pending_messages_head

struct PendingMessage* GNUNET_ATS_Session::pending_messages_head

Messages currently pending for transmission to this peer, if any.

Definition at line 788 of file plugin_transport_tcp.c.

Referenced by create_session(), do_transmit(), process_pending_messages(), tcp_plugin_disconnect_session(), and tcp_plugin_send().

◆ pending_messages_tail

struct PendingMessage* GNUNET_ATS_Session::pending_messages_tail

Messages currently pending for transmission to this peer, if any.

Definition at line 794 of file plugin_transport_tcp.c.

Referenced by create_session(), do_transmit(), tcp_plugin_disconnect_session(), and tcp_plugin_send().

◆ transmit_handle

struct GNUNET_SERVER_TransmitHandle* GNUNET_ATS_Session::transmit_handle

Handle for pending transmission request.

Definition at line 799 of file plugin_transport_tcp.c.

Referenced by do_transmit(), process_pending_messages(), and tcp_plugin_disconnect_session().

◆ receive_delay_task

struct GNUNET_SCHEDULER_Task* GNUNET_ATS_Session::receive_delay_task

ID of task used to delay receiving more to throttle sender.

Definition at line 809 of file plugin_transport_tcp.c.

Referenced by delayed_done(), handle_tcp_data(), notify_session_monitor(), tcp_plugin_disconnect_session(), and tcp_plugin_update_inbound_delay().

◆ receive_delay

struct GNUNET_TIME_Absolute GNUNET_ATS_Session::receive_delay

When will we continue to read from the socket? (used to enforce inbound quota).

Definition at line 814 of file plugin_transport_tcp.c.

Referenced by notify_session_monitor(), and tcp_plugin_update_inbound_delay().

◆ last_activity

struct GNUNET_TIME_Absolute GNUNET_ATS_Session::last_activity

Last activity on this connection.

Used to select preferred connection.

Definition at line 814 of file plugin_transport_tcp.c.

Referenced by create_session(), do_transmit(), handle_tcp_data(), handle_tcp_nat_probe(), and handle_tcp_welcome().

◆ expecting_welcome

int GNUNET_ATS_Session::expecting_welcome

Are we still expecting the welcome message? (GNUNET_YES/GNUNET_NO)

Definition at line 851 of file plugin_transport_tcp.c.

Referenced by create_session(), handle_tcp_data(), and handle_tcp_welcome().

◆ is_nat

int GNUNET_ATS_Session::is_nat

Was this session created using NAT traversal?

Definition at line 856 of file plugin_transport_tcp.c.

Referenced by create_session().

◆ sender

struct GNUNET_PeerIdentity GNUNET_ATS_Session::sender

To whom are we talking to (set to our identity if we are still waiting for the welcome message)

Definition at line 554 of file plugin_transport_template.c.

◆ transmit_cont

GNUNET_TRANSPORT_TransmitContinuation GNUNET_ATS_Session::transmit_cont

The client (used to identify this connection)

Continuation function to call once the transmission buffer has again space available. NULL if there is no continuation to call.

Definition at line 83 of file plugin_transport_template.c.

◆ transmit_cont_cls

void* GNUNET_ATS_Session::transmit_cont_cls

Closure for transmit_cont.

Definition at line 88 of file plugin_transport_template.c.

◆ last_quota_update

struct GNUNET_TIME_Absolute GNUNET_ATS_Session::last_quota_update

At what time did we reset last_received last?

Definition at line 88 of file plugin_transport_template.c.

◆ last_received

uint64_t GNUNET_ATS_Session::last_received

How many bytes have we received since the last_quota_update timestamp?

Definition at line 99 of file plugin_transport_template.c.

◆ quota

uint32_t GNUNET_ATS_Session::quota

Number of bytes per ms that this peer is allowed to send to us.

Definition at line 105 of file plugin_transport_template.c.

◆ mst

struct GNUNET_MessageStreamTokenizer* GNUNET_ATS_Session::mst

Tokenizer for inbound messages.

Definition at line 163 of file plugin_transport_udp.c.

Referenced by free_session(), process_udp_message(), and udp_plugin_create_session().

◆ frag_ctx

struct UDP_FragmentationContext* GNUNET_ATS_Session::frag_ctx

◆ flow_delay_for_other_peer

struct GNUNET_TIME_Relative GNUNET_ATS_Session::flow_delay_for_other_peer

Desired delay for next sending we send to other peer.

Definition at line 173 of file plugin_transport_udp.c.

Referenced by ack_proc(), process_inbound_tokenized_messages(), and udp_plugin_create_session().

◆ flow_delay_from_other_peer

struct GNUNET_TIME_Relative GNUNET_ATS_Session::flow_delay_from_other_peer

Desired delay for transmissions we received from other peer.

This is for full messages, the value needs to be adjusted for fragmented messages.

Definition at line 173 of file plugin_transport_udp.c.

Referenced by read_process_ack(), udp_plugin_create_session(), and udp_plugin_send().

◆ last_transmit_time

struct GNUNET_TIME_Absolute GNUNET_ATS_Session::last_transmit_time

What time did we last transmit?

Definition at line 190 of file plugin_transport_udp.c.

Referenced by udp_plugin_create_session(), udp_plugin_send(), and udp_select_send().

◆ last_expected_ack_delay

struct GNUNET_TIME_Relative GNUNET_ATS_Session::last_expected_ack_delay

expected delay for ACKs

Definition at line 190 of file plugin_transport_udp.c.

Referenced by fragmented_message_done(), udp_plugin_create_session(), and udp_plugin_send().

◆ last_expected_msg_delay

struct GNUNET_TIME_Relative GNUNET_ATS_Session::last_expected_msg_delay

desired delay between UDP messages

Definition at line 190 of file plugin_transport_udp.c.

Referenced by fragmented_message_done(), udp_plugin_create_session(), and udp_plugin_send().

◆ rc

unsigned int GNUNET_ATS_Session::rc

Reference counter to indicate that this session is currently being used and must not be destroyed; setting in_destroy will destroy it as soon as possible.

Definition at line 233 of file plugin_transport_udp.c.

Referenced by process_udp_message(), and udp_disconnect_session().

◆ in_destroy

int GNUNET_ATS_Session::in_destroy

Is this session about to be destroyed (sometimes we cannot destroy a session immediately as below us on the stack there might be code that still uses it; in this case, rc is non-zero).

Definition at line 246 of file plugin_transport_udp.c.

Referenced by enqueue(), notify_session_monitor(), process_inbound_tokenized_messages(), process_udp_message(), reschedule_session_timeout(), session_cmp_it(), and udp_disconnect_session().

◆ mac

struct MacEndpoint* GNUNET_ATS_Session::mac

MAC endpoint with the address of this peer.

Definition at line 277 of file plugin_transport_wlan.c.

Referenced by create_session(), session_timeout(), wlan_plugin_disconnect_session(), wlan_plugin_send(), and wlan_plugin_setup_monitor().


The documentation for this struct was generated from the following files: