We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hello
I am trying to run the vertx mail-service examples. The verticle gets started but the mail is not being sent.
Following is what i am doing in a start method of a verticle
MailConfig mailConfig = new MailConfig() .setHostname("smtp.gmail.com") .setPort(465) .setStarttls(StartTLSOptions.REQUIRED) .setLogin(LoginOption.REQUIRED) .setAuthMethods("PLAIN") .setUsername("abc@abc.com") .setPassword("abc");
MailClient mailClient = MailClient.createShared(vertx, mailConfig); MailMessage email = new MailMessage() .setFrom("user1@example.com") .setTo("abc@abc.com") .setSubject("Test email with HTML") .setText("this is a message") .setHtml("<a href=\"http://vertx.io\">vertx.io</a>"); mailClient.sendMail(email, result -> { if (result.succeeded()) { System.out.println(result.result()); } else { System.out.println("got exception"); result.cause().printStackTrace(); } }); }
When sendMail is called, its handler is never called. no action is performed.
The text was updated successfully, but these errors were encountered:
your configuration is wrong. To send a mail from Gmail, use:
MailConfig mailConfig = new MailConfig() .setHostname("smtp.gmail.com") .setPort(465) .setSsl(true) .setLogin(LoginOption.REQUIRED) .setAuthMethods("PLAIN") ....
Sorry, something went wrong.
private static MailClient getEmailClient() { config.setHostname("smtp.gmail.com"); config.setPort(465); config.setSsl(true); config.setLogin(LoginOption.REQUIRED); config.setUsername("xxx"); config.setPassword("xxx"); config.setAuthMethods("PLAIN"); mailClient = MailClient.createShared(vert, config); eMessage.setFrom("xxx@gmail.com"); eMessage.setTo("xxx@gmail.com"); eMessage.setSubject("Test email"); eMessage.setText("this is the plain message text"); eMessage.setHtml("this is html text <a href="http://vertx.io\">vertx.io"); return mailClient; }
exception on connect javax.net.ssl.SSLHandshakeException: Failed to create SSL connection
i tried this and it keeps throwing this exception
cescoffier
No branches or pull requests
Hello
I am trying to run the vertx mail-service examples. The verticle gets started but the mail is not being sent.
Following is what i am doing in a start method of a verticle
MailConfig mailConfig = new MailConfig()
.setHostname("smtp.gmail.com")
.setPort(465)
.setStarttls(StartTLSOptions.REQUIRED)
.setLogin(LoginOption.REQUIRED)
.setAuthMethods("PLAIN")
.setUsername("abc@abc.com")
.setPassword("abc");
When sendMail is called, its handler is never called. no action is performed.
The text was updated successfully, but these errors were encountered: