Refactor(plug_mgr API): remove session_ctx, provide stellar_mq
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -5,7 +5,7 @@ extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
#include "plugin_manager_interna.h"
|
||||
#include "plugin_manager/plugin_manager_interna.h"
|
||||
|
||||
#include "stellar/session.h"
|
||||
#include "tuple.h"
|
||||
@@ -37,7 +37,7 @@ struct packet
|
||||
|
||||
struct session
|
||||
{
|
||||
struct plugin_manager_runtime *plug_mgr_rt;
|
||||
struct stellar_exdata *session_exdat_rt;
|
||||
enum session_type type;
|
||||
enum session_state state;
|
||||
int sess_pkt_cnt;
|
||||
@@ -54,7 +54,7 @@ int stellar_set_plugin_manger(struct stellar *st, struct plugin_manager_schema *
|
||||
return 0;
|
||||
}
|
||||
|
||||
int stellar_get_worker_thread_num(struct stellar *st)
|
||||
int stellar_get_worker_thread_num(struct stellar *st __attribute__((unused)))
|
||||
{
|
||||
return 16;
|
||||
}
|
||||
@@ -77,12 +77,12 @@ enum session_type session_get_type(const struct session *sess)
|
||||
|
||||
void session_set_user_data(struct session *sess, void *user_data)
|
||||
{
|
||||
sess->plug_mgr_rt = (struct plugin_manager_runtime *)user_data;
|
||||
sess->session_exdat_rt = (struct stellar_exdata *)user_data;
|
||||
}
|
||||
|
||||
void *session_get_user_data(const struct session *sess)
|
||||
{
|
||||
return sess->plug_mgr_rt;
|
||||
return sess->session_exdat_rt;
|
||||
}
|
||||
|
||||
void *packet_get_user_data(const struct packet *pkt)
|
||||
@@ -96,21 +96,11 @@ int packet_get_innermost_tuple6(const struct packet *pkt, struct tuple6 *tuple)
|
||||
return 0;
|
||||
}
|
||||
|
||||
uint8_t packet_is_ctrl(const struct packet *pkt)
|
||||
uint8_t packet_is_ctrl(const struct packet *pkt __attribute__((unused)))
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
struct tcp_segment *session_get_tcp_segment(struct session *sess)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void session_free_tcp_segment(struct session *sess, struct tcp_segment *seg)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
Reference in New Issue
Block a user