rotating_file_creator.h 534 B

123456789101112131415161718
  1. #pragma once
  2. #include "file_creator.h"
  3. class TRotatingFileLogBackendCreator : public TFileLogBackendCreator {
  4. public:
  5. TRotatingFileLogBackendCreator();
  6. virtual bool Init(const IInitContext& ctx) override;
  7. static TFactory::TRegistrator<TRotatingFileLogBackendCreator> Registrar;
  8. protected:
  9. virtual void DoToJson(NJson::TJsonValue& value) const override;
  10. private:
  11. virtual THolder<TLogBackend> DoCreateLogBackend() const override;
  12. ui64 MaxSizeBytes = Max<ui64>();
  13. ui64 RotatedFilesCount = Max<ui64>();
  14. };