Hi laxmi,
I'm also trying to send mail thru appengine.
My code is as follows

package outlooky;

import java.io.BufferedReader;

import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Properties;
import javax.mail.Message;
import javax.mail.MessagingException;
import javax.mail.Session;
import javax.mail.Transport;
import javax.mail.internet.AddressException;
import javax.mail.internet.InternetAddress;
import javax.mail.internet.MimeMessage;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

class AuthServlet extends HttpServlet
{
        private static final long serialVersionUID = 1L;

        public void doPost(HttpServletRequest req, HttpServletResponse resp)
throws IOException {
        BufferedReader rd = null;
        rd  = new BufferedReader(new
InputStreamReader(req.getInputStream()));
        String msgBody = new String(rd.readLine());
        sendEmail(msgBody);

}
public void sendEmail(String title) {
    Properties props = new Properties();
      Session session = Session.getDefaultInstance(props, null);

      try {
      Message msg = new MimeMessage(session);
      msg.setFrom(new InternetAddress("[email protected]"));
      msg.addRecipient(Message.RecipientType.TO,new
InternetAddress("[email protected]"));
      msg.setSubject("the wave " + title + " was updated");
      msg.setText("it was updated!");
      Transport.send(msg);
      }
      catch (AddressException e)
      {
      // ...
      }
      catch (MessagingException e)
      {
      // ...
      }
}
}


But I'm not getting any logs in my app and also its not showing me any
sent mail...
can u tell me where is the actual problem is?

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to