Classes | Macros | Enumerations | Functions
proxy.cpp File Reference
#include "precompiled.hpp"
#include <stddef.h>
#include "poller.hpp"
#include "proxy.hpp"
#include "likely.hpp"
#include "msg.hpp"
#include "socket_base.hpp"
#include "err.hpp"
#include "socket_poller.hpp"
Include dependency graph for proxy.cpp:

Go to the source code of this file.

Classes

struct  stats_endpoint
 
struct  stats_proxy
 
struct  stats_socket
 

Macros

#define CHECK_RC_EXIT_ON_FAILURE()
 
#define PROXY_CLEANUP()
 

Enumerations

enum  proxy_state_t { active, paused, terminated }
 

Functions

static int capture (class zmq::socket_base_t *capture_, zmq::msg_t *msg_, int more_=0)
 
static int forward (class zmq::socket_base_t *from_, class zmq::socket_base_t *to_, class zmq::socket_base_t *capture_, zmq::msg_t *msg_, stats_socket &recving, stats_socket &sending)
 
static int handle_control (class zmq::socket_base_t *control_, proxy_state_t &state, const stats_proxy &stats)
 

Macro Definition Documentation

◆ CHECK_RC_EXIT_ON_FAILURE

#define CHECK_RC_EXIT_ON_FAILURE ( )
Value:
do { \
if (rc < 0) { \
PROXY_CLEANUP (); \
return close_and_return (&msg, -1); \
} \
} while (false)

Definition at line 47 of file proxy.cpp.

◆ PROXY_CLEANUP

#define PROXY_CLEANUP ( )
Value:
do { \
delete poller_all; \
delete poller_in; \
delete poller_receive_blocked; \
delete poller_send_blocked; \
delete poller_both_blocked; \
delete poller_frontend_only; \
delete poller_backend_only; \
} while (false)

Definition at line 35 of file proxy.cpp.

Enumeration Type Documentation

◆ proxy_state_t

Enumerator
active 
paused 
terminated 

Definition at line 139 of file proxy.cpp.

Function Documentation

◆ capture()

static int capture ( class zmq::socket_base_t capture_,
zmq::msg_t msg_,
int  more_ = 0 
)
static

Definition at line 58 of file proxy.cpp.

◆ forward()

static int forward ( class zmq::socket_base_t from_,
class zmq::socket_base_t to_,
class zmq::socket_base_t capture_,
zmq::msg_t msg_,
stats_socket recving,
stats_socket sending 
)
static

Definition at line 89 of file proxy.cpp.

◆ handle_control()

static int handle_control ( class zmq::socket_base_t control_,
proxy_state_t state,
const stats_proxy stats 
)
static

Definition at line 148 of file proxy.cpp.

zmq::close_and_return
int close_and_return(zmq::msg_t *msg_, int echo_)
Definition: msg.hpp:300


libaditof
Author(s):
autogenerated on Wed May 21 2025 02:07:04