mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-08-26 18:06:03 +00:00
Add Indexing Stack (#19305)
This commit is contained in:
parent
be3fdedc76
commit
d66c689f6d
@ -86,7 +86,10 @@ public class ElasticSearchIndexSink implements BulkSink, Closeable {
|
||||
} catch (Exception e) {
|
||||
entityErrorList.add(
|
||||
new EntityError()
|
||||
.withMessage("Failed to convert entity to request: " + e.getMessage())
|
||||
.withMessage(
|
||||
String.format(
|
||||
"Failed to convert entity to request: %s , Stack : %s",
|
||||
e.getMessage(), ExceptionUtils.exceptionStackTraceAsString(e)))
|
||||
.withEntity(entity.toString()));
|
||||
LOG.error("Error converting entity to request", e);
|
||||
}
|
||||
@ -173,6 +176,14 @@ public class ElasticSearchIndexSink implements BulkSink, Closeable {
|
||||
handleNonRetriableException(requests.size(), e);
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
entityErrorList.add(
|
||||
new EntityError()
|
||||
.withMessage(
|
||||
String.format(
|
||||
"Bulk request failed: %s, StackTrace: %s",
|
||||
ex.getMessage(),
|
||||
ExceptionUtils.exceptionStackTraceAsString(ex)))
|
||||
.withEntity(requests.toString()));
|
||||
LOG.error("Bulk request retry attempt {}/{} failed", 1, maxRetries, ex);
|
||||
} finally {
|
||||
semaphore.release();
|
||||
|
@ -87,7 +87,10 @@ public class OpenSearchIndexSink implements BulkSink, Closeable {
|
||||
} catch (Exception e) {
|
||||
entityErrorList.add(
|
||||
new EntityError()
|
||||
.withMessage("Failed to convert entity to request: " + e.getMessage())
|
||||
.withMessage(
|
||||
String.format(
|
||||
"Failed to convert entity to request: %s , Stack : %s",
|
||||
e.getMessage(), ExceptionUtils.exceptionStackTraceAsString(e)))
|
||||
.withEntity(entity.toString()));
|
||||
LOG.error("Error converting entity to request", e);
|
||||
}
|
||||
@ -174,6 +177,14 @@ public class OpenSearchIndexSink implements BulkSink, Closeable {
|
||||
handleNonRetriableException(requests.size(), e);
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
entityErrorList.add(
|
||||
new EntityError()
|
||||
.withMessage(
|
||||
String.format(
|
||||
"Bulk request failed: %s, StackTrace: %s",
|
||||
ex.getMessage(),
|
||||
ExceptionUtils.exceptionStackTraceAsString(ex)))
|
||||
.withEntity(requests.toString()));
|
||||
LOG.error("Bulk request retry attempt {}/{} failed", 1, maxRetries, ex);
|
||||
} finally {
|
||||
semaphore.release();
|
||||
|
Loading…
x
Reference in New Issue
Block a user