Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GSoC: finagle-smtp - initial #287

Closed
wants to merge 50 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
27a48e6
A quick&dirty example of SMTP client
suncelesta Mar 12, 2014
7de8295
simple wrappers for javamail and a.c.e.
suncelesta May 6, 2014
d8f4877
New client API
suncelesta May 7, 2014
3684bf5
SMTP commands
suncelesta May 16, 2014
18f43f2
Reply classes
suncelesta May 26, 2014
728d7f9
Dispatcher and transport
suncelesta Jun 3, 2014
5b9e617
Finished codec
suncelesta Jun 9, 2014
507a775
Filters concerning email payload
suncelesta Jun 10, 2014
4410eeb
Receiving server greeting before the session
suncelesta Jun 11, 2014
f5e7604
Reply code refactoring
suncelesta Jun 11, 2014
bed4e94
Minor bugs fix
suncelesta Jun 11, 2014
699d78d
More concise result in simple client
suncelesta Jun 11, 2014
067917c
Full multiline support
suncelesta Jun 11, 2014
14adab8
Refined structure, tests for filters
suncelesta Jun 17, 2014
69aec96
More tests
suncelesta Jun 21, 2014
3664948
Multiline correction and usage doc
suncelesta Jun 24, 2014
8614e7a
Update README.md
selvin Jun 24, 2014
017d516
Update README.md
selvin Jun 24, 2014
074d72d
Update README.md
selvin Jun 24, 2014
a187f29
Update README.md
selvin Jun 24, 2014
571e85a
Update README.md
selvin Jun 24, 2014
41f35c8
Update README.md
selvin Jun 24, 2014
8626554
Merge pull request #1 from selvin/master
suncelesta Jun 25, 2014
f6c8be9
Sending quit command upon service closing
suncelesta Jun 25, 2014
358655c
Fixed issue with build error
suncelesta Jun 25, 2014
adfc22d
EHLO sends domain/address literal
suncelesta Jul 3, 2014
cd9efe4
Copies and EmailBuilder
suncelesta Jul 5, 2014
3ea84a4
Logs
suncelesta Jul 5, 2014
53c9b63
Tests for MailAddress and EmailBuilder
suncelesta Jul 5, 2014
0ea3914
SmtpSimple sends EHLO once in the beginning
suncelesta Jul 7, 2014
597a8c8
..
suncelesta Jul 7, 2014
bc1ac67
resolve conflict
suncelesta Jul 7, 2014
bd2e836
delete unnecessary file
suncelesta Jul 7, 2014
e560f60
Fix accidental mysql test rearrangement
suncelesta Jul 9, 2014
275ec98
Moved Example.scala to finagle-example
suncelesta Jul 9, 2014
7fa4157
Removed left diff on mysql RequestTest
suncelesta Jul 10, 2014
5681625
try to remove end of line diff
suncelesta Jul 10, 2014
ed5ec40
Minor fixes
suncelesta Jul 10, 2014
bd15c38
Merge branch 'finagle-smtp' of https://github.com/suncelesta/finagle …
suncelesta Jul 10, 2014
258be78
Fixed Sender field
suncelesta Jul 11, 2014
178ae73
Fixed README.MD
suncelesta Jul 11, 2014
f2f6a7e
Added scaladoc comments
suncelesta Jul 17, 2014
9b3c003
Added link to RFC
suncelesta Jul 23, 2014
c04fca9
Corrected link to Example in README
suncelesta Jul 28, 2014
a1f96a8
Email headers
suncelesta Aug 1, 2014
78fe18d
Fixed style and logic
suncelesta Aug 8, 2014
a342264
Field names converted to lowercase
suncelesta Aug 11, 2014
caa31e3
DefaultEmail instead of EmailBuilder
suncelesta Aug 11, 2014
8adbf4d
Quit moved to dispatcher
suncelesta Aug 14, 2014
03d9be6
Fixes for all tests to pass
suncelesta Aug 17, 2014
File filter...
Filter file types
Jump to…
Jump to file or symbol
Failed to load files and symbols.

Always

Just for now

Prev

Fixes for all tests to pass

  • Loading branch information...
suncelesta committed Aug 17, 2014
commit 03d9be655193a8eb9e0dbd28925675b3ac17c166
@@ -30,8 +30,6 @@ class SmtpClientDispatcher(trans: Transport[Request, UnspecifiedReply])
case ServiceReady(_,_) => Future.Done
case other => Future.exception(InvalidReply(other.toString))
}
} onFailure {
case _ => close()
}
}

@@ -100,7 +98,9 @@ class SmtpClientDispatcher(trans: Transport[Request, UnspecifiedReply])
}
}

override def close(deadline: Time) = apply(Request.Quit).unit ensure super.close(deadline)
override def close(deadline: Time) = connPhase flatMap { _ =>
apply(Request.Quit).unit
} ensure super.close(deadline)

/**
* Constructs a specified [[com.twitter.finagle.smtp.reply.Reply]] judging by the code
@@ -90,9 +90,10 @@ class MailFilterTest extends FunSuite {

@RunWith(classOf[JUnitRunner])
class HeaderFilterTest extends FunSuite {
def hasOneHeader(body: Seq[String], header: String): Boolean = body.count(_.startsWith(header)) == 1
def hasOneHeader(body: Seq[String], header: String): Boolean =
body.count(_.startsWith(header.toLowerCase)) == 1
def checkHeader(body: Seq[String], header: String, expected: String) = {
val line = body.find(_.startsWith(header))
val line = body.find(_.startsWith(header.toLowerCase))
line match {
case Some(hdr) => {
val value = hdr drop header.length
@@ -36,6 +36,8 @@ class SmtpClientDispatcherTest extends FunSuite {
val (client, server, transport) = newTestSet
server.offer(InvalidReply("wronggreet"))
val dispatcher = new SmtpClientDispatcher(transport)
dispatcher(Request.Hello)
server.offer(ClosingTransmission("QUIT"))
assert(!dispatcher.isAvailable)
}

ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.