aijinhui
2023-10-24 8a87e4226aa802d6a0e3566c66824fedf68e77da
ard-work/src/main/java/com/ruoyi/device/camera/service/impl/AsyncLogin.java
@@ -6,6 +6,7 @@
import com.ruoyi.device.hiksdk.service.IHikClientService;
import org.hibernate.validator.internal.util.stereotypes.Lazy;
import org.springframework.scheduling.annotation.Async;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
@@ -25,15 +26,14 @@
    @Resource
    IDhClientService dhClientService;
    @Async
    @Async("loginExecutor")
    public void hikLogin(ArdCameras ardCameras) {
        Threads.sleep(200);
        hikClientService.login(ardCameras);
    }
    @Async
    @Async("loginExecutor")
    public void dhLogin(ArdCameras ardCameras) {
        Threads.sleep(200);
        dhClientService.login(ardCameras);
    }
}
}