public class JobManagerImpl extends java.lang.Object implements JobManager
Modifier and Type | Class and Description |
---|---|
class |
JobManagerImpl.JobDeleteResource |
Constructor and Description |
---|
JobManagerImpl(com.marklogic.client.DatabaseClient jobClient,
com.marklogic.client.DatabaseClient traceClient) |
Modifier and Type | Method and Description |
---|---|
JobDeleteResponse |
deleteJobs(java.lang.String jobIds) |
JobExportResponse |
exportJobs(java.nio.file.Path exportFilePath,
java.lang.String[] jobIds)
Export Job documents and their associated Trace documents to a zip file.
|
void |
importJobs(java.nio.file.Path importFilePath)
Import Job documents and their associated Trace documents from a zip file.
|
void |
saveJob(Job job)
Saves the job to the database
|
void |
saveJob(Job job,
com.marklogic.client.Transaction transaction)
Saves the job to the database
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
create
public JobManagerImpl(com.marklogic.client.DatabaseClient jobClient, com.marklogic.client.DatabaseClient traceClient)
public void saveJob(Job job)
JobManager
saveJob
in interface JobManager
job
- - the job you want to savepublic void saveJob(Job job, com.marklogic.client.Transaction transaction)
JobManager
saveJob
in interface JobManager
job
- - the job you want to savetransaction
- - the transaction that is to be used to write the jobpublic JobDeleteResponse deleteJobs(java.lang.String jobIds)
deleteJobs
in interface JobManager
jobIds
- comma-separated list of jobIds to delete.public JobExportResponse exportJobs(java.nio.file.Path exportFilePath, java.lang.String[] jobIds)
JobManager
exportJobs
in interface JobManager
exportFilePath
- specifies where the zip file will be writtenjobIds
- a comma-separated list of jobIds; if null, all will be exportedpublic void importJobs(java.nio.file.Path importFilePath) throws java.io.IOException
JobManager
importJobs
in interface JobManager
importFilePath
- specifies where the zip file existsjava.io.IOException
- if unable to open or read the target input file