blob_depot_tablet.h 886 B

123456789101112131415161718192021222324252627282930313233343536
  1. #pragma once
  2. #include "defs.h"
  3. namespace NKikimr::NBlobDepot {
  4. using NTabletFlatExecutor::TTabletExecutedFlat;
  5. class TBlobDepot
  6. : public TActor<TBlobDepot>
  7. , public TTabletExecutedFlat
  8. {
  9. public:
  10. TBlobDepot(TActorId tablet, TTabletStorageInfo *info)
  11. : TActor(&TThis::StateFunc)
  12. , TTabletExecutedFlat(info, tablet, new NMiniKQL::TMiniKQLFactory)
  13. {}
  14. void OnActivateExecutor(const TActorContext&) override
  15. {}
  16. void OnDetach(const TActorContext&) override {
  17. // TODO: what does this callback mean
  18. PassAway();
  19. }
  20. void OnTabletDead(TEvTablet::TEvTabletDead::TPtr& /*ev*/, const TActorContext&) override {
  21. PassAway();
  22. }
  23. STFUNC(StateFunc) {
  24. HandleDefaultEvents(ev, ctx);
  25. }
  26. };
  27. } // NKikimr::NBlobDepot