public class BatchProcessExportData extends AbstractBatchProcess
job, processDefEXPORT_BIB_AND_INSTANCE, EXPORT_BIB_INSTANCE_AND_EINSTANCE, EXPORT_BIB_ONLY, EXPORT_EX_STAFF, EXPORT_FILTER, EXPORT_FULL, EXPORT_INC, EXT_ERR_TXT, EXT_MARC, EXT_MARCXML, FILTER_DT_FORMAT, INCREMENTAL_EXPORT_EX_STAFF, JOB_DT_FORMAT, MARC, MARCXML, PERCENT, SOLR_DT_FORMAT, XML_DEC| Constructor and Description |
|---|
BatchProcessExportData() |
| Modifier and Type | Method and Description |
|---|---|
Object[] |
batchExport(OLEBatchProcessProfileBo profileBo)
The method receives the profile information and performs the solr query to retrieve the
solr document list and calls the ExportService to get the export data and writes the
formatted data to the file system
|
void |
batchProcessExportFetch() |
int |
generateMarcFromXml()
Writes the content read into a mrc file
|
List<String> |
getBibDocList() |
SearchResponse |
getDeleteSolrQuery() |
DocstoreClientLocator |
getDocstoreClientLocator() |
StringBuilder |
getErrBuilder() |
String |
getErrCnt() |
String |
getFileName() |
File |
getFilePath() |
SearchResponse |
getIncrementalSolrQuery() |
protected void |
getNextBatch()
gets the next batch of records for export
|
int |
getProcessedRec() |
SearchResponse |
getResponse() |
void |
getSolrQuery()
Gets the filter criteria which is used to create the solr query
|
int |
getTotalRecordsExported() |
protected void |
loadProfile(OLEBatchProcessDefinitionDocument processDef)
loads the profile and checks for incremental export
|
void |
performSolrQuery()
gets the solr query based on the filter criteria and executed to retrieve the results
|
protected void |
prepareForRead()
method to be implemented to read initial data for the various processes; will be called before prepareForWrite() method
|
protected void |
prepareForWrite()
methods creates the directories to write file to if they do not exist
if the user provided folder is not valid (cannot be created) then the default location is chosen
|
void |
prepareForWrite(String fileName) |
protected void |
processBatch()
Performs the batch write operation
Writes the data to marcxml or mrc format based on the output format specified in the process
|
void |
setErrCnt(String errCnt) |
void |
setFileName(String fileName) |
void |
setResponse(SearchResponse response) |
void |
setTotalRecordsExported(int totalRecordsExported) |
void |
writeErrorFile()
Writes the error records to the path
|
void |
writeFileToLocation()
Write the content read to mrcxml file
|
void |
writeFileToLocation(String fileName) |
checkJobPauseStatus, createBatchDeleteFailureReportFile, createBatchErrorAttachmentFile, createBatchFailureFile, createBatchFailureFile, createBatchSuccessFile, createFile, deleteBatchFile, deleteBatchFile, getBatchProcessFileContent, getBatchProcessFileContent, getBatchProcessFilePath, getBusinessObjectService, isJobRunning, process, updateJobProgresspublic BatchProcessExportData()
public DocstoreClientLocator getDocstoreClientLocator()
public Object[] batchExport(OLEBatchProcessProfileBo profileBo) throws Exception
Exceptionpublic void getSolrQuery() throws Exception
Exceptionpublic SearchResponse getDeleteSolrQuery() throws Exception
Exceptionpublic SearchResponse getIncrementalSolrQuery() throws Exception
Exceptionprotected void prepareForRead() throws Exception
AbstractBatchProcessprepareForRead in class AbstractBatchProcessExceptionprotected void getNextBatch() throws Exception
getNextBatch in class AbstractBatchProcessExceptionprotected void prepareForWrite() throws Exception
prepareForWrite in class AbstractBatchProcessExceptionpublic void prepareForWrite(String fileName) throws Exception
Exceptionprotected void processBatch() throws Exception
processBatch in class AbstractBatchProcessExceptionpublic void writeFileToLocation() throws Exception
Exceptionpublic void writeFileToLocation(String fileName) throws Exception
Exceptionpublic int generateMarcFromXml() throws Exception
Exceptionprotected void loadProfile(OLEBatchProcessDefinitionDocument processDef) throws Exception
loadProfile in class AbstractBatchProcessprocessDef - Exceptionpublic void performSolrQuery() throws Exception
Exceptionpublic void writeErrorFile() throws Exception
Exceptionpublic void batchProcessExportFetch() throws Exception
Exceptionpublic StringBuilder getErrBuilder()
public List<String> getBibDocList()
public int getProcessedRec()
public String getFileName()
public void setFileName(String fileName)
public int getTotalRecordsExported()
public void setTotalRecordsExported(int totalRecordsExported)
public SearchResponse getResponse()
public void setResponse(SearchResponse response)
public File getFilePath()
Copyright © 2004–2014 The Kuali Foundation. All rights reserved.