akka-smtp-server

Build Status Coverage Status Codacy Badge Codacy Badge Maven Central Maven Central

Smtp server based on akka stream.

Add to your project:

 libraryDependencies += "com.github.ajozwik" %% "akka-smtp" % <version>

For minimal usage you need to provide consumer method with signature (Mail=>Future[ConsumedResult]). consumer method receives Mail object and it repeats with Future[SuccessfulConsumed] or Future[FailedConsumed].

AddressHandler.scala is optional implementation for fail fast address resolution (blacklist).

Usage: Implement trait Consumer

Example implementation: LogConsumer

Example usage:

  • Pack project

sbt pack

akka-smtp/target/pack/bin/main -Dconsumer.class=pl.jozwik.smtp.server.consumer.FileLogConsumer

  • or use project as dependency and provide own Main class