Skip to content

Commit

Permalink
fix(database): refine log output for sync database failed
Browse files Browse the repository at this point in the history
  • Loading branch information
yizhouxw committed Sep 30, 2024
1 parent 1f5d93a commit 6d91af8
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
import org.springframework.transaction.annotation.Transactional;
import org.springframework.validation.annotation.Validated;

import com.oceanbase.odc.common.util.ExceptionUtils;
import com.oceanbase.odc.core.authority.SecurityManager;
import com.oceanbase.odc.core.authority.permission.Permission;
import com.oceanbase.odc.core.authority.util.Authenticated;
Expand Down Expand Up @@ -515,7 +516,8 @@ public Boolean internalSyncDataSourceSchemas(@NonNull Long dataSourceId) throws
});
return true;
} catch (Exception ex) {
log.warn("Sync database failed, dataSourceId={}, errorMessage={}", dataSourceId, ex.getLocalizedMessage());
log.warn("Sync database failed, dataSourceId={}, errorMessage={}",
dataSourceId, ExceptionUtils.getRootCauseReason(ex));
return false;
} finally {
lock.unlock();
Expand Down

0 comments on commit 6d91af8

Please sign in to comment.