rwadurian/backend/services/mining-service/src/infrastructure/persistence
hailin 49949ff979 fix(mining): use unified transaction to prevent timeout errors
- Wrap all database operations in executeSecondDistribution with
  UnitOfWork.executeInTransaction
- Pass transaction client to repository save methods
- Use longer transaction timeout (60s) for batch operations
- Move Redis operations outside transaction (non-ACID)
- Add distributeToSystemAndPendingInTx method that accepts tx client

This resolves the "Unable to start a transaction in the given time"
error caused by multiple concurrent transactions competing for
database connections.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-17 00:31:20 -08:00
..
prisma refactor(frontend): 删除我的页面中的支付密码功能 2026-01-17 00:28:30 -08:00
repositories refactor(frontend): 删除我的页面中的支付密码功能 2026-01-17 00:28:30 -08:00
unit-of-work fix(mining): use unified transaction to prevent timeout errors 2026-01-17 00:31:20 -08:00