UNPKG

slavery-js

Version:

A simple clustering app that allows you to scale an application on multiple thread, containers or machines

25 lines (23 loc) 891 B
type Options = { host?: string, port?: number, nm_host?: string, nm_port?: number, // max number of request before making more nodes max_queued_requests?: number, // fixed number of processes number_of_nodes?: number, max_number_of_nodes?: number, min_number_of_nodes?: number, // the number of request that have to be in queue before increasing the number of processes increase_processes_at_requests?: number, // the number of node that have to be idle before decreasing the number of processes decrease_processes_at_idles?: number, // how to handle errors: 'throw' | 'log' | 'ignore' | 'return' onError?: 'throw' | 'log' | 'ignore' | 'return', // auto scale based on length of Rquest Queue and the idle rate od nodes auto_scale?: boolean, // timeout for requests timeout?: number, } export default Options;