X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-relayd%2Fstream.h;h=a4a6461e69cf218cfa2d573437ada85b12bb3a7d;hp=5e23e7339cf4fcf7495f2ae4825fcdfdd57641d1;hb=348a81dcf7b6944b10a813d93dcaf86fdb5194f6;hpb=2abe796968937298012c0ec668f7fc88305683f2 diff --git a/src/bin/lttng-relayd/stream.h b/src/bin/lttng-relayd/stream.h index 5e23e7339..a4a6461e6 100644 --- a/src/bin/lttng-relayd/stream.h +++ b/src/bin/lttng-relayd/stream.h @@ -26,16 +26,12 @@ #include #include +#include #include "session.h" #include "stream-fd.h" #include "tracefile-array.h" -struct relay_stream_chunk_id { - bool is_set; - uint64_t value; -}; - /* * Represents a stream in the relay */ @@ -175,23 +171,16 @@ struct relay_stream { bool data_rotated; bool index_rotated; /* - * This is the id of the chunk where we are writing to if no rotation is - * pending (rotate_at_seq_num == -1ULL). If a rotation is pending, this - * is the chunk_id we will have after the rotation. It must be updated - * atomically with rotate_at_seq_num. - * - * Always access with stream lock held. - * - * This attribute is not set if the stream is created by a pre-2.11 - * consumer. + * `trace_chunk` is the trace chunk to which the file currently + * being produced (if any) belongs. */ - struct relay_stream_chunk_id current_chunk_id; + struct lttng_trace_chunk *trace_chunk; }; struct relay_stream *stream_create(struct ctf_trace *trace, uint64_t stream_handle, char *path_name, char *channel_name, uint64_t tracefile_size, - uint64_t tracefile_count, const struct relay_stream_chunk_id *chunk_id); + uint64_t tracefile_count); struct relay_stream *stream_get_by_id(uint64_t stream_id); bool stream_get(struct relay_stream *stream);