canderso / Mixpanel

A .NET Mixpanel API to add tracking to your Windows Phone, WinRT and .NET 4 apps. The complete Mixpanel API is supported (tracking events and all types of profile updates). The API also supports offline mode and bad networks: if element could not be sent, it'll be stored locally and sent later on.
10 stars 2 forks source link

Optimizations #1

Open netogallo opened 8 years ago

netogallo commented 8 years ago

Hi Carl,

I wrote you in NuGet recently. Thank you for sharing the code. I noticed that every time an event gets logged, it will be immediately sent and written to an individual file (one file per event) (correct me if I am wrong). My team is interested in allowing some optimizations to this process. Ie. batch sending and saving several events instead of one per file. I think the best approach would be making the MixpanelClient extensible and allowing the send/save methods to be overridden so one can send/save events according to needs. Would you be open in working together to optimize this library in such way? Let me know, that way I can start sharing improvements as pull requsts :)

canderso commented 8 years ago

Hi,

Sure, go ahead! The behaviour you're describing is specific to the .NET implementation, the WinRT and Windows Phone 8 ones already provide such support. Therefore adding it to the library would make perfect sense.

Please make all the changes you'd like, just write the corresponding unit tests while at it, it'd be perfect.

I'll review your pull request ASAP.

Thanks for your interest, Carl