JasperServer 7.8 : how to use free SMTP server (no credentials required)

0

Hello, I'm trying to configure JRS to send reports by email; the mail server is owned by my client and does not require any authentication (no username and no password).

I can't use another mail server due to client security policies.

I configured the js.quartz.properties file as follow:

report.scheduler.mail.sender.host=our-client-mail-server-name
report.scheduler.mail.sender.username=
report.scheduler.mail.sender.password=
report.scheduler.mail.sender.from=sender-address@sender-domain
report.scheduler.mail.sender.protocol=smtp
report.scheduler.mail.sender.port=25

I configured the applicationContext-report-scheduling.xml file as follows:

<bean id="reportSchedulerMailSender" class="org.springframework.mail.javamail.JavaMailSenderImpl" lazy-init="true">
<property name="host" value="${report.scheduler.mail.sender.host}"/>
<property name="username" value="${report.scheduler.mail.sender.username}"/>
<property name="password" value="${report.scheduler.mail.sender.password}"/>
<property name="protocol" value="${report.scheduler.mail.sender.protocol}"/>
<property name="port" value="${report.scheduler.mail.sender.port}"/>
<property name="javaMailProperties">
<props>
<prop key="mail.smtp.sendpartial">true</prop>
<prop key="mail.smtp.auth">false</prop>
</props>
</property>
</bean>

I tested an ImmediateExecution of an existing job, and it stucks in executing.

How can I properly configure JRS?

Thanks

dbarbon's picture
Joined: May 9 2018 - 1:29am
Last seen: 5 days 20 hours ago

1 Answer:

0
If your mail server does not require authentication then ensure mail.smtp.auth is set to false in applicationContext-report-scheduling.xml the above config shows that this is already set. 
Perhaps the problem lies somewhere else but there is not enough information.
 
You can enable mail debug to see more  SMTP debug logging. Check this article on how to set mail.debug :
https://community.jaspersoft.com/wiki/gmail-smtp-report-jobs-failing-smtp-authentication-error-despite-correct-username-and-password
vchiem's picture
23114
Joined: May 1 2017 - 5:33pm
Last seen: 5 hours 22 min ago
Feedback
randomness