Audience Service
The in-app audience service is responsible for the lifecycle of the audiences within in-app. It will initialize an audience from a segment and also make sure that it’s being updated from that segment using the segment-diff service.
Modules
The source for modules described here is available in the jobs folder for the workers and the scripts folder for the cron-jobs.
init-audience worker
Consumes messages from the inapp-init-audience queue and processes them by pulling the full segment associated with the audience and then in turn creates messages containing contact-ids into the inapp-batch queue.
update-audience worker
Consumes messages from the inapp-update-audience queue and using the segment-diff service looks for updates to the segment. For these updates it will create messages containing the contact-ids into the inapp-batch queue or inapp-remove queue depending on if contacts were added or removed.