44#include <StormByte/type_traits/safe.hxx>
47#include <StormByte/byte_size.hxx>
48#include <StormByte/safe/string.hxx>
49#include <StormByte/telemetry.hxx>
50#include <StormByte/type_traits.hxx>
155 bool m_committed {
false};
227 std::atomic<
std::uint64_t> m_rate_bytes;
231 std::atomic<
std::uint64_t> m_op_us;
235 std::atomic<
std::uint64_t> m_mean_rate;
Manual bridge between two StormByte-Buffer ends.
Definition bridge.hxx:129
friend class Bridge
Definition telemetry.hxx:285
StormByte::ByteSize Delivered() const noexcept
Octets delivered to the caller.
ReadTelemetry() noexcept
Construct all counters at 0.
StormByte::ByteSize m_delivered
Octets delivered.
Definition telemetry.hxx:290
operator StormByte::Safe::String() const override
Flatten base read counters.
Measures one operation with an independent Base clock sample.
Definition telemetry.hxx:100
void Commit(StormByte::ByteSize bytes) noexcept
Includes this sample in the rate calculation.
friend class Telemetry
Definition telemetry.hxx:132
OperationSample(OperationSample &&other) noexcept
Transfers the active sample.
~OperationSample() noexcept
Stops the sample and records a committed operation.
OperationSample & operator=(const OperationSample &)=delete
Copy assignment is disabled.
OperationSample & operator=(OperationSample &&)=delete
Move assignment is disabled.
OperationSample(const OperationSample &)=delete
Copy construction is disabled.
virtual ~Telemetry() noexcept
Virtual destructor.
StormByte::ByteSize MeanRate() const noexcept
Effective mean rate of requested user operations.
void RecordOperation(StormByte::ByteSize bytes, std::chrono::microseconds elapsed) noexcept
Accumulate committed bytes and duration from a Base sample.
friend class Bridge
Definition telemetry.hxx:222
OperationSample MeasureOperation() noexcept
Starts an independent measurement on the aggregate operation clock.
Telemetry() noexcept
Construct all counters at 0.
virtual operator StormByte::Safe::String() const =0
Flatten counters.
operator StormByte::Safe::String() const override
Flatten base write counters.
friend class Bridge
Definition telemetry.hxx:340
StormByte::ByteSize Accepted() const noexcept
Octets accepted by a successful write.
WriteTelemetry() noexcept
Construct all counters at 0.
StormByte::ByteSize m_accepted
Octets accepted.
Definition telemetry.hxx:345
class Clock & Clock(std::string_view name)
STORMBYTE_DECLARE_MAYBE_SAFE(class StormByte::System::Device::Access)
Buffer module of the StormByte suite.
Root namespace of the StormByte C++ suite.
#define STORMBYTE_BUFFER_PUBLIC
Definition visibility.h:54