activity: add return if callback error
This commit is contained in:
parent
2d4a4ad991
commit
d77e557945
@ -1104,12 +1104,12 @@ public class DefaultTransportService extends TransportActivityManager implements
|
|||||||
TopicPartitionInfo tpi;
|
TopicPartitionInfo tpi;
|
||||||
try {
|
try {
|
||||||
tpi = partitionService.resolve(ServiceType.TB_CORE, tenantId, entityId);
|
tpi = partitionService.resolve(ServiceType.TB_CORE, tenantId, entityId);
|
||||||
} catch (TenantNotFoundException e) {
|
} catch (Exception e) {
|
||||||
log.trace("Failed to send message to core. Tenant with ID [{}] not found in the database. Message delivery aborted.", tenantId, e);
|
log.trace("Failed to send message to core. Tenant with ID [{}], entityType [{}], entityId [{}], routingKey [{}], \nmsg [{}].\n Message delivery aborted.", tenantId, entityId.getEntityType(), entityId.toString(), routingKey, msg, e);
|
||||||
tpi = TopicPartitionInfo.builder().topic("").build();
|
|
||||||
if (callback != null) {
|
if (callback != null) {
|
||||||
callback.onError(e);
|
callback.onError(e);
|
||||||
}
|
}
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
if (log.isTraceEnabled()) {
|
if (log.isTraceEnabled()) {
|
||||||
log.trace("[{}][{}] Pushing to topic {} message {}", tenantId, entityId, tpi.getFullTopicName(), msg);
|
log.trace("[{}][{}] Pushing to topic {} message {}", tenantId, entityId, tpi.getFullTopicName(), msg);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user