UNPKG

blazerjob

Version:

TypeScript library for scheduling, executing, and managing asynchronous tasks (custom, HTTP, Cosmos) with a SQLite backend.

21 lines (20 loc) 761 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const index_1 = require("../index"); const cosmos_1 = require("../cosmos"); const job = new index_1.BlazeJob({ dbPath: './tasks_cosmos_query.db' }); (async () => { console.log('Test Cosmos multi-query démarré'); await (0, cosmos_1.scheduleManyCosmosQueries)(job, { addresses: [ 'cosmos1fl48vsnmsdzcv85q5d2q4z5ajdha8yu34mf0eh', 'cosmos1c9ye9j3p4e9w8f7j2k7l6k8e8f7g9h5d3j8k7h', // Ajoute ici d'autres adresses si besoin ], count: 100, queryType: 'balance', intervalMs: 100, // Autres options possibles: retriesLeft, priority, configOverrides, runAt, webhookUrl }); job.start(); })();