Skip to content

Add access to the underlying javax.mail.Session properties #19

@nclemeur

Description

@nclemeur

I had a case where the connection to the smtp server was hanging and never returning. It seems to be linked to the fact no value for the timeout parameters was is given when building the session. The parameters are mail.smtp.timeout and mail.smtp.connectiontimeout and there is currently no easy way to set these.

One option is to use the Mailer constructor with the Session argument, but then it fails on a NPE in logSession because the transportStrategy is not set. Also, a lot of the setup work has to be redone using this approach.

I think a better approach, would be to provide another arguments to the Mailer constructor, adding a Properties argument which would allow for full customisation of the session properties.

Metadata

Metadata

Assignees

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions