CMVR-IOT/cmvr-iot-inspection/src/main/java/com/cmvr/inspection/service/IInspectionDetectionAlertService.java
lixiaolong 922d30632b feat(inspection): 添加边缘端gRPC服务IP字段并优化报警去重逻辑
- 在AlertEnvelope中添加grpcIp字段用于前端展示和问题定位
- 将数据库表inspection_detection_alert的幂等键改为仅记录模式,使用event_id进行重复过滤
- 移除检测框明细表及相关处理逻辑,简化数据结构
- 更新麦克风和扬声器控制器的参数传递方式,统一使用RequestBody
- 新增EdgeSpeakerPlayAudioVO类用于扬声器播放音频接口参数传递
2026-07-22 14:46:32 +08:00

19 lines
555 B
Java
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package com.cmvr.inspection.service;
import com.cmvr.inspection.domain.dto.alert.AlertEnvelope;
/**
* 边缘 AI 检测报警接收服务。
*/
public interface IInspectionDetectionAlertService
{
/**
* 接收并持久化一条 PPE 违规报警。
*
* @param envelope 报警信封
* @param requestIdempotencyKey HTTP 请求头中的幂等键,仅记录,不用于重复过滤
* @return true 表示本次新增false 表示重复事件
*/
boolean receive(AlertEnvelope envelope, String requestIdempotencyKey);
}