catch a throwable in datastore crawl
This commit is contained in:
parent
e8319c44f6
commit
6d36baa952
2 changed files with 2 additions and 2 deletions
|
@ -266,7 +266,7 @@ public class CsvDataStoreImpl extends AbstractDataStoreImpl {
|
|||
}
|
||||
final FailureUrlService failureUrlService = ComponentUtil.getComponent(FailureUrlService.class);
|
||||
failureUrlService.store(dataConfig, errorName, url, target);
|
||||
} catch (final Exception e) {
|
||||
} catch (final Exception | OutOfMemoryError e) {
|
||||
final String url = csvFile.getAbsolutePath() + ":" + csvReader.getLineNumber();
|
||||
final FailureUrlService failureUrlService = ComponentUtil.getComponent(FailureUrlService.class);
|
||||
failureUrlService.store(dataConfig, e.getClass().getCanonicalName(), url, e);
|
||||
|
|
|
@ -233,7 +233,7 @@ public class DataIndexHelper implements Serializable {
|
|||
} else {
|
||||
try {
|
||||
dataStore.store(dataConfig, indexUpdateCallback, initParamMap);
|
||||
} catch (final Exception e) {
|
||||
} catch (final Throwable e) {
|
||||
logger.error("Failed to process a data crawling: " + dataConfig.getName(), e);
|
||||
ComponentUtil.getComponent(FailureUrlService.class).store(dataConfig, e.getClass().getCanonicalName(),
|
||||
dataConfig.getConfigId() + ":" + dataConfig.getName(), e);
|
||||
|
|
Loading…
Add table
Reference in a new issue