ParseErrorException on outgoing mail from JIRA

Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.

Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Summary

Symptoms

JIRA's outgoing mail is generating error messages.

The following appears in the atlassian-jira.log:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 org.apache.velocity.exception.ParseErrorException: Encountered "mailto" at line 3, column 59. Was expecting one of: "," ... ")" ... <WHITESPACE> ... at org.apache.velocity.Template.process(Template.java:141) at org.apache.velocity.runtime.resource.ResourceManagerImpl.loadResource(ResourceManagerImpl.java:374) at org.apache.velocity.runtime.resource.ResourceManagerImpl.getResource(ResourceManagerImpl.java:297) at org.apache.velocity.runtime.RuntimeInstance.getTemplate(RuntimeInstance.java:767) at org.apache.velocity.runtime.directive.Parse.render(Parse.java:141) at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:114) at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:230) at org.apache.velocity.Template.merge(Template.java:256) at org.apache.velocity.app.VelocityEngine.mergeTemplate(VelocityEngine.java:422) at com.atlassian.velocity.DefaultVelocityManager.getEncodedBody(DefaultVelocityManager.java:77) at com.atlassian.velocity.DefaultVelocityManager.getEncodedBody(DefaultVelocityManager.java:61) at com.atlassian.jira.service.services.mail.MailFetcherService.createErrorForwardEmail(MailFetcherService.java:338) at com.atlassian.jira.service.services.mail.MailFetcherService.forwardEmail(MailFetcherService.java:382) at com.atlassian.jira.service.services.mail.MailFetcherService.run(MailFetcherService.java:192) at com.atlassian.jira.service.JiraServiceContainerImpl.run(JiraServiceContainerImpl.java:60) at com.atlassian.jira.service.ServiceRunner.execute(ServiceRunner.java:47) at org.quartz.core.JobRunShell.run(JobRunShell.java:195) at com.atlassian.multitenant.quartz.MultiTenantThreadPool$MultiTenantRunnable.run(MultiTenantThreadPool.java:72) at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)

Diagnosis

Email templates have been modified. See the Administration > System > Troubleshooting & Support >System Info page for modified files and verify whether any *.vm files are listed.

Cause

Email templates are using invalid formatting.

Solution

Workaround

Replace modified vm templates with unmodified copies.

Resolution

Modify the vm templates to use valid formatting. See more here on Customizing Email Content

You can get copies of unmodified templates from the archive downloads on our JIRA Archives Downloads page. We recommend that you match the download version to the one that you are running.

Customizations to Velocity templates or other JIRA files are not included in the scope of Atlassian Support.

Updated on April 2, 2025

Still need help?

The Atlassian Community is here for you.