|
|
|
@ -8,8 +8,10 @@ import cn.estsh.i3plus.platform.common.util.PlatformConstWords;
|
|
|
|
|
import cn.estsh.i3plus.platform.common.util.QueueConstWords;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.common.Pager;
|
|
|
|
|
import cn.estsh.i3plus.pojo.base.enumutil.CommonEnumUtil;
|
|
|
|
|
import cn.estsh.i3plus.pojo.model.test.TestConstructModel;
|
|
|
|
|
import cn.estsh.i3plus.pojo.platform.bean.SessionUser;
|
|
|
|
|
import cn.estsh.i3plus.pojo.platform.bean.SysRole;
|
|
|
|
|
import cn.estsh.i3plus.pojo.platform.bean.TestTransUser;
|
|
|
|
|
import cn.estsh.impp.framework.base.controller.CoreBaseController;
|
|
|
|
|
import cn.estsh.impp.framework.boot.auth.AuthUtil;
|
|
|
|
|
import cn.estsh.impp.framework.boot.exception.ImppExceptionBuilder;
|
|
|
|
@ -35,6 +37,7 @@ import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
|
|
import java.io.IOException;
|
|
|
|
|
import java.util.ArrayList;
|
|
|
|
|
import java.util.List;
|
|
|
|
|
import java.util.Locale;
|
|
|
|
|
import java.util.Set;
|
|
|
|
@ -109,10 +112,10 @@ public class DemoRedisMqController extends CoreBaseController{
|
|
|
|
|
|
|
|
|
|
@GetMapping(value="/get-cache")
|
|
|
|
|
@ApiOperation(value="缓存",notes="获取数据")
|
|
|
|
|
public ResultBean getCache(){
|
|
|
|
|
System.out.println("2===== " + redisCore.getObject("wms"));
|
|
|
|
|
public ResultBean getCache(String name){
|
|
|
|
|
System.out.println("===== " + redisCore.getObject(name));
|
|
|
|
|
|
|
|
|
|
return new ResultBean(true);
|
|
|
|
|
return new ResultBean(true,redisCore.getObject(name));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@GetMapping(value="/exception-demo")
|
|
|
|
@ -353,4 +356,17 @@ public class DemoRedisMqController extends CoreBaseController{
|
|
|
|
|
|
|
|
|
|
return new ResultBean(true,"操作成功");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@GetMapping(value="/redis-object")
|
|
|
|
|
@ApiOperation(value="测试对象",notes="对象是否需要构造方法")
|
|
|
|
|
public ResultBean testRedisObject(){
|
|
|
|
|
//放入缓存
|
|
|
|
|
TestConstructModel model = new TestConstructModel();
|
|
|
|
|
model.setId(1);
|
|
|
|
|
model.setUser(new TestTransUser());
|
|
|
|
|
model.setUserList(new ArrayList<>());
|
|
|
|
|
redisCore.putObject("model",model,100);
|
|
|
|
|
|
|
|
|
|
return new ResultBean(true,"已放入缓存");
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|