Reputation: 2363
I have defined a job as follows in the jobs folder in grails:
class TransferFilesQueueJob {
def execute() {
print "File Transfer Job start!"
FileTransfer.transferFilesToHere()
print "File Transfer Job end!"
}
}
When running my application in IntelliJ, this job runs every few seconds or so. Even after restarting. Any idea why? I don't have any other places that are scheduling it.
I had a declaration earlier on, but I've removed it. It seems like it is storing configuration somewhere else or job state information. But I cannot find where. -- Further notes I renamed the job class and it stopped running. So this seems to point to the job being persisted somewhere. However, I have never set it to have any kind of persistance beyond the current running of the server.
Upvotes: 1
Views: 1253
Reputation: 3881
The Quartz plugin has a default simple trigger for every Job
, which is used if no trigger is set by the programmer, and which fires every few seconds. To have no triggers attached to a Job
, set an empty static triggers
block in the class.
static triggers = { }
Upvotes: 5