Whenever an analytics event is generated, it is persisted to disk until the event has successfully been sent to the server. The problem is that all events are written to the same json file. This will cause issues when more than one analytics process is being run at the same time.
So we solve this by writing events to separate files as well as creating a pid file that only allows one process to send analytics at a time.
FYI, these changes take place in node-appc.