Hi I'm trying to find a java solution which will allow me to set up the local host into a a VERY light SMTP server. Essentially, I just need to send a single message from the local host which contains configuration details, and I really don't want to mess around which SMTP authentication and such (Trying to keep this as simple as possible, as its a very insignificant [though essential] part of my program). I've have been looking at a variety of tools and I found Asprin, which is an embeddable SMTP server. However, it provides little documentation, and I was wondering if anyone who has had experience using it could provide some insight on how you can set up the server and send messages.
It seems pretty simple to use, but I am also new to the JavaMail API so tackling both at the same time has proved to be harder than I thought.
The project is located here:
https://aspirin.dev.java.net/ Thanks in advance for any help.
actually I haven't tested it myself. But did you read the point "How do I use it?" on the new Aspirin home page? It sounds really pretty easy to send a simple mail with Aspirin.
And from what I see you don't need to know very much about JavaMail for this. You just have to set the necessary fields in the MimeMessage you can create accordingly to the Aspirin documentation almost like you would do when typing a mail in your favorite mail client (recipient, content, ...) ;-) Give it a try and feel free to let me know where you experience problems!
Marco
Ulf Dittmer
Marshal
Joined: Mar 22, 2005
Posts: 35253
7
posted
0
Yeah, I've successfully used aspirin. Here's about the simplest possible code to send a mail with it. You'll have to add assorted import statement for the JavaMail and aspirin classes.
Very important: you need to set a system property called "aspirinDeliverThreads" to "1". Otherwise it starts more than one mail sender thread, and that will lead to problems at shutdown time.
are you still having problems to send mails as described in the other post?
Marco
Ulf Dittmer
Marshal
Joined: Mar 22, 2005
Posts: 35253
7
posted
0
could never use Aspirin
As I pointed out elsewhere, that had nothing to do with aspirin, but is the result of a certain combination of sender address and recipient address. Any other mail server would have encountered the same problem.
But let's not hijack this thread any further by posts that have nothing to do with Lance's problem.
Treimin Clark
Ranch Hand
Joined: Nov 12, 2008
Posts: 757
posted
0
Marco,
Yes, I can never do that on my machine, with my current ISP.
Ulf,
I know that, you told it me before. The problem may be with my ISP. Sorry for attempting to hijack the thread
Treimin: I'm going to post an answer for you problems to the mentioned thread ;-)
Marco
Aggarwal Arpit
Ranch Hand
Joined: Mar 04, 2012
Posts: 86
posted
0
Hi Ulf,
I downloaded zipped file of Aspirin from https://github.com/masukomi/aspirin. But not getting how to use it.
Can you please throw some light on how to work with Aspirin.