Interface PatchImportService
- All Known Implementing Classes:
DefaultPatchImportService
public interface PatchImportService
Patches specific impex import service. It is responsible for importing data based on impexImportUnit and creating
ImpexImportUnitResult.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiongetStreamForImpexImportUnit(ImpexImportUnit impexImportUnit) Method prepares SequenceInputStream based on impexImportUnit.importImpexUnit(ImpexImportUnit impexImportUnit) Method for importing impex data based on ImpexImportUnit.importImpexUnitWithoutTracking(ImpexImportUnit impexImportUnit) Method is workaround not to execute the aspect.
-
Field Details
-
IMPEX_IMPORT_CRON_JOB_REMOVE_ON_SUCCESS_PROPERTY_KEY
Property to disable removing impex import cron job after successful import- See Also:
-
IMPEX_IMPORT_FAIL_ON_ERROR_PROPERTY_KEY
Property to disable failing impex import on error- See Also:
-
-
Method Details
-
importImpexUnit
Method for importing impex data based on ImpexImportUnit. ImpexImportUnitResult data is created after import with information about import result.- Parameters:
impexImportUnit- unit which keeps all data- Returns:
- ImpexImportUnitResult - object keeps information about impexImportUnit and import result
- Throws:
PatchImportException- when there is- FileNotFoundException - impex data file or mandatory header file is missing
- SystemException - problems related to model initialization, model saving or model not found, interceptor exceptions
- IllegalArgumentException - there is no script for import configuration or there is model type not supported exception
- IllegalStateException - during performing cron job when underlying source for given model doesn't exist
-
importImpexUnitWithoutTracking
Method is workaround not to execute the aspect. It is used to execute importImpexUnit without tracking.- Parameters:
impexImportUnit- unit which keeps all data- Returns:
- ImpexImportUnitResult - object keeps information about impexImportUnit and import result
- Throws:
PatchImportException
-
getStreamForImpexImportUnit
SequenceInputStream getStreamForImpexImportUnit(ImpexImportUnit impexImportUnit) throws FileNotFoundException Method prepares SequenceInputStream based on impexImportUnit. It combines stream based on macro list, header files and data file.- Parameters:
impexImportUnit- unit which keeps all data- Returns:
- SequenceInputStream keeps all data from impexImportUnit in one stream
- Throws:
FileNotFoundException- when a given impex file cannot be found
-