123
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
package com.ruoyi.controller;
|
||||
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
public class IndexController {
|
||||
@GetMapping("/ok")
|
||||
public String ok(){
|
||||
return "ok";
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
package com.ruoyi.controller;
|
||||
|
||||
|
||||
import com.ruoyi.cai.ws.holder.WebSocketSessionHolder;
|
||||
import com.ruoyi.cai.ws.util.WebSocketUtils;
|
||||
import com.ruoyi.common.core.domain.R;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/cai/test")
|
||||
public class TestController {
|
||||
public R getSession(){
|
||||
int size = WebSocketSessionHolder.size();
|
||||
return R.ok(size);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user