18 #ifndef PERIODICLOGUPLOADSTRATEGY_HPP_
19 #define PERIODICLOGUPLOADSTRATEGY_HPP_
40 auto now = Clock::now();
43 KAA_LOG_INFO(boost::format(
"Need to upload logs - current count: %llu, lastUploadedTime: %llu, timeLimit: %llu sec")
46 lastUploadTime_ = now;
54 typedef std::chrono::system_clock Clock;
55 std::chrono::time_point<Clock> lastUploadTime_;
PeriodicLogUploadStrategy(std::size_t logUploadCheckReriod, IKaaClientContext &context)
void setLogUploadCheckPeriod(std::size_t period)
The default ILogUploadStrategy implementation.
#define KAA_LOG_INFO(message)
virtual LogUploadStrategyDecision isUploadNeeded(ILogStorageStatus &status) override
Decides whether the log upload is needed.
LogUploadStrategyDecision
Log upload decisions.
virtual std::size_t getRecordsCount()=0
Returns the number of collected logs.
The public interface to represent the current log storage state.
std::size_t logUploadCheckReriod_