Better language for email polling, C# or C++? RRS feed

  • General discussion

  • There's currently a small internal debate over what language we should be writing an email polling service.

    It is a part of a much broader system. Various accounts will be set up, and emails will be pulled from them and then encrypted and stored in a database.

    As it is part of a larger system we are planning on using an ORM such as Entity Framework and have a DAL or C# API to handle all things database. C# .NET has a solid networking API and some mail related stuff already, as well as solid encryption.

    Concerns surrounding using C++ include;

    • Having to write network code from scratch (limited on external library use)
    • Can not use Entity Framework or the C# database API, would require database code to be repeated in 2 languages allowing for transfer of bugs, more time taken etc..
    • Encryption.. The clients are going to be .NET and so we want to use .NET encryption from start to finish so that encryption is standardized throughout
    • Later in the projects life we want to support more than just Pop3 and IMAP, Microsoft provide a managed API for it's exchange web services. To achieve this in C++ is not elegant and not recommended by Microsoft

    What are the advantages of using C++ in this scenario if any?

    Sunday, February 1, 2015 10:53 PM

All replies

  • Hi Lee,

    first of all: I would choose C# for the task.

    That said, C++ does have some advantages:

    • Better control over memory usage (it's especially easier to vanish sensitive information from memory)
    • Having to build it up from scratch means you can optimize performance to your specific needs.

    I don't see how that would justify adding that much more work-hours though.


    There's no place like

    Monday, February 2, 2015 9:38 AM