X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=src%2Fbin%2Flttng-relayd%2Fsession.h;h=43f76a4aad54eadc7ac3e53f311bab00a748653b;hb=aa91fbc56d63f8d75661a68b68f4052d3c0dba45;hp=2a034daf34e8b448f37fa8f6e301ffe4cd90a119;hpb=ecd1a12fac39784bded85c0f06e47ace2dc98cde;p=lttng-tools.git diff --git a/src/bin/lttng-relayd/session.h b/src/bin/lttng-relayd/session.h index 2a034daf3..43f76a4aa 100644 --- a/src/bin/lttng-relayd/session.h +++ b/src/bin/lttng-relayd/session.h @@ -28,7 +28,7 @@ #include #include -#include +#include #include #include @@ -53,6 +53,7 @@ struct relay_session { */ lttng_uuid sessiond_uuid; LTTNG_OPTIONAL(time_t) creation_time; + /* Must _not_ be empty for 2.4+ peers. */ char session_name[LTTNG_NAME_MAX]; char hostname[LTTNG_HOST_NAME_MAX]; char base_path[LTTNG_PATH_MAX]; @@ -133,6 +134,11 @@ struct relay_session { struct cds_list_head viewer_session_node; struct lttng_trace_chunk *current_trace_chunk; struct lttng_trace_chunk *pending_closure_trace_chunk; + /* + * Prevent live viewers from taking of copy of the chunk + * while new chunk has a temporary directory name. + */ + bool ongoing_rotation; struct rcu_head rcu_node; /* For call_rcu teardown. */ }; @@ -154,6 +160,9 @@ void session_put(struct relay_session *session); int session_close(struct relay_session *session); int session_abort(struct relay_session *session); +struct lttng_directory_handle *session_create_output_directory_handle( + struct relay_session *session); + void print_sessions(void); #endif /* _SESSION_H */