huge refactor done
This commit is contained in:
parent
843a7b9b9b
commit
60d7de1da8
16 changed files with 472 additions and 443 deletions
22
test-queue.ts
Normal file
22
test-queue.ts
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
import { Queue } from 'bullmq';
|
||||
|
||||
const queue = new Queue('{data-ingestion_ceo}', {
|
||||
connection: {
|
||||
host: 'localhost',
|
||||
port: 6379,
|
||||
db: 0,
|
||||
},
|
||||
});
|
||||
|
||||
async function testJob() {
|
||||
const job = await queue.add('fetchCompany', {
|
||||
handler: 'ceo',
|
||||
operation: 'fetchCompany',
|
||||
payload: { symbol: 'AAPL' },
|
||||
});
|
||||
|
||||
console.log('Job added:', job.id);
|
||||
process.exit(0);
|
||||
}
|
||||
|
||||
testJob().catch(console.error);
|
||||
Loading…
Add table
Add a link
Reference in a new issue