-
Notifications
You must be signed in to change notification settings - Fork 6
Channel Broker
The channel-broker acts as a dam between the survey-broker that polls active surveys and schedules contacts (IVR calls or SMS messages) for new and failed respondents. The channel-broker memorizes and keeps updated active contacts on the external channel services (Verboice, Nuntium) and prevents having more contacts than the channel capacity.
One single channel-broker process will be spawned for each distinct channel. Surveys running in parallel inside a single Surveda instance will all go through the same channel-broker and thus share the channel equally, though not randomized because of the survey-broker design which polls surveys one by one; each survey will advance one after the other.
The channel-broker doesn't monitor the external services. It assumes that the external service is dedicated to it. It only memorizes which contacts have been sent to the external services from this Surveda instance, then monitors these contacts only. The channel-broker doesn't ask the external services for their actual queues.
That being said, if we know that multiple Surveda instances will run Surveys in parallel on the same external service, the channel capacity of each Surveda instance can be tweaked to share the channel queue (equally or not).
See Start Survey for how the channel-broker is integrated into the system.
The channel-capacity can be customized for each channel.
-
DEFAULT_CHANNEL_CAPACITY
(defaults to 100); -
CHNL_BKR_GC_IDLE_MINUTES
how long until a contact is considered idle (defaults to 2); -
CHNL_BKR_GC_INTERVAL_MINUTES
how often to run the idle-contacts state check against the remote service (defaults to 2); -
SHUT_DOWN_MINUTES
inactivity timeout before a channel-broker process shall exit (defaults to 30) (:warning: currently not working).