Meaningless Drivel is fun!*
The moose likes Servlets and the fly likes email not triggering Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "email not triggering" Watch "email not triggering" New topic

email not triggering

monis raza
Ranch Hand

Joined: Sep 05, 2011
Posts: 38

here is my code to trigger email.
when i am running email file as java application it is working fine but when i am adding it to servlet email is not triggering. can anyone tell me if my servlet is ok to access the code in model

Prasad Krishnegowda
Ranch Hand

Joined: Apr 25, 2010
Posts: 507

How is the servlet invoked? is it with GET or POST request.
I see doPost() blank. Is it intentional?

Also, how about writing syslogs to see where the flow is going?
Tel us, what you have done till now, to DEBUG this?

Regards, Prasad
SCJP 5 (93%)
Marek Krokosinski
Ranch Hand

Joined: Jun 10, 2011
Posts: 64
Try with:

instead of:
sai rama krishna
Ranch Hand

Joined: May 29, 2009
Posts: 230
getDefaultInstance Get the default Session object. If a default has not yet been setup, a new Session object is created and installed as the default.

Therefore, if one does not already exist, it call getInstance()

getInstance Get a new Session object.

So, a new session object is created, regardless of whether one already exists.
Don't get me started about those stupid light bulbs.
subject: email not triggering
Similar Threads
SHA1 digest error for javax/mail/MessagingException
How to send mail form java application
Java Mail Authentication
Auto Generated Email using Java
SendFailedException for sending simple email by using JavaMail