MCPcopy Create free account
hub / github.com/omkarcloud/botasaurus / getParallelCount

Method getParallelCount

js/botasaurus-server-js/src/server.ts:598–604  ·  view source on GitHub ↗

* Get the parallel count (how many scrapers can run at once) for a task. * Uses scraper_name if scraper-based rate limiting, otherwise scraper_type.

(scraperName: string, scraperType: string)

Source from the content-addressed store, hash-verified

596 * Uses scraper_name if scraper-based rate limiting, otherwise scraper_type.
597 */
598 getParallelCount(scraperName: string, scraperType: string): number {
599 const key = this.isScraperBasedRateLimit ? scraperName : scraperType;
600 // @ts-ignore
601 const limit = this.rateLimit[key];
602 // If no limit is set (null/undefined), default to 1
603 return limit != null && limit > 0 ? limit : 1;
604 }
605}
606
607export const Server = new _Server();

Callers 1

enrichWithEtaFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected