@@ -38,6 +38,7 @@ DownloadShardState::DownloadShardState(BlockIdExt block_id, BlockIdExt mastercha
3838}
3939
4040void DownloadShardState::start_up () {
41+ status_ = ProcessStatus (manager_, " process.download_state" );
4142 alarm_timestamp () = timeout_;
4243
4344 auto P = td::PromiseCreator::lambda ([SelfId = actor_id (this )](td::Result<BlockHandle> R) {
@@ -81,6 +82,7 @@ void DownloadShardState::download_state() {
8182 });
8283 td::actor::send_closure (manager_, &ValidatorManager::send_get_block_proof_link_request, block_id_, priority_,
8384 std::move (P));
85+ status_.set_status (PSTRING () << block_id_.id .to_str () << " : downloading proof" );
8486}
8587
8688void DownloadShardState::downloaded_proof_link (td::BufferSlice data) {
@@ -123,6 +125,7 @@ void DownloadShardState::checked_proof_link() {
123125 td::actor::send_closure (manager_, &ValidatorManager::send_get_persistent_state_request, block_id_,
124126 masterchain_block_id_, priority_, std::move (P));
125127 }
128+ status_.set_status (PSTRING () << block_id_.id .to_str () << " : downloading state" );
126129}
127130
128131void DownloadShardState::download_zero_state () {
@@ -152,6 +155,7 @@ void DownloadShardState::downloaded_zero_state(td::BufferSlice data) {
152155}
153156
154157void DownloadShardState::downloaded_shard_state (td::BufferSlice data) {
158+ status_.set_status (PSTRING () << block_id_.id .to_str () << " : processing downloaded state" );
155159 auto S = create_shard_state (block_id_, data.clone ());
156160 if (S.is_error ()) {
157161 fail_handler (actor_id (this ), S.move_as_error ());
@@ -174,6 +178,7 @@ void DownloadShardState::downloaded_shard_state(td::BufferSlice data) {
174178}
175179
176180void DownloadShardState::checked_shard_state () {
181+ status_.set_status (PSTRING () << block_id_.id .to_str () << " : storing state file" );
177182 LOG (WARNING) << " checked shard state " << block_id_.to_str ();
178183 auto P = td::PromiseCreator::lambda ([SelfId = actor_id (this )](td::Result<td::Unit> R) {
179184 R.ensure ();
@@ -189,6 +194,7 @@ void DownloadShardState::checked_shard_state() {
189194}
190195
191196void DownloadShardState::written_shard_state_file () {
197+ status_.set_status (PSTRING () << block_id_.id .to_str () << " : storing state to celldb" );
192198 LOG (WARNING) << " written shard state file " << block_id_.to_str ();
193199 auto P = td::PromiseCreator::lambda ([SelfId = actor_id (this )](td::Result<td::Ref<ShardState>> R) {
194200 R.ensure ();
@@ -198,6 +204,7 @@ void DownloadShardState::written_shard_state_file() {
198204}
199205
200206void DownloadShardState::written_shard_state (td::Ref<ShardState> state) {
207+ status_.set_status (PSTRING () << block_id_.id .to_str () << " : finishing" );
201208 state_ = std::move (state);
202209 handle_->set_unix_time (state_->get_unix_time ());
203210 handle_->set_is_key_block (block_id_.is_masterchain ());
0 commit comments