Commit 7968f009 authored by tangtuo's avatar tangtuo

版权相关功能开发

parent 16f962bc
......@@ -4,7 +4,7 @@
<inspection_tool class="ArgNamesErrorsInspection" enabled="false" level="ERROR" enabled_by_default="false" />
<inspection_tool class="DuplicatedCode" enabled="true" level="WEAK WARNING" enabled_by_default="true">
<Languages>
<language minSize="57" name="Java" />
<language minSize="60" name="Java" />
</Languages>
</inspection_tool>
<inspection_tool class="JavaDoc" enabled="true" level="WARNING" enabled_by_default="true">
......
......@@ -23,6 +23,10 @@
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-amqp</artifactId>
</dependency>
<dependency>
<groupId>com.fzm</groupId>
<artifactId>joying-common</artifactId>
<version>1.0.0</version>
......@@ -36,10 +40,6 @@
<artifactId>druid-spring-boot-starter</artifactId>
</dependency>
<dependency>
<groupId>com.baomidou</groupId>
<artifactId>mybatis-plus-boot-starter</artifactId>
</dependency>
<dependency>
<groupId>com.github.xiaoymin</groupId>
<artifactId>knife4j-spring-boot-starter</artifactId>
</dependency>
......
......@@ -12,6 +12,8 @@ import com.github.pagehelper.PageInfo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
......@@ -21,13 +23,17 @@ import java.util.List;
* @author tangtuo
* @date 2021/7/5 15:34
*/
@Authentication
//@Authentication
@Slf4j
@RestController
@RequestMapping("/nft")
@Api(tags = "剧本nft管理")
public class NftController {
@Resource
private RabbitTemplate rabbitTemplate;
@Resource
private NftService nftService;
@Resource
......@@ -96,4 +102,11 @@ public class NftController {
List<NftTransferRecordVo> list = nftTransferRecordService.getTransferRecordList(nftHash, fromAddress, toAddress, startDate, endDate);
return ResponseModel.success(new PageInfo<>(list));
}
@GetMapping("/send")
public String send(@RequestParam String msg) {
rabbitTemplate.convertAndSend("copyright.direct", "copyright.apply", msg);
log.info("发送消息:{}", msg);
return "SUCCESS";
}
}
package com.fzm.admin.listener;
import cn.hutool.core.lang.TypeReference;
import cn.hutool.http.HttpUtil;
import cn.hutool.json.JSONUtil;
import com.fzm.common.config.RabbitMQConfig;
import com.fzm.common.entity.dto.CopyrightQueryRequest;
import com.fzm.common.entity.dto.CopyrightQueryResponse;
import com.fzm.common.entity.dto.CopyrightResponse;
import com.fzm.common.enums.ResultCode;
import com.fzm.common.exception.GlobalException;
import com.fzm.common.properties.CopyrightProperties;
import com.fzm.common.utils.CopyrightSignUtil;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
import java.util.TreeMap;
/**
* @author tangtuo
* @date 2021/12/23 14:56
*/
@Slf4j
@Component
public class CopyrightLister {
@Resource
private CopyrightProperties copyrightProperties;
/**
* 主动查询当前流水号对应的版权审批结果
*
* @param serial_code
*/
@RabbitListener(queues = RabbitMQConfig.COPYRIGHT_QUEUE)
public void listerCopyrightApply(String serial_code) {
log.info("监听者接收消息, 流水号为: {}", serial_code);
CopyrightQueryRequest request = new CopyrightQueryRequest(serial_code, copyrightProperties.getAppId());
TreeMap<String, String> map = this.beanToMap(request, copyrightProperties.getAppSecret());
String sign = CopyrightSignUtil.generateSign(map);
request.setSign(sign);
String json = JSONUtil.toJsonStr(request);
log.info("查询审核结果, 当前流水号为:{} , 请求参数为 : {}", serial_code, json);
String response = HttpUtil.post(copyrightProperties.getQueryUrl(), json, 10000);
log.info("查询审核结果接口响应内容: {}", response);
if (StringUtils.isBlank(response)) {
throw GlobalException.newException(ResultCode.COPYRIGHT_FAILED, "版权局接口无响应,请稍后重试");
}
CopyrightQueryResponse copyrightResponse = JSONUtil.toBean(response, CopyrightQueryResponse.class);
if (copyrightResponse == null) {
throw GlobalException.newException(ResultCode.COPYRIGHT_FAILED, "版权局接口无响应,请稍后重试");
}
if (!copyrightResponse.isSuccess()) {
throw GlobalException.newException(ResultCode.COPYRIGHT_FAILED, copyrightResponse.getMessage());
}
// 如果审核结果还是审核中的话,就继续把流水号丢进延时队列,2小时后再查一次
// 审核成功或失败的话,更新审核结果
}
private TreeMap<String, String> beanToMap(CopyrightQueryRequest request, String app_secret) {
TreeMap<String, String> map = JSONUtil.toBean(JSONUtil.toJsonStr(request), new TypeReference<TreeMap<String, String>>() {
}, true);
map.put("biz_content", JSONUtil.toJsonStr(request.getBiz_content()));
map.put("app_secret", app_secret);
return map;
}
}
......@@ -46,6 +46,19 @@ spring:
redis:
# 缓存失效时间
time-to-live: 86400000
rabbitmq:
host: 172.16.101.135
port: 5672
username: admin
password: admin
listener:
simple:
retry:
enabled: true
max-attempts: 5
initial-interval: 1000
multiplier: 2
stateless: true
swagger:
title: 乐映影视后台管理系统
description: 乐映影视后台管理系统RESTFUL API
......@@ -83,7 +96,9 @@ aliyun:
encrypt-bucket: test-nft-2
copyright:
url: https://p.yareiot.com/ccct/api/copyright/create
apply-url: https://p.yareiot.com/ccct/api/copyright/create
query-url: https://p.yareiot.com/ccct/api/copyright/query
app-id: 289391457858
app-secret: xExjKUCYH1nrze6Hpxf8s1dYWdxEggo2FiwKlZKygCItOV7E8bFhkyr4C192uhK
......@@ -47,7 +47,19 @@ spring:
redis:
# 缓存失效时间
time-to-live: 86400000
rabbitmq:
host: 10.0.0.81
port: 5672
username: admin
password: admin
listener:
simple:
retry:
enabled: true
max-attempts: 5
initial-interval: 1000
multiplier: 2
stateless: true
swagger:
title: 乐映影视乐映影视后台管理系统
description: 乐映影视后台管理系统RESTFUL API
......@@ -84,3 +96,8 @@ aliyun:
simple-bucket: test-nft
encrypt-bucket: test-nft-2
copyright:
url: https://p.yareiot.com/ccct/api/copyright/create
app-id: 289391457858
app-secret: xExjKUCYH1nrze6Hpxf8s1dYWdxEggo2FiwKlZKygCItOV7E8bFhkyr4C192uhK
server:
port: 8002
spring:
main:
allow-bean-definition-overriding: true
datasource:
url: jdbc:mysql://146.56.197.42:3306/joying?useUnicode=true&characterEncoding=utf8&useSSL=false&tinyInt1isBit=false
username: root
password: fzm_db_01@TEST
platform: mysql
type: com.alibaba.druid.pool.DruidDataSource
driver-class-name: com.mysql.cj.jdbc.Driver
druid:
initial-size: 5
min-idle: 5
max-active: 20
max-wait: 60000
time-between-eviction-runs-millis: 60000
min-evictable-idle-time-millis: 300000
validation-query: SELECT 1 FROM DUAL
test-while-idle: true
test-on-borrow: false
test-on-return: false
pool-prepared-statements: false
max-pool-prepared-statement-per-connection-size: 20
filters: stat ,wall
connection-properties: druid.stat.mergeSql=true;druid.stat.slowSqlMillis=5000
useGlobalDataSourceStat: true
redis:
database: 2
host: 146.56.218.121
port: 6379
password: fzmcache
lettuce:
pool:
# 连接池最大连接数(使用负值表示没有限制) 默认 8
max-active: 100
# 连接池最大阻塞等待时间(使用负值表示没有限制) 默认 -1
max-wait: -1
# 连接池中的最大空闲连接 默认 8
max-idle: 8
# 连接池中的最小空闲连接 默认 0
min-idle: 0
cache:
# 整合SpringCache,redis作为缓存类型
type: redis
redis:
# 缓存失效时间
time-to-live: 86400000
rabbitmq:
host: 129.211.166.223
port: 5672
username: guest
password: guest
listener:
simple:
retry:
enabled: true
max-attempts: 5
initial-interval: 1000
multiplier: 2
stateless: true
swagger:
title: 乐映影视后台管理系统
description: 乐映影视后台管理系统RESTFUL API
version: 1.0.0
base-package: com.fzm.admin.controller
base-path: /**
enabled: true
globalOperationParameters:
- description: Authorization
modelRef: string
name: Authorization
parameterType: header
required: false
contact:
name: tangtuo
email: ttuo@33.com
chain:
para:
rpc-url: http://146.56.197.42:12021
withhold-addr: 1417K9fd5vt4zYW86xinWiCbAkNP794aNy
withhold-key: 19d78691584930407e63cd35ac6e67fae6113894b41812e65847d4a365a802a0
title: user.p.mall.
admin: 133AfuMYQXRxc45JGUb1jLk1M1W4ka39L1
admin-key: 85c6c95bcb41779f1d197e686d26b228a523fa36b77cfed79edb59b8853b569b
contract-name: user.evm.0xb3ae98ac253679602d54d1513aa9cad7d1b10d5f5117d5ce999c1bf67906ba99
contract-address: 15DtbSyS4eVFxdF87jmrcAdXMSAwXEHVLW
aliyun:
oss:
app-key: LTAI5tHGn7cVJdEtihTFLSeB
app-secret: XYmfBSbLaZoblGXZwIXkbhfBD7a1eg
end-point: oss-cn-hangzhou.aliyuncs.com
simple-bucket: test-nft
encrypt-bucket: test-nft-2
copyright:
apply-url: https://p.yareiot.com/ccct/api/copyright/create
query-url: https://p.yareiot.com/ccct/api/copyright/query
app-id: 289391457858
app-secret: xExjKUCYH1nrze6Hpxf8s1dYWdxEggo2FiwKlZKygCItOV7E8bFhkyr4C192uhK
......@@ -82,3 +82,8 @@ aliyun:
simple-bucket: joying-file
encrypt-bucket: joying-nft
copyright:
url: https://p.yareiot.com/ccct/ccct/api/copyright/create
app-id: 289391457858
app-secret: xExjKUCYH1nrze6Hpxf8s1dYWdxEggo2FiwKlZKygCItOV7E8bFhkyr4C192uhK
......@@ -46,6 +46,19 @@ spring:
redis:
# 缓存失效时间
time-to-live: 86400000
rabbitmq:
host: 10.0.0.81
port: 5672
username: admin
password: admin
listener:
simple:
retry:
enabled: true
max-attempts: 5
initial-interval: 1000
multiplier: 2
stateless: true
swagger:
title: 乐映影视乐映影视后台管理系统
description: 乐映影视后台管理系统RESTFUL API
......@@ -82,3 +95,8 @@ aliyun:
simple-bucket: test-nft
encrypt-bucket: test-nft-2
copyright:
url: https://p.yareiot.com/ccct/api/copyright/create
app-id: 289391457858
app-secret: xExjKUCYH1nrze6Hpxf8s1dYWdxEggo2FiwKlZKygCItOV7E8bFhkyr4C192uhK
spring:
profiles:
active: local
active: nj
application:
name: ly-admin
......
......@@ -62,6 +62,10 @@
<appender-ref ref="CONSOLE"/>
<appender-ref ref="INFO_FILE"/>
</springProfile>
<springProfile name="nj">
<appender-ref ref="CONSOLE"/>
<appender-ref ref="INFO_FILE"/>
</springProfile>
</root>
</configuration>
\ No newline at end of file
package com.fzm.admin;
import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;
@SpringBootTest
class LyAdminApplicationTests {
@Test
void contextLoads() {
}
}
......@@ -32,6 +32,10 @@
<artifactId>spring-boot-starter-aop</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-amqp</artifactId>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-pool2</artifactId>
<version>2.0</version>
......
package com.fzm.common.config;
import org.springframework.amqp.core.*;
import org.springframework.amqp.support.converter.Jackson2JsonMessageConverter;
import org.springframework.amqp.support.converter.MessageConverter;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
* @author tangtuo
* @date 2021/12/23 13:25
*/
@Configuration
public class RabbitMQConfig {
public static final String COPYRIGHT_DIRECT = "copyright.direct";
public static final String DEAD_LETTER_DIRECT = "dl.direct";
public static final String COPYRIGHT_QUEUE = "copyright.queue";
public static final String DEAD_LETTER_QUEUE = "dl.queue";
/**
* 定义直连交换机copyright.direct
*
* @return
*/
@Bean
public DirectExchange copyrightDirect() {
return new DirectExchange(COPYRIGHT_DIRECT, true, false, null);
}
/**
* 死信交换机
*
* @return
*/
@Bean
public DirectExchange dlDirect() {
return new DirectExchange(DEAD_LETTER_DIRECT, true, false, null);
}
/**
* 存放死信的队列,用户监听这个队列
*
* @return
*/
@Bean
public Queue copyrightQueue() {
return new Queue(COPYRIGHT_QUEUE, true);
}
/**
* 定义死信队列
*
* @return
*/
@Bean
public Queue dlQueue() {
return QueueBuilder.durable(DEAD_LETTER_QUEUE)
.ttl(1000 * 60 * 60 * 2)
.deadLetterExchange(DEAD_LETTER_DIRECT)
.deadLetterRoutingKey("copyright.notify")
.build();
}
@Bean
public Binding dlBinding() {
return BindingBuilder.bind(dlQueue()).to(copyrightDirect()).with("copyright.apply");
}
@Bean
public Binding copyrightBinding() {
return BindingBuilder.bind(copyrightQueue()).to(dlDirect()).with("copyright.notify");
}
@Bean
public MessageConverter messageConverter() {
return new Jackson2JsonMessageConverter();
}
}
......@@ -35,6 +35,9 @@ public class CopyrightApply {
@ApiModelProperty(value = "nft名称")
private String nftName;
@ApiModelProperty(value = "登记委托书")
private String registerEntrust;
@ApiModelProperty(value = "作品名称")
private String opusName;
......@@ -83,6 +86,9 @@ public class CopyrightApply {
@ApiModelProperty(value = "权力归属证明材料的文件地址")
private String authorityAscriptionProve;
@ApiModelProperty(value = "作品权力保证书")
private String opusPowerGuarantee;
@ApiModelProperty(value = "申请时间")
private Date applyTime;
......
......@@ -29,6 +29,10 @@ public class CopyrightDTO {
@ApiModelProperty(value = "nft名称")
private String nftName;
@NotBlank(message = "登记委托书不能为空")
@ApiModelProperty(value = "登记委托书")
private String registerEntrust;
@NotBlank(message = "作品名称不能为空")
@ApiModelProperty(value = "作品名称")
private String opusName;
......@@ -83,17 +87,21 @@ public class CopyrightDTO {
private String authorityAcquireMode;
@NotBlank(message = "权力取得证明材料不能为空")
@ApiModelProperty(value = "权力取得证明材料的文件地址")
@ApiModelProperty(value = "权力取得证明材料")
private String authorityAcquireProve;
@NotBlank(message = "权力归属方式不能为空")
@ApiModelProperty(value = "权力归属方式")
private String authorityAscriptionMode;
@NotBlank(message = "权力归属证明材料不能为空")
@NotBlank(message = "权力归属材料不能为空")
@ApiModelProperty(value = "权力归属证明材料的文件地址")
private String authorityAscriptionProve;
@NotBlank(message = "作品权力保证书不能为空")
@ApiModelProperty(value = "作品权力保证书")
private String opusPowerGuarantee;
@NotEmpty(message = "作者列表不能为空")
@ApiModelProperty(value = "作者列表")
private List<Author> authors;
......
package com.fzm.common.entity.dto;
import cn.hutool.core.date.DateUtil;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import java.util.Date;
/**
* @author tangtuo
* @date 2021/12/23 17:26
*/
@Data
public class CopyrightQueryRequest {
private String app_id;
private String charset = "utf-8";
private String sign;
private String sign_type = "md5";
private String timestamp = DateUtil.format(new Date(), "yyyy-MM-dd HH:mm:ss");
private String version = "1.0";
private BizContent biz_content;
@Data
@AllArgsConstructor
public static class BizContent {
private String serial_code;
}
public CopyrightQueryRequest(String serial_code, String app_id) {
this.app_id = app_id;
this.biz_content = new BizContent(serial_code);
}
}
package com.fzm.common.entity.dto;
import lombok.Data;
/**
* @author tangtuo
* @date 2021/12/23 18:18
*/
@Data
public class CopyrightQueryResponse {
private Integer audit_status;
private CertificateInfo certificate;
private int code;
private CopyrightRequest.CopyrightDetail copyright_detail;
private String message;
private String remark;
private String sign;
private boolean success;
private String timestamp;
@Data
public static class CertificateInfo {
private String author_name;
private Integer cert_status;
private Integer cert_type;
private String create_time;
private String finish_time;
private Integer form_code;
private Integer is_publicity;
private Integer mail_status;
private String mail_time;
private String owner_name;
private String power_range;
private String publish_time;
private String register_code;
private String territorial_scope;
private String works_name;
private Integer works_type_code;
}
}
......@@ -25,10 +25,10 @@ import java.util.stream.Collectors;
@Data
public class CopyrightRequest {
private String app_id = "289391457858";
private String app_id;
private String charset = "utf-8";
private String sign;
private String sign_type = "RSA";
private String sign_type = "md5";
private String timestamp = DateUtil.format(new Date(), "yyyy-MM-dd HH:mm:ss");
private String version = "1.0";
private CopyrightDetail biz_content;
......@@ -42,7 +42,7 @@ public class CopyrightRequest {
@ApiModelProperty(value = "代理证明图片")//无
private String agency_photo;
@ApiModelProperty(value = "作者身份证明图片")//无
@ApiModelProperty(value = "作者身份证明图片")
private String author_photo;
@ApiModelProperty(value = "合作作者")
......@@ -54,7 +54,7 @@ public class CopyrightRequest {
@ApiModelProperty(value = "作品完成时间,格式:2021-09-10")
private String end_time;
@ApiModelProperty(value = "委托证明图片")//无
@ApiModelProperty(value = "委托证明图片")
private String entrust_photo;
@ApiModelProperty(value = "权利获得方式编码")
......@@ -144,7 +144,7 @@ public class CopyrightRequest {
public CopyrightDetail(CopyrightVo copyrightVo, OpusCategory opusCategory) {
this.affilia_photo = copyrightVo.getAuthorityAscriptionProve();
this.agency_photo = "";
this.agency_photo = copyrightVo.getRegisterEntrust();
this.author_photo = "";
this.end_address = copyrightVo.getOpusCompleteProvince() + copyrightVo.getOpusCompleteCity();
this.end_time = DateUtil.format(copyrightVo.getOpusCompleteDate(), "yyyy-MM-dd");
......@@ -182,7 +182,7 @@ public class CopyrightRequest {
copyrightVo.getAuthorities().stream().map(
Authority::getAuthority).collect(
Collectors.toList()), "、");
this.rights_guarantee_photo = "";
this.rights_guarantee_photo = copyrightVo.getOpusPowerGuarantee();
this.works_create_desc = copyrightVo.getCreateProcess();
this.works_desc = copyrightVo.getContentSynopsis();
for (CopyrightFile file : copyrightVo.getFiles()) {
......@@ -267,7 +267,7 @@ public class CopyrightRequest {
@ApiModelProperty(value = "著作权人姓名")
private String owner_name;
@ApiModelProperty(value = "署名")//无
@ApiModelProperty(value = "署名")
private String owner_sign_name;
@ApiModelProperty(value = "著作权人类别(1:自然人)")
......@@ -352,7 +352,9 @@ public class CopyrightRequest {
}
public CopyrightRequest(CopyrightVo copyrightVo,OpusCategory category) {
public CopyrightRequest(CopyrightVo copyrightVo, OpusCategory category, String app_id, String sign) {
this.biz_content = new CopyrightDetail(copyrightVo, category);
this.app_id = app_id;
this.sign = sign;
}
}
\ No newline at end of file
......@@ -24,6 +24,9 @@ public class CopyrightVo {
@ApiModelProperty(value = "用户id")
private Integer userId;
@ApiModelProperty(value = "登记委托书")
private String registerEntrust;
@ApiModelProperty(value = "nft哈希")
private String nftHash;
......@@ -78,6 +81,9 @@ public class CopyrightVo {
@ApiModelProperty(value = "权力归属证明材料的文件地址")
private String authorityAscriptionProve;
@ApiModelProperty(value = "作品权力保证书")
private String opusPowerGuarantee;
@ApiModelProperty(value = "登记状态 0-待审核 1-登记成功 2-审核失败")
private Integer registerState;
......
......@@ -13,7 +13,8 @@ import org.springframework.stereotype.Component;
@ConfigurationProperties(prefix = "copyright")
public class CopyrightProperties {
private String url;
private String applyUrl;
private String queryUrl;
private String appId;
private String appSecret;
......
......@@ -3,10 +3,12 @@ package com.fzm.common.service.impl;
import cn.hutool.core.collection.CollectionUtil;
import cn.hutool.core.date.DateTime;
import cn.hutool.core.date.DateUtil;
import cn.hutool.core.lang.TypeReference;
import cn.hutool.http.HttpUtil;
import cn.hutool.json.JSONUtil;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.fzm.common.config.RabbitMQConfig;
import com.fzm.common.constant.SystemConstant;
import com.fzm.common.entity.*;
import com.fzm.common.entity.dto.CopyrightDTO;
......@@ -18,20 +20,21 @@ import com.fzm.common.enums.CopyrightApplyState;
import com.fzm.common.enums.ResultCode;
import com.fzm.common.exception.GlobalException;
import com.fzm.common.mapper.CopyrightApplyMapper;
import com.fzm.common.properties.CopyrightProperties;
import com.fzm.common.service.*;
import com.fzm.common.utils.CopyrightSignUtil;
import com.fzm.common.utils.OssUtil;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.*;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.ExecutionException;
......@@ -80,6 +83,13 @@ public class CopyrightApplyServiceImpl extends ServiceImpl<CopyrightApplyMapper,
@Resource
private OpusCategoryService opusCategoryService;
@Resource
private CopyrightProperties copyrightProperties;
@Resource
private RabbitTemplate rabbitTemplate;
@Override
public Integer submit(CopyrightDTO copyrightDTO) {
// 判断此nft是否属于当前登录用户所有
......@@ -311,13 +321,16 @@ public class CopyrightApplyServiceImpl extends ServiceImpl<CopyrightApplyMapper,
if (CopyrightApplyState.TO_BE_REVIEWED.getCode() != copyright.getRegisterState()) {
throw GlobalException.newException(ResultCode.OPERATION_FAILED, "此版权申请记录的状态不是待提交,无法审核通过");
}
// todo 版权申请
// 请求版权局接口
CopyrightVo detail = this.getDetail(id);
OpusCategory category = opusCategoryService.getById(detail.getOpusCategoryId());
CopyrightRequest copyrightRequest = new CopyrightRequest(detail, category);
CopyrightRequest copyrightRequest = new CopyrightRequest(detail, category, copyrightProperties.getAppId(), null);
TreeMap<String, String> param = this.beanToMap(copyrightRequest, copyrightProperties.getAppSecret());
String sign = CopyrightSignUtil.generateSign(param);
copyrightRequest.setSign(sign);
String json = JSONUtil.toJsonStr(copyrightRequest);
log.info("请求版权局接口, 请求参数:{}", json);
String response = HttpUtil.post("https://p.yareiot.com/ccct/api/copyright/create", json, 10000);
log.info("请求版权局接口, 接口地址:{}, 请求参数:{}", copyrightProperties.getApplyUrl(), json);
String response = HttpUtil.post(copyrightProperties.getApplyUrl(), json, 10000);
log.info("版权局响应内容:{}", response);
if (StringUtils.isBlank(response)) {
throw GlobalException.newException(ResultCode.COPYRIGHT_FAILED, "版权局接口无响应,请稍后重试");
......@@ -329,12 +342,24 @@ public class CopyrightApplyServiceImpl extends ServiceImpl<CopyrightApplyMapper,
if (!copyrightResponse.isSuccess()) {
throw GlobalException.newException(ResultCode.COPYRIGHT_FAILED, copyrightResponse.getMessage());
}
copyright.setSerialNum(copyrightResponse.getSerial_code());
// 申请成功
String serial_code = copyrightResponse.getSerial_code();
rabbitTemplate.convertAndSend(RabbitMQConfig.COPYRIGHT_DIRECT, "copyright.apply", serial_code);
copyright.setSerialNum(serial_code);
copyright.setRegisterState(CopyrightApplyState.SUCCEEDED.getCode());
copyright.setRejectReason("");
return updateById(copyright);
}
private TreeMap<String, String> beanToMap(CopyrightRequest copyrightRequest, String app_secret) {
TreeMap<String, String> treeMap = JSONUtil.toBean(JSONUtil.toJsonStr(copyrightRequest), new TypeReference<TreeMap<String, String>>() {
}, true);
treeMap.put("biz_content", JSONUtil.toJsonStr(copyrightRequest.getBiz_content()));
treeMap.put("app_secret", app_secret);
return treeMap;
}
@Override
public int getSuccessCount() {
QueryWrapper<CopyrightApply> wrapper = new QueryWrapper<>();
......
package com.fzm.common.utils;
import cn.hutool.crypto.SecureUtil;
import cn.hutool.json.JSONUtil;
import com.fzm.common.entity.dto.CopyrightRequest;
import com.fzm.common.properties.CopyrightProperties;
import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.autoconfigure.codec.CodecProperties;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
import java.util.Map;
import java.util.TreeMap;
/**
* @author tangtuo
* @date 2021/12/23 11:40
*/
@Slf4j
public class CopyrightSignUtil {
public static String generateSign(TreeMap<String, String> param) {
StringBuilder sb = new StringBuilder();
for (Map.Entry<String, String> entry : param.entrySet()) {
String key = entry.getKey();
if ("sign".equals(key)) continue;
String value = entry.getValue();
sb.append(key).append("=").append(value).append("&");
}
String signStr = sb.deleteCharAt(sb.length() - 1).toString();
log.info("signStr: {}", signStr);
return SecureUtil.md5(signStr);
}
}
This diff is collapsed.
This diff is collapsed.
......@@ -27,7 +27,7 @@ spring:
connection-properties: druid.stat.mergeSql=true;druid.stat.slowSqlMillis=5000
useGlobalDataSourceStat: true
redis:
host: localhost
host: 172.16.101.135
port: 6379
password: 123456
lettuce:
......@@ -45,16 +45,19 @@ spring:
type: redis
redis:
time-to-live: 86400000
# rabbitmq:
# host: 172.16.101.135
# port: 5672
# username: admin
# password: admin
# listener:
# simple:
# ####开启手动签收
# acknowledge-mode: manual
rabbitmq:
host: 10.0.0.81
port: 5672
username: admin
password: admin
listener:
simple:
retry:
enabled: true
max-attempts: 5
initial-interval: 1000
multiplier: 2
stateless: true
swagger:
title: 乐映影视门户系统
description: 乐映影视门户系统RESTFUL API
......@@ -72,14 +75,6 @@ swagger:
name: tangtuo
email: ttuo@33.com
aliyun:
oss:
app-key: LTAI5tHGn7cVJdEtihTFLSeB
app-secret: XYmfBSbLaZoblGXZwIXkbhfBD7a1eg
end-point: oss-cn-hangzhou.aliyuncs.com
simple-bucket: test-nft
encrypt-bucket: test-nft-2
sms:
app-key: Yiru
app-secret: mx5oaR^RY8!(ziHn
......@@ -103,4 +98,10 @@ chain:
contract-name: user.evm.0x72ab91df57d70ddca74c219fee29a4e08632bb7b1109c1627fc11173961b180c
contract-address: 1ErrPnk5mocNL5k87Yx66ihqmprc8avjPJ
aliyun:
oss:
app-key: LTAI5tHGn7cVJdEtihTFLSeB
app-secret: XYmfBSbLaZoblGXZwIXkbhfBD7a1eg
end-point: oss-cn-hangzhou.aliyuncs.com
simple-bucket: test-nft
encrypt-bucket: test-nft-2
server:
port: 8001
spring:
main:
allow-bean-definition-overriding: true
datasource:
url: jdbc:mysql://146.56.197.42:3306/joying?useUnicode=true&characterEncoding=utf8&useSSL=false&tinyInt1isBit=false
username: root
password: fzm_db_01@TEST
platform: mysql
type: com.alibaba.druid.pool.DruidDataSource
driver-class-name: com.mysql.cj.jdbc.Driver
druid:
initial-size: 5
min-idle: 5
max-active: 20
max-wait: 60000
time-between-eviction-runs-millis: 60000
min-evictable-idle-time-millis: 300000
validation-query: SELECT 1 FROM DUAL
test-while-idle: true
test-on-borrow: false
test-on-return: false
pool-prepared-statements: false
max-pool-prepared-statement-per-connection-size: 20
filters: stat ,wall
connection-properties: druid.stat.mergeSql=true;druid.stat.slowSqlMillis=5000
useGlobalDataSourceStat: true
redis:
database: 2
host: 146.56.218.121
port: 6379
password: fzmcache
lettuce:
pool:
# 连接池最大连接数(使用负值表示没有限制) 默认 8
max-active: 100
# 连接池最大阻塞等待时间(使用负值表示没有限制) 默认 -1
max-wait: -1
# 连接池中的最大空闲连接 默认 8
max-idle: 8
# 连接池中的最小空闲连接 默认 0
min-idle: 0
cache:
# 整合SpringCache,redis作为缓存类型
type: redis
redis:
time-to-live: 86400000
swagger:
title: 乐映影视门户系统
description: 乐映影视门户系统RESTFUL API
version: 1.0.0
base-package: com.fzm.portal.controller
base-path: /**
enabled: true
globalOperationParameters:
- description: Authorization
modelRef: string
name: Authorization
parameterType: header
required: false
contact:
name: tangtuo
email: ttuo@33.com
sms:
app-key: Yiru
app-secret: mx5oaR^RY8!(ziHn
login-message-codetype: quick
login-email-codetype: quick
login-voice-codetype: quick
send-sms-url: http://118.31.52.32/send/sms2
validate-code-url: http://118.31.52.32/validate/code
transfer-nft-message-codetype: notice_transfer
transfer-nft-email-codetype: notice_transfer
transfer-nft-voice-codetype: notice_transfer
chain:
para:
rpc-url: http://146.56.197.42:12021
withhold-addr: 1417K9fd5vt4zYW86xinWiCbAkNP794aNy
withhold-key: 19d78691584930407e63cd35ac6e67fae6113894b41812e65847d4a365a802a0
title: user.p.mall.
admin: 133AfuMYQXRxc45JGUb1jLk1M1W4ka39L1
admin-key: 85c6c95bcb41779f1d197e686d26b228a523fa36b77cfed79edb59b8853b569b
contract-name: user.evm.0xb3ae98ac253679602d54d1513aa9cad7d1b10d5f5117d5ce999c1bf67906ba99
contract-address: 15DtbSyS4eVFxdF87jmrcAdXMSAwXEHVLW
aliyun:
oss:
app-key: LTAI5tHGn7cVJdEtihTFLSeB
app-secret: XYmfBSbLaZoblGXZwIXkbhfBD7a1eg
end-point: oss-cn-hangzhou.aliyuncs.com
simple-bucket: test-nft
encrypt-bucket: test-nft-2
spring:
profiles:
active: dev
active: nj
application:
name: joying-portal
servlet:
......
......@@ -62,6 +62,10 @@
<appender-ref ref="CONSOLE"/>
<appender-ref ref="INFO_FILE"/>
</springProfile>
<springProfile name="nj">
<appender-ref ref="CONSOLE"/>
<appender-ref ref="INFO_FILE"/>
</springProfile>
</root>
</configuration>
\ No newline at end of file
......@@ -3,6 +3,7 @@ package com.fzm.portal;
import cn.hutool.crypto.SecureUtil;
import java.io.File;
import java.util.TreeMap;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.Semaphore;
......@@ -13,6 +14,11 @@ import java.util.concurrent.Semaphore;
public class FileTest {
public static void main(String[] args) {
TreeMap<String, Object> paramMap = new TreeMap<>();
paramMap.put("appId", 123);
paramMap.put("bizContent", "bizContent");
paramMap.put("signType", "UTF-8");
paramMap.put("appSecret", 456);
System.out.println(paramMap);
}
}
package com.fzm.portal;
import cn.fzm.chain.simplesdk.client.ParaChainClient;
import cn.hutool.crypto.SecureUtil;
import cn.hutool.json.JSON;
import cn.hutool.json.JSONUtil;
import com.fzm.common.constant.RedisConstant;
import com.fzm.common.entity.CopyrightAuthorityRelation;
......@@ -9,6 +11,7 @@ import com.fzm.common.entity.dto.CopyrightRequest;
import com.fzm.common.entity.vo.CopyrightVo;
import com.fzm.common.enums.ResultCode;
import com.fzm.common.exception.GlobalException;
import com.fzm.common.properties.CopyrightProperties;
import com.fzm.common.service.CopyrightApplyService;
import com.fzm.common.service.CopyrightAuthorityRelationService;
import com.fzm.common.service.OpusCategoryService;
......@@ -26,6 +29,8 @@ import org.springframework.security.crypto.password.PasswordEncoder;
import javax.annotation.Resource;
import java.util.HashMap;
import java.util.Map;
import java.util.TreeMap;
import java.util.concurrent.ExecutionException;
@SpringBootTest
......@@ -52,12 +57,31 @@ class LyPortalApplicationTests {
@Resource
private OpusCategoryService opusCategoryService;
@Resource
private CopyrightProperties copyrightProperties;
@Test
void test1() throws ExecutionException, InterruptedException {
CopyrightVo detail = copyrightApplyService.getDetail(48);
OpusCategory opusCategory = opusCategoryService.getById(1);
CopyrightRequest.CopyrightDetail copyrightDetail = new CopyrightRequest.CopyrightDetail(detail, opusCategory);
// CopyrightRequest copyrightRequest = new CopyrightRequest(copyrightDetail);
// CopyrightVo detail = copyrightApplyService.getDetail(48);
// OpusCategory opusCategory = opusCategoryService.getById(1);
// CopyrightRequest copyrightRequest = new CopyrightRequest(detail, opusCategory);
// TreeMap<String, String> map = new TreeMap<>();
// map.put("app_id", "289391457858");
// map.put("app_secret", "xExjKUCYH1nrze6Hpxf8s1dYWdxEggo2FiwKlZKygCItOV7E8bFhkyr4C192uhK");
// map.put("biz_content", JSONUtil.toJsonStr(copyrightRequest.getBiz_content()));
// map.put("charset", copyrightRequest.getCharset());
// map.put("sign_type", copyrightRequest.getSign_type());
// map.put("timestamp", copyrightRequest.getTimestamp());
// map.put("version", copyrightRequest.getVersion());
// StringBuilder sb = new StringBuilder();
// for (Map.Entry<String, String> entry : map.entrySet()) {
// String key = entry.getKey();
// String value = entry.getValue();
// sb.append(key).append("=").append(value).append("&");
// }
// String signStr = sb.deleteCharAt(sb.length() - 1).toString();
// System.out.println(signStr);
// System.out.println(SecureUtil.md5(signStr));
// System.out.println(JSONUtil.toJsonStr(copyrightRequest));
}
......@@ -65,7 +89,6 @@ class LyPortalApplicationTests {
void contextLoads() {
System.out.println("redisson = " + redisson);
RSemaphore semaphore = redisson.getSemaphore("banner09");
boolean b = semaphore.trySetPermits(10);
for (int i = 0; i < 3; i++) {
boolean acquire = semaphore.tryAcquire();
......
package com.fzm.portal;
import lombok.extern.slf4j.Slf4j;
import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;
import javax.annotation.Resource;
/**
* @author tangtuo
* @date 2021/12/23 14:41
*/
@Slf4j
@SpringBootTest
public class RabbitTestDemo {
/* @Resource
private RabbitTemplate rabbitTemplate;
@Test
void test1() {
rabbitTemplate.convertAndSend("copyright.direct", "copyright.apply", 123);
log.info("发送消息-------,{}", 123);
}*/
}
This source diff could not be displayed because it is too large. You can view the blob instead.
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
2021-12-21 15:54:25.212 [main] INFO com.fzm.portal.JoyingPortalApplication-Starting JoyingPortalApplication on LAPTOP-AT8CNAMK with PID 1860 (D:\workspace\fzm-joying\joying-portal\target\classes started by tangtuo in D:\workspace\fzm-joying)
2021-12-21 15:54:25.214 [main] INFO com.fzm.portal.JoyingPortalApplication-The following profiles are active: dev
2021-12-21 15:54:26.286 [main] INFO o.s.d.r.config.RepositoryConfigurationDelegate-Multiple Spring Data modules found, entering strict repository configuration mode!
2021-12-21 15:54:26.288 [main] INFO o.s.d.r.config.RepositoryConfigurationDelegate-Bootstrapping Spring Data Redis repositories in DEFAULT mode.
2021-12-21 15:54:26.310 [main] INFO o.s.d.r.config.RepositoryConfigurationDelegate-Finished Spring Data repository scanning in 10ms. Found 0 Redis repository interfaces.
2021-12-21 15:54:27.037 [main] INFO o.s.boot.web.embedded.tomcat.TomcatWebServer-Tomcat initialized with port(s): 8001 (http)
2021-12-21 15:54:27.044 [main] INFO org.apache.coyote.http11.Http11NioProtocol-Initializing ProtocolHandler ["http-nio-8001"]
2021-12-21 15:54:27.045 [main] INFO org.apache.catalina.core.StandardService-Starting service [Tomcat]
2021-12-21 15:54:27.045 [main] INFO org.apache.catalina.core.StandardEngine-Starting Servlet engine: [Apache Tomcat/9.0.35]
2021-12-21 15:54:27.169 [main] INFO o.a.c.core.ContainerBase.[Tomcat].[localhost].[/]-Initializing Spring embedded WebApplicationContext
2021-12-21 15:54:27.169 [main] INFO org.springframework.web.context.ContextLoader-Root WebApplicationContext: initialization completed in 1915 ms
2021-12-21 15:54:27.313 [main] INFO c.a.d.s.b.a.DruidDataSourceAutoConfigure-Init DruidDataSource
2021-12-21 15:54:28.552 [main] INFO com.alibaba.druid.pool.DruidDataSource-{dataSource-1} inited
2021-12-21 15:54:30.063 [main] INFO org.redisson.Version-Redisson 3.16.0
2021-12-21 15:54:30.958 [redisson-netty-4-23] INFO o.r.connection.pool.MasterPubSubConnectionPool-1 connections initialized for 172.16.101.135/172.16.101.135:6379
2021-12-21 15:54:31.034 [redisson-netty-4-19] INFO org.redisson.connection.pool.MasterConnectionPool-24 connections initialized for 172.16.101.135/172.16.101.135:6379
2021-12-21 15:54:31.212 [main] WARN c.b.mybatisplus.core.metadata.TableInfoHelper-Warn: Could not find @TableId in Class: com.fzm.common.entity.CopyrightApplyOwnerRelation.
2021-12-21 15:54:31.300 [main] WARN c.b.mybatisplus.core.metadata.TableInfoHelper-Warn: Could not find @TableId in Class: com.fzm.common.entity.CopyrightAuthorityRelation.
2021-12-21 15:54:31.380 [main] INFO o.s.scheduling.concurrent.ThreadPoolTaskExecutor-Initializing ExecutorService 'threadPoolTaskExecutor'
2021-12-21 15:54:32.062 [main] INFO s.d.s.w.PropertySourcedRequestMappingHandlerMapping-Mapped URL path [/v2/api-docs] onto method [springfox.documentation.swagger2.web.Swagger2Controller#getDocumentation(String, HttpServletRequest)]
2021-12-21 15:54:32.627 [main] INFO org.apache.coyote.http11.Http11NioProtocol-Starting ProtocolHandler ["http-nio-8001"]
2021-12-21 15:54:32.639 [main] INFO o.s.boot.web.embedded.tomcat.TomcatWebServer-Tomcat started on port(s): 8001 (http) with context path ''
2021-12-21 15:54:32.640 [main] INFO s.d.s.web.plugins.DocumentationPluginsBootstrapper-Context refreshed
2021-12-21 15:54:32.653 [main] INFO s.d.s.web.plugins.DocumentationPluginsBootstrapper-Found 1 custom documentation plugin(s)
2021-12-21 15:54:32.680 [main] INFO s.d.spring.web.scanners.ApiListingReferenceScanner-Scanning for api listing references
2021-12-21 15:54:32.787 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_1
2021-12-21 15:54:32.799 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_2
2021-12-21 15:54:32.817 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_3
2021-12-21 15:54:32.845 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: getByIdUsingGET_1
2021-12-21 15:54:32.860 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_4
2021-12-21 15:54:32.881 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: addUsingPOST_1
2021-12-21 15:54:32.882 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: deleteUsingPOST_1
2021-12-21 15:54:32.888 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_5
2021-12-21 15:54:32.889 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: updateUsingPOST_1
2021-12-21 15:54:32.891 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: deleteUsingPOST_2
2021-12-21 15:54:32.896 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_6
2021-12-21 15:54:32.915 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: getByIdUsingGET_2
2021-12-21 15:54:32.926 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_7
2021-12-21 15:54:32.931 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: publishUsingPOST_1
2021-12-21 15:54:32.946 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: saveUsingPOST_1
2021-12-21 15:54:32.955 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: getDetailUsingGET_1
2021-12-21 15:54:32.958 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_8
2021-12-21 15:54:32.960 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_9
2021-12-21 15:54:32.961 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: deleteUsingPOST_3
2021-12-21 15:54:32.962 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: downloadUsingPOST_1
2021-12-21 15:54:32.967 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: uploadUsingPOST_1
2021-12-21 15:54:32.990 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: updateUsingPOST_2
2021-12-21 15:54:33.010 [main] INFO com.fzm.portal.JoyingPortalApplication-Started JoyingPortalApplication in 8.27 seconds (JVM running for 10.009)
2021-12-21 15:54:37.577 [SpringContextShutdownHook] INFO o.s.scheduling.concurrent.ThreadPoolTaskExecutor-Shutting down ExecutorService 'threadPoolTaskExecutor'
2021-12-21 15:54:37.622 [SpringContextShutdownHook] INFO com.alibaba.druid.pool.DruidDataSource-{dataSource-1} closing ...
2021-12-21 15:54:37.626 [SpringContextShutdownHook] INFO com.alibaba.druid.pool.DruidDataSource-{dataSource-1} closed
2021-12-22 14:20:10.146 [main] INFO com.fzm.portal.JoyingPortalApplication-Starting JoyingPortalApplication on LAPTOP-AT8CNAMK with PID 20028 (D:\workspace\fzm-joying\joying-portal\target\classes started by tangtuo in D:\workspace\fzm-joying)
2021-12-22 14:20:10.149 [main] INFO com.fzm.portal.JoyingPortalApplication-The following profiles are active: dev
2021-12-22 14:20:11.120 [main] INFO o.s.d.r.config.RepositoryConfigurationDelegate-Multiple Spring Data modules found, entering strict repository configuration mode!
2021-12-22 14:20:11.122 [main] INFO o.s.d.r.config.RepositoryConfigurationDelegate-Bootstrapping Spring Data Redis repositories in DEFAULT mode.
2021-12-22 14:20:11.153 [main] INFO o.s.d.r.config.RepositoryConfigurationDelegate-Finished Spring Data repository scanning in 11ms. Found 0 Redis repository interfaces.
2021-12-22 14:20:12.047 [main] INFO o.s.boot.web.embedded.tomcat.TomcatWebServer-Tomcat initialized with port(s): 8001 (http)
2021-12-22 14:20:12.055 [main] INFO org.apache.coyote.http11.Http11NioProtocol-Initializing ProtocolHandler ["http-nio-8001"]
2021-12-22 14:20:12.056 [main] INFO org.apache.catalina.core.StandardService-Starting service [Tomcat]
2021-12-22 14:20:12.056 [main] INFO org.apache.catalina.core.StandardEngine-Starting Servlet engine: [Apache Tomcat/9.0.35]
2021-12-22 14:20:12.199 [main] INFO o.a.c.core.ContainerBase.[Tomcat].[localhost].[/]-Initializing Spring embedded WebApplicationContext
2021-12-22 14:20:12.200 [main] INFO org.springframework.web.context.ContextLoader-Root WebApplicationContext: initialization completed in 2011 ms
2021-12-22 14:20:12.392 [main] INFO c.a.d.s.b.a.DruidDataSourceAutoConfigure-Init DruidDataSource
2021-12-22 14:20:13.891 [main] INFO com.alibaba.druid.pool.DruidDataSource-{dataSource-1} inited
2021-12-22 14:20:15.407 [main] INFO org.redisson.Version-Redisson 3.16.0
2021-12-22 14:20:16.248 [redisson-netty-4-13] INFO o.r.connection.pool.MasterPubSubConnectionPool-1 connections initialized for 172.16.101.135/172.16.101.135:6379
2021-12-22 14:20:16.368 [redisson-netty-4-20] INFO org.redisson.connection.pool.MasterConnectionPool-24 connections initialized for 172.16.101.135/172.16.101.135:6379
2021-12-22 14:20:16.684 [main] WARN c.b.mybatisplus.core.metadata.TableInfoHelper-Warn: Could not find @TableId in Class: com.fzm.common.entity.CopyrightApplyOwnerRelation.
2021-12-22 14:20:16.762 [main] WARN c.b.mybatisplus.core.metadata.TableInfoHelper-Warn: Could not find @TableId in Class: com.fzm.common.entity.CopyrightAuthorityRelation.
2021-12-22 14:20:16.829 [main] INFO o.s.scheduling.concurrent.ThreadPoolTaskExecutor-Initializing ExecutorService 'threadPoolTaskExecutor'
2021-12-22 14:20:17.439 [main] INFO s.d.s.w.PropertySourcedRequestMappingHandlerMapping-Mapped URL path [/v2/api-docs] onto method [springfox.documentation.swagger2.web.Swagger2Controller#getDocumentation(String, HttpServletRequest)]
2021-12-22 14:20:18.020 [main] INFO org.apache.coyote.http11.Http11NioProtocol-Starting ProtocolHandler ["http-nio-8001"]
2021-12-22 14:20:18.032 [main] INFO o.s.boot.web.embedded.tomcat.TomcatWebServer-Tomcat started on port(s): 8001 (http) with context path ''
2021-12-22 14:20:18.033 [main] INFO s.d.s.web.plugins.DocumentationPluginsBootstrapper-Context refreshed
2021-12-22 14:20:18.046 [main] INFO s.d.s.web.plugins.DocumentationPluginsBootstrapper-Found 1 custom documentation plugin(s)
2021-12-22 14:20:18.073 [main] INFO s.d.spring.web.scanners.ApiListingReferenceScanner-Scanning for api listing references
2021-12-22 14:20:18.179 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_1
2021-12-22 14:20:18.191 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_2
2021-12-22 14:20:18.209 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_3
2021-12-22 14:20:18.235 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: getByIdUsingGET_1
2021-12-22 14:20:18.252 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_4
2021-12-22 14:20:18.272 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: addUsingPOST_1
2021-12-22 14:20:18.273 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: deleteUsingPOST_1
2021-12-22 14:20:18.279 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_5
2021-12-22 14:20:18.281 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: updateUsingPOST_1
2021-12-22 14:20:18.282 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: deleteUsingPOST_2
2021-12-22 14:20:18.287 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_6
2021-12-22 14:20:18.307 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: getByIdUsingGET_2
2021-12-22 14:20:18.319 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_7
2021-12-22 14:20:18.324 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: publishUsingPOST_1
2021-12-22 14:20:18.339 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: saveUsingPOST_1
2021-12-22 14:20:18.347 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: getDetailUsingGET_1
2021-12-22 14:20:18.350 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_8
2021-12-22 14:20:18.353 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: listUsingGET_9
2021-12-22 14:20:18.354 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: deleteUsingPOST_3
2021-12-22 14:20:18.355 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: downloadUsingPOST_1
2021-12-22 14:20:18.359 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: uploadUsingPOST_1
2021-12-22 14:20:18.382 [main] INFO s.d.s.w.r.operation.CachingOperationNameGenerator-Generating unique operation named: updateUsingPOST_2
2021-12-22 14:20:18.401 [main] INFO com.fzm.portal.JoyingPortalApplication-Started JoyingPortalApplication in 8.673 seconds (JVM running for 10.384)
2021-12-22 14:20:40.874 [http-nio-8001-exec-5] INFO o.a.c.core.ContainerBase.[Tomcat].[localhost].[/]-Initializing Spring DispatcherServlet 'dispatcherServlet'
2021-12-22 14:20:40.874 [http-nio-8001-exec-5] INFO org.springframework.web.servlet.DispatcherServlet-Initializing Servlet 'dispatcherServlet'
2021-12-22 14:20:40.881 [http-nio-8001-exec-5] INFO org.springframework.web.servlet.DispatcherServlet-Completed initialization in 7 ms
2021-12-22 14:21:32.072 [http-nio-8001-exec-9] INFO com.fzm.portal.aop.LogAop-请求路径: /open/nft/hash,请求参数:[{tokenId=1431186204212203520}]
2021-12-22 14:21:32.165 [http-nio-8001-exec-9] DEBUG com.fzm.common.mapper.NftMapper.selectOne-==> Preparing: SELECT id,category_id,user_id,publish_address,name,cover,author,synopsis,file_name,file_url,file_hash,nft_id,nft_hash,token_id,publish_time,transfer_hash,commemorate_id,is_top,status,is_commemorate,create_date,update_date,create_time,update_time FROM tb_nft WHERE (token_id = ?)
2021-12-22 14:21:32.259 [http-nio-8001-exec-9] DEBUG com.fzm.common.mapper.NftMapper.selectOne-==> Parameters: 1431186204212203520(Long)
2021-12-22 14:21:32.322 [http-nio-8001-exec-9] DEBUG com.fzm.common.mapper.NftMapper.selectOne-<== Total: 1
2021-12-22 14:21:32.336 [http-nio-8001-exec-9] INFO com.fzm.portal.aop.LogAop-请求路径:/open/nft/hash,接口耗时:268ms
This diff is collapsed.
......@@ -17,7 +17,7 @@
<parent>
<artifactId>spring-boot-starter-parent</artifactId>
<groupId>org.springframework.boot</groupId>
<version>2.3.0.RELEASE</version>
<version>2.3.9.RELEASE</version>
</parent>
<dependencies>
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment