FD.io VPP  v18.07.1-19-g511ce25
Vector Packet Processing
application.h File Reference
+ Include dependency graph for application.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define APP_INVALID_INDEX   ((u32)~0)
 
#define APP_NS_INVALID_INDEX   ((u32)~0)
 
#define APP_INVALID_SEGMENT_MANAGER_INDEX   ((u32) ~0)
 

Typedefs

typedef struct _stream_session_cb_vft session_cb_vft_t
 
typedef struct _application application_t
 

Functions

application_tapplication_new ()
 
int application_init (application_t *app, u32 api_client_index, u8 *name, u64 *options, session_cb_vft_t *cb_fns)
 
void application_del (application_t *app)
 
application_tapplication_get (u32 index)
 
application_tapplication_get_if_valid (u32 index)
 
application_tapplication_lookup (u32 api_client_index)
 
application_tapplication_lookup_name (const u8 *name)
 
u32 application_get_index (application_t *app)
 
int application_start_listen (application_t *app, session_endpoint_t *tep, session_handle_t *handle)
 Start listening local transport endpoint for requested transport. More...
 
int application_start_local_listen (application_t *server, session_endpoint_t *sep, session_handle_t *handle)
 
int application_stop_listen (application_t *srv, session_handle_t handle)
 Stop listening on session associated to handle. More...
 
int application_stop_local_listen (application_t *server, session_handle_t listener_handle)
 Clean up local session table. More...
 
int application_open_session (application_t *app, session_endpoint_t *tep, u32 api_context)
 
int application_api_queue_is_full (application_t *app)
 
segment_manager_tapplication_get_listen_segment_manager (application_t *app, stream_session_t *ls)
 
segment_manager_tapplication_get_connect_segment_manager (application_t *app)
 
int application_alloc_connects_segment_manager (application_t *app)
 
int application_is_proxy (application_t *app)
 
int application_is_builtin (application_t *app)
 
int application_is_builtin_proxy (application_t *app)
 
int application_add_segment_notify (u32 app_index, ssvm_private_t *fs)
 Send an API message to the external app, to map new segment. More...
 
u32 application_session_table (application_t *app, u8 fib_proto)
 
u32 application_local_session_table (application_t *app)
 
u8application_name_from_index (u32 app_index)
 Returns app name. More...
 
u8 application_has_local_scope (application_t *app)
 
u8 application_has_global_scope (application_t *app)
 
u32 application_n_listeners (application_t *app)
 
stream_session_tapplication_first_listener (application_t *app, u8 fib_proto, u8 transport_proto)
 
void application_setup_proxy (application_t *app)
 
void application_remove_proxy (application_t *app)
 
segment_manager_properties_tapplication_get_segment_manager_properties (u32 app_index)
 
segment_manager_properties_tapplication_segment_manager_properties (application_t *app)
 
local_session_tapplication_alloc_local_session (application_t *app)
 
void application_free_local_session (application_t *app, local_session_t *ls)
 
local_session_tapplication_get_local_session (application_t *app, u32 session_index)
 
local_session_tapplication_get_local_session_from_handle (session_handle_t handle)
 
int application_local_session_connect (u32 table_index, application_t *client, application_t *server, local_session_t *ll, u32 opaque)
 
int application_local_session_connect_notify (local_session_t *ls)
 
int application_local_session_disconnect (u32 app_index, local_session_t *ls)
 
int application_local_session_disconnect_w_index (u32 app_index, u32 ls_index)
 
void application_local_sessions_del (application_t *app)
 
static u32 local_session_id (local_session_t *ll)
 
static void local_session_parse_id (u32 ls_id, u32 *app_index, u32 *session_index)
 
static void local_session_parse_handle (session_handle_t handle, u32 *server_index, u32 *session_index)
 
static session_handle_t application_local_session_handle (local_session_t *ls)
 
static local_session_tapplication_get_local_listen_session (application_t *app, u32 session_index)
 
static local_session_tapplication_get_local_listener_w_handle (session_handle_t handle)
 
static u8 application_local_session_listener_has_transport (local_session_t *ls)
 
void send_local_session_disconnect_callback (u32 app_index, local_session_t *ls)
 
int application_connect (u32 client_index, u32 api_context, session_endpoint_t *sep)
 
uword unformat_application_proto (unformat_input_t *input, va_list *args)
 

Macro Definition Documentation

#define APP_INVALID_INDEX   ((u32)~0)

Definition at line 135 of file application.h.

#define APP_INVALID_SEGMENT_MANAGER_INDEX   ((u32) ~0)

Definition at line 137 of file application.h.

#define APP_NS_INVALID_INDEX   ((u32)~0)

Definition at line 136 of file application.h.

Typedef Documentation

typedef struct _application application_t
typedef struct _stream_session_cb_vft session_cb_vft_t

Function Documentation

int application_add_segment_notify ( u32  app_index,
ssvm_private_t fs 
)

Send an API message to the external app, to map new segment.

Definition at line 600 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_alloc_connects_segment_manager ( application_t app)

Definition at line 528 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

local_session_t* application_alloc_local_session ( application_t app)

Definition at line 811 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_api_queue_is_full ( application_t app)

Definition at line 85 of file application.c.

+ Here is the call graph for this function:

int application_connect ( u32  client_index,
u32  api_context,
session_endpoint_t sep 
)

Definition at line 241 of file application_interface.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void application_del ( application_t app)

Definition at line 173 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

stream_session_t* application_first_listener ( application_t app,
u8  fib_proto,
u8  transport_proto 
)

Definition at line 625 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void application_free_local_session ( application_t app,
local_session_t ls 
)

Definition at line 823 of file application.c.

+ Here is the caller graph for this function:

application_t* application_get ( u32  index)

Definition at line 386 of file application.c.

+ Here is the caller graph for this function:

segment_manager_t* application_get_connect_segment_manager ( application_t app)

Definition at line 543 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

application_t* application_get_if_valid ( u32  index)

Definition at line 394 of file application.c.

+ Here is the caller graph for this function:

u32 application_get_index ( application_t app)

Definition at line 403 of file application.c.

+ Here is the caller graph for this function:

segment_manager_t* application_get_listen_segment_manager ( application_t app,
stream_session_t ls 
)

Definition at line 550 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static local_session_t* application_get_local_listen_session ( application_t app,
u32  session_index 
)
inlinestatic

Definition at line 242 of file application.h.

+ Here is the caller graph for this function:

static local_session_t* application_get_local_listener_w_handle ( session_handle_t  handle)
inlinestatic

Definition at line 248 of file application.h.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

local_session_t* application_get_local_session ( application_t app,
u32  session_index 
)

Definition at line 831 of file application.c.

+ Here is the caller graph for this function:

local_session_t* application_get_local_session_from_handle ( session_handle_t  handle)

Definition at line 837 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

segment_manager_properties_t* application_get_segment_manager_properties ( u32  app_index)

Definition at line 804 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u8 application_has_global_scope ( application_t app)

Definition at line 613 of file application.c.

+ Here is the caller graph for this function:

u8 application_has_local_scope ( application_t app)

Definition at line 607 of file application.c.

+ Here is the caller graph for this function:

int application_init ( application_t app,
u32  api_client_index,
u8 name,
u64 options,
session_cb_vft_t cb_fns 
)

Definition at line 291 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_is_builtin ( application_t app)

Definition at line 585 of file application.c.

+ Here is the caller graph for this function:

int application_is_builtin_proxy ( application_t app)

Definition at line 591 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_is_proxy ( application_t app)

Definition at line 579 of file application.c.

+ Here is the caller graph for this function:

int application_local_session_connect ( u32  table_index,
application_t client,
application_t server,
local_session_t ll,
u32  opaque 
)

Definition at line 942 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_local_session_connect_notify ( local_session_t ls)

Definition at line 1048 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_local_session_disconnect ( u32  app_index,
local_session_t ls 
)

Definition at line 1121 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_local_session_disconnect_w_index ( u32  app_index,
u32  ls_index 
)

Definition at line 1162 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static session_handle_t application_local_session_handle ( local_session_t ls)
inlinestatic

Definition at line 235 of file application.h.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static u8 application_local_session_listener_has_transport ( local_session_t ls)
inlinestatic

Definition at line 258 of file application.h.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 application_local_session_table ( application_t app)

Definition at line 75 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void application_local_sessions_del ( application_t app)

Definition at line 1172 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

application_t* application_lookup ( u32  api_client_index)

Definition at line 136 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

application_t* application_lookup_name ( const u8 name)

Definition at line 147 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 application_n_listeners ( application_t app)

Definition at line 619 of file application.c.

+ Here is the call graph for this function:

u8* application_name_from_index ( u32  app_index)

Returns app name.

Since the name is not stored per app, we generate it on the fly. It is the caller's responsibility to free the vector

Definition at line 109 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

application_t* application_new ( )

Definition at line 158 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_open_session ( application_t app,
session_endpoint_t tep,
u32  api_context 
)

Definition at line 513 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void application_remove_proxy ( application_t app)

Definition at line 782 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

segment_manager_properties_t* application_segment_manager_properties ( application_t app)

Definition at line 798 of file application.c.

+ Here is the caller graph for this function:

u32 application_session_table ( application_t app,
u8  fib_proto 
)

Definition at line 60 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void application_setup_proxy ( application_t app)

Definition at line 766 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_start_listen ( application_t srv,
session_endpoint_t sep,
session_handle_t res 
)

Start listening local transport endpoint for requested transport.

Creates a 'dummy' stream session with state LISTENING to be used in session lookups, prior to establishing connection. Requests transport to build it's own specific listening connection.

Definition at line 436 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_start_local_listen ( application_t server,
session_endpoint_t sep,
session_handle_t handle 
)

Definition at line 857 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_stop_listen ( application_t srv,
session_handle_t  handle 
)

Stop listening on session associated to handle.

Definition at line 477 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

int application_stop_local_listen ( application_t server,
session_handle_t  lh 
)

Clean up local session table.

If we have a listener session use it to find the port and proto. If not, the handle must be a local table handle so parse it.

Definition at line 895 of file application.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static u32 local_session_id ( local_session_t ll)
inlinestatic

Definition at line 211 of file application.h.

+ Here is the caller graph for this function:

static void local_session_parse_handle ( session_handle_t  handle,
u32 server_index,
u32 session_index 
)
inlinestatic

Definition at line 225 of file application.h.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void local_session_parse_id ( u32  ls_id,
u32 app_index,
u32 session_index 
)
inlinestatic

Definition at line 218 of file application.h.

+ Here is the caller graph for this function:

void send_local_session_disconnect_callback ( u32  app_index,
local_session_t ls 
)

Definition at line 232 of file session_api.c.

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

uword unformat_application_proto ( unformat_input_t input,
va_list *  args 
)

+ Here is the caller graph for this function: