hcengineering / hcengineering/platform

If restore could not find a backup it should move to restore-failed

Open
#9,120 1 comment 0 reactions 1 assignee Claimed by @haiodo View on GitHub
Dominant language
TypeScript
Stars
27.7k
Forks
2.2k
PR merge metrics
No merged PRs in 30d

Description

We need to add restore-failed state and in case of multiple errors on restore move workspace into this state.

```plaintext
{"level":"warn","message":"\nRESTORE WORKSPACE ","mode":"restoring","timestamp":"2025-05-28T04:00:21.552Z","workspace":"c43e12ce-867f-422e-a6ac-23af72af4636"}
{"file":"backup.json.gz","level":"error","message":"file not pressent","timestamp":"2025-05-28T04:00:21.711Z"}
{"err":{"message":"backup.json.gz should present to restore","stack":"Error: backup.json.gz should present to restore\n at restore (/usr/src/app/bundle.js:797:16373)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async doRestoreWorkspace (/usr/src/app/bundle.js:787:174)\n at async vur.doRestore (/usr/src/app/bundle.js:800:344300)\n at async vur.doWorkspaceOperation (/usr/src/app/bundle.js:800:342496)\n at async /usr/src/app/bundle.js:800:337133\n at async vur.exec (/usr/src/app/bundle.js:800:337321)"},"level":"error","message":"\n\nFAILED to RESTORE","mode":"restoring","timestamp":"2025-05-28T04:00:21.711Z","workspace":"c43e12ce-867f-422e-a6ac-23af72af4636"}
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.