Package org.cdlib.mrt.tools.loader
Class BatchLoader
java.lang.Object
org.cdlib.mrt.utility.ListProcessorBase
org.cdlib.mrt.utility.ListProcessorSimple
org.cdlib.mrt.tools.loader.BatchLoader
- All Implemented Interfaces:
ListProcessor
Run a Storage load test
- Author:
- dloy
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected String
protected URL
static boolean
protected File
protected Vector<LoaderInfo>
protected URL
static final String
protected String
protected String
protected File
protected URL
protected File
protected URL
protected File
protected String
static boolean
Fields inherited from class org.cdlib.mrt.utility.ListProcessorSimple
m_clientProperties
Fields inherited from class org.cdlib.mrt.utility.ListProcessorBase
logger, m_framework, m_status, PROCESSCNT, PROCESSTIME, TOTALBYTES, TOTALTIME
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected String
dumpStatus
(String header, Properties statusProp) void
end()
Process on EnrichmentList itemprotected Properties
protected Properties
getIngestStatus
(org.apache.http.HttpResponse response) getName()
Name of EnrichmentListprotected void
initialize
(TFrame fw) protected void
protected void
static void
Main methodvoid
process
(String line, Properties processProp) Process an incoming line which contains 1) ark 2) sequence number Use the ark for issuing an addVersion to a storage serviceprotected Properties
sendIngest
(URL ingestURL, String profile, File manifestFile) Send constructed request to ingestprotected org.apache.http.HttpResponse
Send ingest requestMethods inherited from class org.cdlib.mrt.utility.ListProcessorSimple
getClientProperties, getIntProp, processList
Methods inherited from class org.cdlib.mrt.utility.ListProcessorBase
getFileProperties, log, requiredProp
-
Field Details
-
NAME
-
MESSAGE
-
LS
-
DEBUG
public static boolean DEBUG -
SENDINGEST
public static boolean SENDINGEST -
checksumType
-
processList
-
extractBaseDirectory
-
outputManifestDirectoryBase
-
outputManifestBaseURL
-
componentURLBase
-
outputManifestURL
-
outputBatchFile
-
extractDirectories
-
profile
-
ingestBase
-
-
Constructor Details
-
BatchLoader
- Throws:
TException
-
-
Method Details
-
main
Main method -
initialize
- Overrides:
initialize
in classListProcessorSimple
- Throws:
TException
-
initializeBatchLoader
- Throws:
TException
-
getName
Name of EnrichmentList- Specified by:
getName
in interfaceListProcessor
- Overrides:
getName
in classListProcessorSimple
- Returns:
- name to be applied for identifying process properties
-
process
Process an incoming line which contains 1) ark 2) sequence number Use the ark for issuing an addVersion to a storage service
- Specified by:
process
in interfaceListProcessor
- Overrides:
process
in classListProcessorSimple
- Parameters:
line
- line containing ark and sequence numberprocessProp
- runtime properties- Throws:
TException
- process exception
-
log
-
end
Description copied from class:ListProcessorSimple
Process on EnrichmentList item- Overrides:
end
in classListProcessorSimple
- Throws:
TException
-
sendIngest
Send constructed request to ingest- Parameters:
ingestURL
- batch ingest serviceprofile
- process profilemanifestInfo
- batch manifest information- Returns:
- Feeder service state
- Throws:
TException
- process exception
-
sendIngestMultipart
protected org.apache.http.HttpResponse sendIngestMultipart(String ingestID, URL url, File ingestPackage, String profileIn, String type) throws TException Send ingest request- Parameters:
ingestID
-url
- URL of ingest serviceingestPackage
- batch fileprofileIn
- ingest profiletype
- type of ingest request- Returns:
- http client response
- Throws:
TException
- process exceptions
-
getIngestStatus
- Throws:
TException
-
getDummyIngestStatus
- Throws:
TException
-
dumpStatus
-