Skip to content

Commit

Permalink
Merge pull request #195 from utxostack/feat/worker
Browse files Browse the repository at this point in the history
feat: enable worker threads
  • Loading branch information
ahonn authored Sep 25, 2024
2 parents 395ed1d + 21c551a commit bc641cd
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion backend/src/core/indexer/processor/assets.processor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ export interface IndexerAssetsJobData {
const BATCH_SIZE = BI.from(400).toHexString();

@Processor(INDEXER_ASSETS_QUEUE, {
concurrency: 100,
stalledInterval: 60_000,
useWorkerThreads: true,
})
export class IndexerAssetsProcessor extends WorkerHost {
private logger = new Logger(IndexerAssetsProcessor.name);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ export interface IndexerBlockAssetsJobData {
}

@Processor(INDEXER_BLOCK_ASSETS_QUEUE, {
concurrency: 100,
stalledInterval: 60_000,
useWorkerThreads: true,
})
export class IndexerBlockAssetsProcessor extends WorkerHost {
private logger = new Logger(IndexerBlockAssetsProcessor.name);
Expand Down
2 changes: 1 addition & 1 deletion backend/src/core/indexer/processor/block.processor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ export interface IndexerBlockJobData {
}

@Processor(INDEXER_BLOCK_QUEUE, {
concurrency: 100,
stalledInterval: 60_000,
useWorkerThreads: true,
})
export class IndexerBlockProcessor extends WorkerHost {
private logger = new Logger(IndexerBlockProcessor.name);
Expand Down
2 changes: 1 addition & 1 deletion backend/src/core/indexer/processor/lock.processor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ class IndexerLockError extends Error {
}

@Processor(INDEXER_LOCK_QUEUE, {
concurrency: 100,
stalledInterval: 60_000,
useWorkerThreads: true,
})
export class IndexerLockProcessor extends WorkerHost {
private logger = new Logger(IndexerLockProcessor.name);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ export interface IndexerTransactionJobData {
}

@Processor(INDEXER_TRANSACTION_QUEUE, {
concurrency: 100,
stalledInterval: 60_000,
useWorkerThreads: true,
})
export class IndexerTransactionProcessor extends WorkerHost {
private logger = new Logger(IndexerTransactionProcessor.name);
Expand Down
2 changes: 1 addition & 1 deletion backend/src/core/indexer/processor/type.processor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ export interface IndexerTypeJobData {
}

@Processor(INDEXER_TYPE_QUEUE, {
concurrency: 100,
stalledInterval: 60_000,
useWorkerThreads: true,
})
export class IndexerTypeProcessor extends WorkerHost {
private logger = new Logger(IndexerTypeProcessor.name);
Expand Down

0 comments on commit bc641cd

Please sign in to comment.