Hi Authors,
I have a question related to OrthancJob. In the orthanc configuration it explain
// Whether to save the jobs into the Orthanc database. If this // option is set to “true”, the pending/running/completed jobs are // automatically reloaded from the database if Orthanc is stopped // then restarted (except if the “–no-jobs” command-line argument // is specified). This option should be set to “false” if multiple // Orthanc servers are using the same database (e.g. if PostgreSQL // or MariaDB/MySQL is used). “SaveJobs” : true,
In my orthanc configuration I already set SaveJobs equals “true”. But job DicomClientJob (in DicomWeb Plugin) is not saved when Orthanc is shutted down. Whereas, job PushTransfer (in TransferAccelerator Plugin) is saved.
I also created a plugin using Job mechanism by calling this SDK
std::string jobId = OrthancPlugins::OrthancJob::Submit(job.release(), PRIORITY);
Everything in my plugin is working perfectly. Job is running asynchronously. However, Job is not saved whenever Orthanc stops.
Can you give me some instructions how to save Job
Hello,
As of release 1.7, the DICOMweb doesn’t support saving of jobs.
This can be seen by the fact that “OrthancPluginRegisterJobsUnserializer()” is not called in the source code of the DICOMweb plugin, contrarily to the “transfers accelerator” plugin.
Sébastien-
Thanks a lot, Sebastien. That’s what I want.
Hi Sebastien,
I have another question. If two plugins register callback by calling OrthancPluginRegisterJobsUnserializer, then do all plugins call all jobs save in Db ? For example I have a plugin calls OrthancPluginRegisterJobsUnserializer, and Transfer Accelerator also calls OrthancPluginRegisterJobsUnserializer. When I use both plugin in the Orthanc, then only Transfer Accelerator calls the callback Unserializer. Is that correct ?
Thanks
This is explained in the documentation of the plugin SDK:
https://sdk.orthanc-server.com/group__Callbacks.html#gae38d30f620161dacfecc364ae2882565
https://sdk.orthanc-server.com/group__Callbacks.html#gada376d33951ece9c3db5e2a7d00d75c1
“The unserialized job (as created by OrthancPluginCreateJob()), or NULL if this unserializer cannot handle this job type.”