zzj
parent
7b38972c73
commit
d05ceebba0
|
@ -14,10 +14,10 @@ spring:
|
||||||
nacos:
|
nacos:
|
||||||
discovery:
|
discovery:
|
||||||
# 服务注册地址
|
# 服务注册地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
config:
|
config:
|
||||||
# 配置中心地址
|
# 配置中心地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
# 配置文件格式
|
# 配置文件格式
|
||||||
file-extension: yml
|
file-extension: yml
|
||||||
# 共享配置
|
# 共享配置
|
||||||
|
|
|
@ -26,6 +26,7 @@ public abstract class CacheAbs<K, V> implements Cache<K, V> {
|
||||||
return keyPre() + key;
|
return keyPre() + key;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 通过Key获取value值
|
* 通过Key获取value值
|
||||||
* @param key 键
|
* @param key 键
|
||||||
|
|
|
@ -14,10 +14,10 @@ spring:
|
||||||
nacos:
|
nacos:
|
||||||
discovery:
|
discovery:
|
||||||
# 服务注册地址
|
# 服务注册地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
config:
|
config:
|
||||||
# 配置中心地址
|
# 配置中心地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
# 配置文件格式
|
# 配置文件格式
|
||||||
file-extension: yml
|
file-extension: yml
|
||||||
# 共享配置
|
# 共享配置
|
||||||
|
@ -33,7 +33,7 @@ spring:
|
||||||
datasource:
|
datasource:
|
||||||
ds1:
|
ds1:
|
||||||
nacos:
|
nacos:
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
dataId: sentinel-muyu-gateway
|
dataId: sentinel-muyu-gateway
|
||||||
groupId: DEFAULT_GROUP
|
groupId: DEFAULT_GROUP
|
||||||
data-type: json
|
data-type: json
|
||||||
|
|
|
@ -14,10 +14,10 @@ spring:
|
||||||
nacos:
|
nacos:
|
||||||
discovery:
|
discovery:
|
||||||
# 服务注册地址
|
# 服务注册地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
config:
|
config:
|
||||||
# 配置中心地址
|
# 配置中心地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
# 配置文件格式
|
# 配置文件格式
|
||||||
file-extension: yml
|
file-extension: yml
|
||||||
# 共享配置
|
# 共享配置
|
||||||
|
|
|
@ -14,10 +14,10 @@ spring:
|
||||||
nacos:
|
nacos:
|
||||||
discovery:
|
discovery:
|
||||||
# 服务注册地址
|
# 服务注册地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
config:
|
config:
|
||||||
# 配置中心地址
|
# 配置中心地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
# 配置文件格式
|
# 配置文件格式
|
||||||
file-extension: yml
|
file-extension: yml
|
||||||
# 共享配置
|
# 共享配置
|
||||||
|
|
|
@ -14,10 +14,10 @@ spring:
|
||||||
nacos:
|
nacos:
|
||||||
discovery:
|
discovery:
|
||||||
# 服务注册地址
|
# 服务注册地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
config:
|
config:
|
||||||
# 配置中心地址
|
# 配置中心地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
# 配置文件格式
|
# 配置文件格式
|
||||||
file-extension: yml
|
file-extension: yml
|
||||||
# 共享配置
|
# 共享配置
|
||||||
|
|
|
@ -51,6 +51,9 @@ public class ProjectInfoCache extends CacheAbs<Long, ProjectInfo> {
|
||||||
return projectInfoData.getData(key);
|
return projectInfoData.getData(key);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 默认值
|
* 默认值
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -15,4 +15,6 @@ public interface ProjectInfoData {
|
||||||
* @return 缓存对象
|
* @return 缓存对象
|
||||||
*/
|
*/
|
||||||
public ProjectInfo getData (Long key);
|
public ProjectInfo getData (Long key);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,7 +8,7 @@ import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author DongZl
|
* @author DongZl
|
||||||
* @description: 缓存数据获取
|
* @description: 商品缓存数据获取
|
||||||
* @Date 2024-3-27 下午 03:37
|
* @Date 2024-3-27 下午 03:37
|
||||||
*/
|
*/
|
||||||
@Service
|
@Service
|
||||||
|
|
|
@ -72,8 +72,8 @@ public class ProjectInfoController extends BaseController {
|
||||||
/**
|
/**
|
||||||
* 获取商品信息详细信息
|
* 获取商品信息详细信息
|
||||||
*/
|
*/
|
||||||
@ApiOperation("获取商品信息详细信息")
|
@ApiOperation("获取商品信息信息")
|
||||||
@RequiresPermissions("product:info:query")
|
// @RequiresPermissions("product:info:query")
|
||||||
@GetMapping(value = "/{id}")
|
@GetMapping(value = "/{id}")
|
||||||
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "Long", paramType = "path", dataTypeClass = Long.class)
|
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "Long", paramType = "path", dataTypeClass = Long.class)
|
||||||
public Result<ProjectInfo> getInfo(@PathVariable("id") Long id) {
|
public Result<ProjectInfo> getInfo(@PathVariable("id") Long id) {
|
||||||
|
@ -84,7 +84,7 @@ public class ProjectInfoController extends BaseController {
|
||||||
* 获取商品信息详细信息
|
* 获取商品信息详细信息
|
||||||
*/
|
*/
|
||||||
@ApiOperation("获取商品信息详细信息")
|
@ApiOperation("获取商品信息详细信息")
|
||||||
@RequiresPermissions("product:info:query")
|
// @RequiresPermissions("product:info:query")
|
||||||
@GetMapping(value = "/cache/{id}")
|
@GetMapping(value = "/cache/{id}")
|
||||||
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "Long", paramType = "path", dataTypeClass = Long.class)
|
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "Long", paramType = "path", dataTypeClass = Long.class)
|
||||||
public Result<ProjectInfo> getCacheInfo(@PathVariable("id") Long id) {
|
public Result<ProjectInfo> getCacheInfo(@PathVariable("id") Long id) {
|
||||||
|
@ -95,7 +95,7 @@ public class ProjectInfoController extends BaseController {
|
||||||
* 获取商品信息详细信息
|
* 获取商品信息详细信息
|
||||||
*/
|
*/
|
||||||
@ApiOperation("获取商品信息详细信息")
|
@ApiOperation("获取商品信息详细信息")
|
||||||
@RequiresPermissions("product:info:query")
|
// @RequiresPermissions("product:info:query")
|
||||||
@GetMapping(value = "/detail/{id}")
|
@GetMapping(value = "/detail/{id}")
|
||||||
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "Long", paramType = "path", dataTypeClass = Long.class)
|
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "Long", paramType = "path", dataTypeClass = Long.class)
|
||||||
public Result<ProjectDetailResp> getDetailInfo(@PathVariable("id") Long id) {
|
public Result<ProjectDetailResp> getDetailInfo(@PathVariable("id") Long id) {
|
||||||
|
|
|
@ -14,10 +14,10 @@ spring:
|
||||||
nacos:
|
nacos:
|
||||||
discovery:
|
discovery:
|
||||||
# 服务注册地址
|
# 服务注册地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
config:
|
config:
|
||||||
# 配置中心地址
|
# 配置中心地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
# 配置文件格式
|
# 配置文件格式
|
||||||
file-extension: yml
|
file-extension: yml
|
||||||
# 共享配置
|
# 共享配置
|
||||||
|
|
|
@ -14,10 +14,10 @@ spring:
|
||||||
nacos:
|
nacos:
|
||||||
discovery:
|
discovery:
|
||||||
# 服务注册地址
|
# 服务注册地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
config:
|
config:
|
||||||
# 配置中心地址
|
# 配置中心地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
# 配置文件格式
|
# 配置文件格式
|
||||||
file-extension: yml
|
file-extension: yml
|
||||||
# 共享配置
|
# 共享配置
|
||||||
|
|
|
@ -14,10 +14,10 @@ spring:
|
||||||
nacos:
|
nacos:
|
||||||
discovery:
|
discovery:
|
||||||
# 服务注册地址
|
# 服务注册地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
config:
|
config:
|
||||||
# 配置中心地址
|
# 配置中心地址
|
||||||
server-addr: 127.0.0.1:8848
|
server-addr: 111.229.102.61:8848
|
||||||
# 配置文件格式
|
# 配置文件格式
|
||||||
file-extension: yml
|
file-extension: yml
|
||||||
# 共享配置
|
# 共享配置
|
||||||
|
|
Loading…
Reference in New Issue