Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
fzm-joying
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lei
fzm-joying
Commits
a3a8196c
Commit
a3a8196c
authored
Jul 30, 2021
by
tangtuo
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev_1.0.0' into test_v1.0.0
parents
1df7a95b
0a8b76e3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
352 additions
and
207 deletions
+352
-207
application-dev.yml
joying-admin/src/main/resources/application-dev.yml
+23
-27
application-local.yml
joying-admin/src/main/resources/application-local.yml
+23
-27
application-prod.yml
joying-admin/src/main/resources/application-prod.yml
+84
-0
application-test.yml
joying-admin/src/main/resources/application-test.yml
+23
-27
logback-spring.xml
joying-admin/src/main/resources/logback-spring.xml
+5
-0
pom.xml
joying-common/pom.xml
+0
-5
RedissonClusterConfig.java
...ain/java/com/fzm/common/config/RedissonClusterConfig.java
+0
-18
RedissonConfig.java
...n/src/main/java/com/fzm/common/config/RedissonConfig.java
+1
-2
NftVo.java
...-common/src/main/java/com/fzm/common/entity/vo/NftVo.java
+5
-1
NftService.java
...mmon/src/main/java/com/fzm/common/service/NftService.java
+2
-1
NftServiceImpl.java
...main/java/com/fzm/common/service/impl/NftServiceImpl.java
+5
-4
OssUtil.java
...ng-common/src/main/java/com/fzm/common/utils/OssUtil.java
+8
-7
SmsUtil.java
...ng-common/src/main/java/com/fzm/common/utils/SmsUtil.java
+0
-4
NftMapper.xml
joying-common/src/main/resources/mapper/NftMapper.xml
+1
-0
NftController.java
...rc/main/java/com/fzm/portal/controller/NftController.java
+3
-3
application-dev.yml
joying-portal/src/main/resources/application-dev.yml
+23
-27
application-local.yml
joying-portal/src/main/resources/application-local.yml
+23
-27
application-prod.yml
joying-portal/src/main/resources/application-prod.yml
+95
-0
application-test.yml
joying-portal/src/main/resources/application-test.yml
+23
-27
logback-spring.xml
joying-portal/src/main/resources/logback-spring.xml
+5
-0
joying.sql
sql/joying.sql
+0
-0
No files found.
joying-admin/src/main/resources/application-dev.yml
View file @
a3a8196c
...
...
@@ -3,33 +3,29 @@ server:
spring
:
main
:
allow-bean-definition-overriding
:
true
shardingsphere
:
datasource
:
names
:
write,read
# 主数据源
write
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.135:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
# 从数据源
read
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.136:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
masterslave
:
# 读写分离配置
load-balance-algorithm-type
:
round_robin
# 最终的数据源名称
name
:
dataSource
# 主库数据源名称
master-data-source-name
:
write
# 从库数据源名称列表,多个逗号分隔
slave-data-source-names
:
read
datasource
:
url
:
jdbc:mysql://172.16.101.135:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
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
:
host
:
172.16.101.135
port
:
6379
...
...
joying-admin/src/main/resources/application-local.yml
View file @
a3a8196c
...
...
@@ -3,33 +3,29 @@ server:
spring
:
main
:
allow-bean-definition-overriding
:
true
shardingsphere
:
datasource
:
names
:
write,read
# 主数据源
write
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.135:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
# 从数据源
read
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.136:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
masterslave
:
# 读写分离配置
load-balance-algorithm-type
:
round_robin
# 最终的数据源名称
name
:
dataSource
# 主库数据源名称
master-data-source-name
:
write
# 从库数据源名称列表,多个逗号分隔
slave-data-source-names
:
read
datasource
:
url
:
jdbc:mysql://172.16.101.135:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
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
:
host
:
172.16.101.135
...
...
joying-admin/src/main/resources/application-prod.yml
0 → 100644
View file @
a3a8196c
server
:
port
:
8002
spring
:
main
:
allow-bean-definition-overriding
:
true
datasource
:
url
:
jdbc:mysql://rm-uf65dutlz01018ctc33150.mysql.rds.aliyuncs.com:3306/joying?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
inmvochain
password
:
db$95872!com@inmvo
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
:
host
:
r-uf65vh5nip6yjfgtcn.redis.rds.aliyuncs.com
port
:
6379
password
:
db$95872!com@inmvo
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.admin.controller
base-path
:
/**
enabled
:
false
globalOperationParameters
:
-
description
:
Authorization
modelRef
:
string
name
:
Authorization
parameterType
:
header
required
:
false
contact
:
name
:
tangtuo
email
:
ttuo@33.com
chain
:
para
:
rpc-url
:
http://47.243.127.76:8901
withhold-addr
:
1Ae6FfgdYJn6LLaqDoRjwga3j4TTmMq3t7
withhold-key
:
a4c49dcb35e0032dc8db5891dc81481943b68fc558ce93ce74d0382c1d104934
title
:
user.p.FilmChain
admin
:
16naUoLwjNUgMhGVRmL3xTVpCso2DJp8JZ
admin-key
:
8cd19e9bf39055f95e3e33cc1e08b9f9fc2e9be48a5b3a4d401e64041c97aec7
contract-name
:
user.evm.0xd996a3a866c577596df260844a045a068ec5accd8d71ccaa3d578c9617ec5490
contract-address
:
1iDWTHZQxPES4hLveZRcwJH6AMaMfZfZZ
aliyun
:
oss
:
app-key
:
LTAI5tAAXBCtnQ2ytwagazjt
app-secret
:
x0T6hyJvRFLtPjZYrNo5egEc4kShlU
end-point
:
oss-cn-shanghai.aliyuncs.com
simple-bucket
:
joying-file
encrypt-bucket
:
joying-nft
joying-admin/src/main/resources/application-test.yml
View file @
a3a8196c
...
...
@@ -3,33 +3,29 @@ server:
spring
:
main
:
allow-bean-definition-overriding
:
true
shardingsphere
:
datasource
:
names
:
write,read
# 主数据源
write
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.135:3306/joying_test?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
# 从数据源
read
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.136:3306/joying_test?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
masterslave
:
# 读写分离配置
load-balance-algorithm-type
:
round_robin
# 最终的数据源名称
name
:
dataSource
# 主库数据源名称
master-data-source-name
:
write
# 从库数据源名称列表,多个逗号分隔
slave-data-source-names
:
read
datasource
:
url
:
jdbc:mysql://172.16.101.135:3306/joying_test?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
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
:
host
:
172.16.101.136
port
:
6379
...
...
joying-admin/src/main/resources/logback-spring.xml
View file @
a3a8196c
...
...
@@ -58,6 +58,10 @@
<appender-ref
ref=
"CONSOLE"
/>
<appender-ref
ref=
"INFO_FILE"
/>
</springProfile>
<springProfile
name=
"prod"
>
<appender-ref
ref=
"CONSOLE"
/>
<appender-ref
ref=
"INFO_FILE"
/>
</springProfile>
</root>
</configuration>
\ No newline at end of file
joying-common/pom.xml
View file @
a3a8196c
...
...
@@ -80,11 +80,6 @@
</dependency>
<dependency>
<groupId>
org.apache.shardingsphere
</groupId>
<artifactId>
sharding-jdbc-spring-boot-starter
</artifactId>
</dependency>
<dependency>
<groupId>
org.redisson
</groupId>
<artifactId>
redisson
</artifactId>
</dependency>
...
...
joying-common/src/main/java/com/fzm/common/config/RedissonClusterConfig.java
deleted
100644 → 0
View file @
1df7a95b
package
com
.
fzm
.
common
.
config
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.context.annotation.Profile
;
/**
* @author tangtuo
* @date 2021/7/19 10:25
* <p>
* 集群版redisson客户端配置
* </p>
*/
@Profile
({
"prod"
})
@Configuration
public
class
RedissonClusterConfig
{
}
joying-common/src/main/java/com/fzm/common/config/Redisson
Single
Config.java
→
joying-common/src/main/java/com/fzm/common/config/RedissonConfig.java
View file @
a3a8196c
...
...
@@ -17,9 +17,8 @@ import javax.annotation.Resource;
* 单机版redisson客户端配置
* </p>
*/
@Profile
({
"dev"
,
"local"
,
"test"
})
@Configuration
public
class
Redisson
Single
Config
{
public
class
RedissonConfig
{
@Resource
RedisProperties
redisProperties
;
...
...
joying-common/src/main/java/com/fzm/common/entity/vo/NftVo.java
View file @
a3a8196c
...
...
@@ -53,6 +53,9 @@ public class NftVo {
@ApiModelProperty
(
"文件地址"
)
private
String
fileUrl
;
@ApiModelProperty
(
"nft哈希"
)
private
String
nftHash
;
@ApiModelProperty
(
"发行时间"
)
private
String
publishTime
;
...
...
@@ -96,6 +99,7 @@ public class NftVo {
this
.
collection
=
false
;
this
.
fileName
=
nft
.
getFileName
();
this
.
fileUrl
=
nft
.
getFileUrl
();
this
.
isCommemorate
=
nft
.
getIsCommemorate
();
this
.
isCommemorate
=
nft
.
getIsCommemorate
();
this
.
nftHash
=
nft
.
getNftHash
();
}
}
joying-common/src/main/java/com/fzm/common/service/NftService.java
View file @
a3a8196c
...
...
@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.service.IService;
import
com.fzm.common.entity.Nft
;
import
com.fzm.common.entity.NftDto
;
import
com.fzm.common.entity.vo.CollectionNftVo
;
import
com.fzm.common.entity.vo.NftCertificateVo
;
import
com.fzm.common.entity.vo.NftListVo
;
import
com.fzm.common.params.NftTransferParam
;
import
com.github.pagehelper.PageInfo
;
...
...
@@ -126,7 +127,7 @@ public interface NftService extends IService<Nft> {
* @param nftDto
* @return
*/
Boolean
publish
(
NftDto
nftDto
);
Integer
publish
(
NftDto
nftDto
);
/**
* nft转让
...
...
joying-common/src/main/java/com/fzm/common/service/impl/NftServiceImpl.java
View file @
a3a8196c
...
...
@@ -15,6 +15,7 @@ import com.fzm.common.constant.SystemConstant;
import
com.fzm.common.entity.*
;
import
com.fzm.common.entity.dto.ChainDto
;
import
com.fzm.common.entity.vo.CollectionNftVo
;
import
com.fzm.common.entity.vo.NftCertificateVo
;
import
com.fzm.common.entity.vo.NftListVo
;
import
com.fzm.common.enums.ResultCode
;
import
com.fzm.common.exception.GlobalException
;
...
...
@@ -99,7 +100,7 @@ public class NftServiceImpl extends ServiceImpl<NftMapper, Nft> implements NftSe
}
@Override
public
Boolean
publish
(
NftDto
nftDto
)
{
public
Integer
publish
(
NftDto
nftDto
)
{
User
user
=
userService
.
getUserByToken
();
String
wallet
=
user
.
getWallet
();
// 获取用户的私钥
...
...
@@ -145,7 +146,7 @@ public class NftServiceImpl extends ServiceImpl<NftMapper, Nft> implements NftSe
userService
.
updateById
(
u
);
redisUtil
.
delete
(
"user::statistic"
);
}
return
true
;
return
nft
.
getId
()
;
}
@Override
...
...
@@ -160,7 +161,7 @@ public class NftServiceImpl extends ServiceImpl<NftMapper, Nft> implements NftSe
throw
GlobalException
.
newException
(
ResultCode
.
TRANSFER_ERROR
,
"您无权转让他人的nft"
);
}
// 校验短信验证码
if
(!
Objects
.
equals
(
"8888"
,
param
.
getCode
())
&&
!
smsUtil
.
validateCode
(
getCodeType
(
param
.
getCodeType
()),
user
.
getTelephone
(),
param
.
getCode
(),
param
.
getCodeType
()))
{
if
(!
smsUtil
.
validateCode
(
getCodeType
(
param
.
getCodeType
()),
user
.
getTelephone
(),
param
.
getCode
(),
param
.
getCodeType
()))
{
throw
GlobalException
.
newException
(
ResultCode
.
TRANSFER_ERROR
,
"短信验证码校验失败"
);
}
// 校验接收人的个人信息
...
...
@@ -287,7 +288,7 @@ public class NftServiceImpl extends ServiceImpl<NftMapper, Nft> implements NftSe
throw
GlobalException
.
newException
(
ResultCode
.
DATA_ERROR
,
"没找到此类目"
);
}
int
code
=
RandomUtil
.
randomInt
(
1000
,
10000
);
return
String
.
format
(
"
YIMU
-%s-%s%s"
,
category
.
getEnglishName
(),
System
.
currentTimeMillis
(),
code
);
return
String
.
format
(
"
INMVO
-%s-%s%s"
,
category
.
getEnglishName
(),
System
.
currentTimeMillis
(),
code
);
}
@Override
...
...
joying-common/src/main/java/com/fzm/common/utils/OssUtil.java
View file @
a3a8196c
...
...
@@ -187,20 +187,21 @@ public class OssUtil {
public
static
void
main
(
String
[]
args
)
{
String
endpoint
=
"oss-cn-
hangzhou
.aliyuncs.com"
;
String
endpoint
=
"oss-cn-
shanghai
.aliyuncs.com"
;
// 阿里云主账号AccessKey拥有所有API的访问权限,风险很高。强烈建议您创建并使用RAM账号进行API访问或日常运维,请登录RAM控制台创建RAM账号。
String
accessKeyId
=
"LTAI5t
HGn7cVJdEtihTFLSeB
"
;
String
accessKeySecret
=
"
XYmfBSbLaZoblGXZwIXkbhfBD7a1eg
"
;
String
accessKeyId
=
"LTAI5t
AAXBCtnQ2ytwagazjt
"
;
String
accessKeySecret
=
"
x0T6hyJvRFLtPjZYrNo5egEc4kShlU
"
;
OSS
ossClient
=
new
OSSClientBuilder
().
build
(
endpoint
,
accessKeyId
,
accessKeySecret
);
// 创建存储空间。
String
bucket
=
"test-nft-2"
;
if
(!
ossClient
.
doesBucketExist
(
bucket
))
{
String
bucket2
=
"joying-nft"
;
if
(
ossClient
.
doesBucketExist
(
bucket2
))
{
// 设置Bucket加密。
ServerSideEncryptionByDefault
applyServerSideEncryptionByDefault
=
new
ServerSideEncryptionByDefault
(
SSEAlgorithm
.
AES256
);
ServerSideEncryptionConfiguration
sseConfig
=
new
ServerSideEncryptionConfiguration
();
sseConfig
.
setApplyServerSideEncryptionByDefault
(
applyServerSideEncryptionByDefault
);
SetBucketEncryptionRequest
request
=
new
SetBucketEncryptionRequest
(
bucket
,
sseConfig
);
SetBucketEncryptionRequest
request
=
new
SetBucketEncryptionRequest
(
bucket
2
,
sseConfig
);
ossClient
.
setBucketEncryption
(
request
);
ossClient
.
shutdown
();
}
...
...
joying-common/src/main/java/com/fzm/common/utils/SmsUtil.java
View file @
a3a8196c
...
...
@@ -91,10 +91,6 @@ public class SmsUtil {
* @return
*/
public
Boolean
validateCode
(
String
codetype
,
String
mobile
,
String
code
,
String
type
)
{
// todo 方便测试,事后要删除
if
(
"8888"
.
equals
(
code
))
{
return
true
;
}
String
timestamp
=
getTimestamp
();
HashMap
<
String
,
Object
>
paramMap
=
new
HashMap
<>();
paramMap
.
put
(
"t"
,
type
);
...
...
joying-common/src/main/resources/mapper/NftMapper.xml
View file @
a3a8196c
...
...
@@ -15,6 +15,7 @@
<select
id=
"getCollectionList"
resultType=
"com.fzm.common.entity.vo.CollectionNftVo"
>
select a.id,
a.name,
a.cover,
a.theme,
a.nft_id,
a.is_commemorate,
...
...
joying-portal/src/main/java/com/fzm/portal/controller/NftController.java
View file @
a3a8196c
...
...
@@ -85,9 +85,9 @@ public class NftController {
@Authentication
@PostMapping
(
"/publish"
)
@ApiOperation
(
"发行nft"
)
public
ResponseModel
<
Boolean
>
publish
(
@Validated
@RequestBody
NftDto
nftDto
)
{
Boolean
result
=
nftService
.
publish
(
nftDto
);
return
ResponseModel
.
success
(
result
);
public
ResponseModel
<
Integer
>
publish
(
@Validated
@RequestBody
NftDto
nftDto
)
{
Integer
id
=
nftService
.
publish
(
nftDto
);
return
ResponseModel
.
success
(
id
);
}
@GetMapping
(
"/list"
)
...
...
joying-portal/src/main/resources/application-dev.yml
View file @
a3a8196c
...
...
@@ -3,33 +3,29 @@ server:
spring
:
main
:
allow-bean-definition-overriding
:
true
shardingsphere
:
datasource
:
names
:
write,read
# 主数据源
write
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.135:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
# 从数据源
read
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.136:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
masterslave
:
# 读写分离配置
load-balance-algorithm-type
:
round_robin
# 最终的数据源名称
name
:
dataSource
# 主库数据源名称
master-data-source-name
:
write
# 从库数据源名称列表,多个逗号分隔
slave-data-source-names
:
read
datasource
:
url
:
jdbc:mysql://172.16.101.135:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
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
:
host
:
172.16.101.135
port
:
6379
...
...
joying-portal/src/main/resources/application-local.yml
View file @
a3a8196c
...
...
@@ -3,33 +3,29 @@ server:
spring
:
main
:
allow-bean-definition-overriding
:
true
shardingsphere
:
datasource
:
names
:
write,read
# 主数据源
write
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.135:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
# 从数据源
read
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.136:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
masterslave
:
# 读写分离配置
load-balance-algorithm-type
:
round_robin
# 最终的数据源名称
name
:
dataSource
# 主库数据源名称
master-data-source-name
:
write
# 从库数据源名称列表,多个逗号分隔
slave-data-source-names
:
read
datasource
:
url
:
jdbc:mysql://172.16.101.135:3306/joying_dev?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
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
:
host
:
localhost
port
:
6379
...
...
joying-portal/src/main/resources/application-prod.yml
0 → 100644
View file @
a3a8196c
server
:
port
:
8001
spring
:
main
:
allow-bean-definition-overriding
:
true
datasource
:
url
:
jdbc:mysql://rm-uf65dutlz01018ctc33150.mysql.rds.aliyuncs.com:3306/joying?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
inmvochain
password
:
db$95872!com@inmvo
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
:
host
:
r-uf65vh5nip6yjfgtcn.redis.rds.aliyuncs.com
port
:
6379
password
:
db$95872!com@inmvo
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
:
false
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://47.243.127.76:8901
withhold-addr
:
1Ae6FfgdYJn6LLaqDoRjwga3j4TTmMq3t7
withhold-key
:
a4c49dcb35e0032dc8db5891dc81481943b68fc558ce93ce74d0382c1d104934
title
:
user.p.FilmChain
admin
:
1N2ABERwHgxGhebVw6fVSwaQ5uLAysmGEu
admin-key
:
4e92bda2477ded0e7c07a9e3acd2370de8d7401c68cc83ee8376806db3121e77
contract-name
:
user.evm.0xd996a3a866c577596df260844a045a068ec5accd8d71ccaa3d578c9617ec5490
contract-address
:
1iDWTHZQxPES4hLveZRcwJH6AMaMfZfZZ
aliyun
:
oss
:
app-key
:
LTAI5tAAXBCtnQ2ytwagazjt
app-secret
:
x0T6hyJvRFLtPjZYrNo5egEc4kShlU
end-point
:
oss-cn-shanghai.aliyuncs.com
simple-bucket
:
joying-file
encrypt-bucket
:
joying-nft
joying-portal/src/main/resources/application-test.yml
View file @
a3a8196c
...
...
@@ -3,33 +3,29 @@ server:
spring
:
main
:
allow-bean-definition-overriding
:
true
shardingsphere
:
datasource
:
names
:
write,read
# 主数据源
write
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.135:3306/joying_test?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
# 从数据源
read
:
type
:
com.alibaba.druid.pool.DruidDataSource
driver-class-name
:
com.mysql.cj.jdbc.Driver
url
:
jdbc:mysql://172.16.101.136:3306/joying_test?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
masterslave
:
# 读写分离配置
load-balance-algorithm-type
:
round_robin
# 最终的数据源名称
name
:
dataSource
# 主库数据源名称
master-data-source-name
:
write
# 从库数据源名称列表,多个逗号分隔
slave-data-source-names
:
read
datasource
:
url
:
jdbc:mysql://172.16.101.135:3306/joying_test?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf8
username
:
root
password
:
Joying@123456
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
:
host
:
172.16.101.136
port
:
6379
...
...
joying-portal/src/main/resources/logback-spring.xml
View file @
a3a8196c
...
...
@@ -58,6 +58,10 @@
<appender-ref
ref=
"CONSOLE"
/>
<appender-ref
ref=
"INFO_FILE"
/>
</springProfile>
<springProfile
name=
"prod"
>
<appender-ref
ref=
"CONSOLE"
/>
<appender-ref
ref=
"INFO_FILE"
/>
</springProfile>
</root>
</configuration>
\ No newline at end of file
sql/joying.sql
View file @
a3a8196c
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment