- 在AlertEnvelope中添加grpcIp字段用于前端展示和问题定位 - 将数据库表inspection_detection_alert的幂等键改为仅记录模式,使用event_id进行重复过滤 - 移除检测框明细表及相关处理逻辑,简化数据结构 - 更新麦克风和扬声器控制器的参数传递方式,统一使用RequestBody - 新增EdgeSpeakerPlayAudioVO类用于扬声器播放音频接口参数传递
19 lines
555 B
Java
19 lines
555 B
Java
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);
|
||
}
|