Multiple Emails generated by Lucee [solved]

We installed Lucee 5.3.2.77 that uses Apache Tomcat/9.0.20 and AdoptOpenJdk 11.0.3 64 bit.
I have an application that is currently running in a DMZ on ColdFusion 11 Standard edition in production and ColdFusion 11 Enterprise on QA and local. We have another Lucee Server that we are doing our testing and changes running Lucee 5.3.1.102 and Oracle Java 1.8.0_181.
On all of the boxes when an email is generated, it only generates the email one time.
On the new Lucee box with OpenJDK, The email is generated and a .tsk file is created in the \server\drive$\inetpub\wwwroot\webdir\sitename\WEB-INF\lucee\remote-client\open folder.
The problem is the file stays there and the next time an email task is run it creates a new tsk file for the new email and both emails are sent, wash rinse repeat.
If 3 emails are generated to then the 1st person will receive 3 emails, the second 2 emails and the 3rd 1 email. In testing the first email was generated, waited a few minutes generated a second, waited and generated a third.
Has anyone come across this?

Any thing in the logs? Try bumping the log level for remote client up?

In the remote client log, it appears to be generating 2 lines everytime the mail is called. This is the page being called.
So on 4th run, there are 4 files and 4 emails generated. and 8 lines in the log.

Carrier Appointment Test body{font-size:14px;} Your appointment has been scheduled at TEST

BOL Number: 123456 Net Weight: 25000
Appointment Date: 08/16/2019
Appointment Time: 1800
Appointment Number: 132121212




Looks like the culprit was the Spool enabled option in the admin:
Uncheck it and update delete files in the open folder.

Sory to resurrect a thread here, but kinda related.

We had the same problem - and did the same “solution”, as in, switch off the spooling in admin settings. This solved the problem, yes.

But now, pushing out 170’000 newsletters with two Lucee boxes takes about 3 hours, which is 6 - 10 times longer than it should :slight_smile:

So, is there anything that could be done with the “when spooling is switched on at admin, duplicate emails tend to happen”? We had to turn off the feature, as some users were getting the newsletter 6 times.