Skip to content

Commit

Permalink
fix checkstyle error
Browse files Browse the repository at this point in the history
  • Loading branch information
xwm1992 committed Aug 1, 2024
1 parent 0e76cbb commit c770607
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,14 @@
import org.apache.eventmesh.common.utils.IPUtils;
import org.apache.eventmesh.common.utils.JsonUtils;
import org.apache.eventmesh.openconnect.api.ConnectorCreateService;
import org.apache.eventmesh.openconnect.offsetmgmt.api.callback.SendExceptionContext;
import org.apache.eventmesh.openconnect.offsetmgmt.api.callback.SendMessageCallback;
import org.apache.eventmesh.openconnect.offsetmgmt.api.callback.SendResult;
import org.apache.eventmesh.openconnect.api.connector.SinkConnectorContext;
import org.apache.eventmesh.openconnect.api.connector.SourceConnectorContext;
import org.apache.eventmesh.openconnect.api.factory.ConnectorPluginFactory;
import org.apache.eventmesh.openconnect.api.sink.Sink;
import org.apache.eventmesh.openconnect.api.source.Source;
import org.apache.eventmesh.openconnect.offsetmgmt.api.callback.SendExceptionContext;
import org.apache.eventmesh.openconnect.offsetmgmt.api.callback.SendMessageCallback;
import org.apache.eventmesh.openconnect.offsetmgmt.api.callback.SendResult;
import org.apache.eventmesh.openconnect.offsetmgmt.api.data.ConnectRecord;
import org.apache.eventmesh.openconnect.offsetmgmt.api.data.RecordOffsetManagement;
import org.apache.eventmesh.openconnect.offsetmgmt.api.storage.DefaultOffsetManagementServiceImpl;
Expand All @@ -66,7 +66,6 @@
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import java.util.UUID;
import java.util.concurrent.BlockingQueue;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.ExecutorService;
Expand Down Expand Up @@ -354,7 +353,8 @@ public void onSuccess(SendResult result) {
public void onException(SendExceptionContext sendExceptionContext) {
// handle exception
sourceConnector.onException(record);
log.error("send record to sink callback exception, process will shut down, record: {}", record, sendExceptionContext.getCause());
log.error("send record to sink callback exception, process will shut down, record: {}", record,
sendExceptionContext.getCause());
try {
stop();
} catch (Exception e) {
Expand All @@ -377,7 +377,7 @@ public void onException(SendExceptionContext sendExceptionContext) {
private SendResult convertToSendResult(ConnectRecord record) {
SendResult result = new SendResult();
result.setMessageId(record.getRecordId());
if(StringUtils.isNotEmpty(record.getExtension("topic"))) {
if (StringUtils.isNotEmpty(record.getExtension("topic"))) {
result.setTopic(record.getExtension("topic"));
}
return result;
Expand Down

0 comments on commit c770607

Please sign in to comment.