[erlang-questions] EPmail-0.2 released

Alexander Kuleshov kuleshovmail@REDACTED
Sat Feb 19 06:24:39 CET 2011


Hello,

First of all thank you Andrew for your advices.

>Your FSMs aren't really very complete, since all you have is
>'autorization' (which should probably be 'authorization') and
>'transaction'. If you're going to use a FSM you should implement...

Yes, now i think about beter FSM implementation.

>Also, implementing the SMTP client for relaying on to a smarthost inline
>like that is kinda... ugly. Your handling of the message body also looks
>like its not ideal, especially if the message is large. You can't be
>sure that gen_tcp:recv(State#state.socket, 0) is going to give you
>everything you need, you need to check for /r/n./r/n at the end.

Yes, i know about it. This is the weakest point. This piece of code is
my top priority in the fixing.

>I'd also suggest writing a lot of unit tests to make sure the code
>behaves as you expect.
Yes i write tests, only they aren't in github.

>Finally, if you're interested, I'd like to invite you to use gen_smtp
>for your SMTP stack. That way you don't have to *write* a SMTP stack and
>I get another user for mine to yell at me for bugs or other issues; we
>both win. Although, if you're writing this just as a learning
>experience, then I can understand the desire to reimplement the wheel
>(although, having written a whole SMTP/MIME stack, I would call it one
>of the more painful wheels to reinvent).

Thank you very much for your offer. You say right: i do it for my
expirience, i want to deep learn Erlang and functional programming.

Thank you.


More information about the erlang-questions mailing list