|
|
@@ -29,6 +29,7 @@ import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
|
|
import com.deepoove.poi.XWPFTemplate;
|
|
|
import com.google.gson.Gson;
|
|
|
import jakarta.json.Json;
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
import okhttp3.*;
|
|
|
import okhttp3.Response;
|
|
|
import org.apache.commons.lang3.ObjectUtils;
|
|
|
@@ -49,6 +50,7 @@ import java.util.concurrent.atomic.AtomicBoolean;
|
|
|
import java.util.stream.Collectors;
|
|
|
|
|
|
@Service
|
|
|
+@Slf4j
|
|
|
public class GenerateRejectionService {
|
|
|
@Autowired
|
|
|
private DifyService difyService;
|
|
|
@@ -133,8 +135,8 @@ public class GenerateRejectionService {
|
|
|
|
|
|
@Override
|
|
|
public void onResponse(Call call, Response response) throws IOException {
|
|
|
-
|
|
|
if (!response.isSuccessful()) {
|
|
|
+ log.error("请求驳回指导函异常:"+response.body());
|
|
|
emitter.error(new IOException("Unexpected code: " + response));
|
|
|
return;
|
|
|
}
|
|
|
@@ -178,12 +180,14 @@ public class GenerateRejectionService {
|
|
|
saveContent(confessionSession, dataObject);
|
|
|
}
|
|
|
} catch (Exception e) {
|
|
|
+ log.error("保存驳导函异常:"+e.getMessage());
|
|
|
e.printStackTrace();
|
|
|
}
|
|
|
}
|
|
|
|
|
|
}
|
|
|
} catch (Exception e) {
|
|
|
+ log.error("获取驳导函信息异常:"+e.getMessage());
|
|
|
e.printStackTrace();
|
|
|
}
|
|
|
emitter.next(line); // 将每行数据发送到 Flux
|