refactor(api): compose research services with narrow collaborators (CL28)
This commit is contained in:
parent
3a63b2039e
commit
24487d35da
28 changed files with 281 additions and 94 deletions
|
|
@ -9,7 +9,7 @@ import { BacktestRunner } from '../../apps/stock/orchestrator/src/backtest/Backt
|
|||
import { PostgresBacktestRunRepository } from '../../apps/stock/orchestrator/src/backtest/PostgresBacktestRunRepository';
|
||||
import { RustBacktestAdapter } from '../../apps/stock/orchestrator/src/backtest/RustBacktestAdapter';
|
||||
import { BacktestServiceV2 } from '../../apps/stock/web-api/src/services/backtest-v2.service';
|
||||
import { ResearchService } from '../../apps/stock/web-api/src/services/research.service';
|
||||
import { createResearchServices } from '../../apps/stock/web-api/src/services/research-services';
|
||||
import { StrategyCatalogService } from '../../apps/stock/web-api/src/services/strategy-catalog.service';
|
||||
import { retainResearchDataset } from '../../scripts/import-research-dataset';
|
||||
import { packageBuiltinStrategies } from '../../scripts/package-builtin-strategies';
|
||||
|
|
@ -81,7 +81,7 @@ async function fixture(applyWorkspace = true, maxConnections = 10) {
|
|||
Object.defineProperty(postgres, 'connectionPool', { get: () => pool });
|
||||
Object.defineProperty(postgres, 'query', { value: pool.query.bind(pool) });
|
||||
const container = { postgres, logger };
|
||||
const service = new ResearchService(container);
|
||||
const service = createResearchServices(container).research;
|
||||
const backtests = new BacktestServiceV2(container);
|
||||
const catalog = new StrategyCatalogService(container);
|
||||
const legacy = async (status = 'completed') => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue