consumerd: Implement clear stream/session commands
[lttng-tools.git] / src / common / consumer / consumer.h
index b8d45cef154166ff657cd93ee735ad9c34570d22..907aecf225e71ffde1e4f592e6b52091b8c93f15 100644 (file)
@@ -62,6 +62,8 @@ enum lttng_consumer_command {
        LTTNG_CONSUMER_LOST_PACKETS,
        LTTNG_CONSUMER_CLEAR_QUIESCENT_CHANNEL,
        LTTNG_CONSUMER_SET_CHANNEL_MONITOR_PIPE,
+       LTTNG_CONSUMER_CLEAR_CHANNEL,
+       LTTNG_CONSUMER_CLEAR_SESSION,
 };
 
 /* State of each fd in consumer */
@@ -429,7 +431,7 @@ struct consumer_relayd_sock_pair {
        /* Network sequence number. */
        uint64_t net_seq_idx;
        /* Number of stream associated with this relayd */
-       unsigned int refcount;
+       int refcount;
 
        /*
         * This flag indicates whether or not we should destroy this object. The
@@ -463,6 +465,7 @@ struct consumer_relayd_sock_pair {
        /* Session id on both sides for the sockets. */
        uint64_t relayd_session_id;
        uint64_t sessiond_session_id;
+       struct lttng_consumer_local_data *ctx;
 };
 
 /*
@@ -753,5 +756,8 @@ void consumer_del_stream_for_data(struct lttng_consumer_stream *stream);
 int consumer_add_metadata_stream(struct lttng_consumer_stream *stream);
 void consumer_del_stream_for_metadata(struct lttng_consumer_stream *stream);
 int consumer_create_index_file(struct lttng_consumer_stream *stream);
+void lttng_consumer_cleanup_relayd(struct consumer_relayd_sock_pair *relayd);
+int lttng_consumer_clear_channel(struct lttng_consumer_channel *channel);
+int lttng_consumer_clear_session(uint64_t session_id);
 
 #endif /* LIB_CONSUMER_H */
This page took 0.02488 seconds and 5 git commands to generate.