Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
涂亚平
/
subsidy
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 27f572f1
authored
Nov 24, 2022
by
涂亚平
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
监管版本/online版本上线了
1 parent
8c908d8a
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
16 deletions
src/main/java/com/subsidy/service/impl/VodPlayHistoryServiceImpl.java
src/main/resources/application.properties
src/main/java/com/subsidy/service/impl/VodPlayHistoryServiceImpl.java
View file @
27f572f
...
@@ -631,7 +631,7 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
...
@@ -631,7 +631,7 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
public
HashSet
<
Long
>
testPlays
(
VodPlayHistoryDO
vodPlayHistoryDO
)
{
public
HashSet
<
Long
>
testPlays
(
VodPlayHistoryDO
vodPlayHistoryDO
)
{
String
classIds
=
"
286,292,350,355,302,366,379,367,368,371,374,373
"
;
String
classIds
=
"
374,375,376,377,378,379,382,383,384,385,386,387,388,389,390,391,392,393,394,395
"
;
String
[]
classIdArr
=
classIds
.
split
(
","
);
String
[]
classIdArr
=
classIds
.
split
(
","
);
...
@@ -647,20 +647,20 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
...
@@ -647,20 +647,20 @@ public class VodPlayHistoryServiceImpl extends ServiceImpl<VodPlayHistoryMapper,
VodPlayStateVO
vodPlayStateVO1
=
vodPlayStateVOS
.
get
(
i
);
//前面
VodPlayStateVO
vodPlayStateVO1
=
vodPlayStateVOS
.
get
(
i
);
//前面
if
(
vodPlayStateVO1
.
getEndDate
().
getTime
()
-
3000
>
vodPlayStateVO
.
getStartDate
().
getTime
()
&&
vodPlayStateVO
.
getPlayLength
()
>=
3
)
{
if
(
vodPlayStateVO1
.
getEndDate
().
getTime
()
-
3000
>
vodPlayStateVO
.
getStartDate
().
getTime
()
&&
vodPlayStateVO
.
getPlayLength
()
>=
3
)
{
//这一条数据有问题
//这一条数据有问题
System
.
out
.
println
(
"111111111111111111111"
+
vodPlayStateVO
);
//
System.out.println("111111111111111111111" + vodPlayStateVO);
//
//查看这个人 这个课程 当天的全部数据 按照createDate升序排序
//查看这个人 这个课程 当天的全部数据 按照createDate升序排序
//
List<VodPlayHistoryDO> vodPlayHistoryDOS = this.baseMapper.getVodPlayDay(Long.valueOf(classId), classMemberMappingDO.getMemberId(), vodPlayStateVO.getStartDate());
List
<
VodPlayHistoryDO
>
vodPlayHistoryDOS
=
this
.
baseMapper
.
getVodPlayDay
(
Long
.
valueOf
(
classId
),
classMemberMappingDO
.
getMemberId
(),
vodPlayStateVO
.
getStartDate
());
//
//从第一条开始看,顺延减去第二条的playlength得到第二条的create_date 以此类推
//从第一条开始看,顺延减去第二条的playlength得到第二条的create_date 以此类推
//
for (int l = 0; l < vodPlayHistoryDOS.size() - 1; l++) {
for
(
int
l
=
0
;
l
<
vodPlayHistoryDOS
.
size
()
-
1
;
l
++)
{
//
VodPlayHistoryDO vph1 = vodPlayHistoryDOS.get(l); //第一条
VodPlayHistoryDO
vph1
=
vodPlayHistoryDOS
.
get
(
l
);
//第一条
//
if (l==0){
if
(
l
==
0
){
//
vph1.setPlayDate(vph1.getCreateDate());
vph1
.
setPlayDate
(
vph1
.
getCreateDate
());
//
}
}
//
VodPlayHistoryDO vph2 = vodPlayHistoryDOS.get(l + 1); //第二条
VodPlayHistoryDO
vph2
=
vodPlayHistoryDOS
.
get
(
l
+
1
);
//第二条
//
LocalDateTime dateTmp = vph1.getPlayDate().plusSeconds(vph2.getPlayLength()+getRandom1_2());
LocalDateTime
dateTmp
=
vph1
.
getPlayDate
().
plusSeconds
(
vph2
.
getPlayLength
()+
getRandom1_2
());
//
vph2.setPlayDate(dateTmp);
vph2
.
setPlayDate
(
dateTmp
);
//
this.baseMapper.updateById(vph2);
this
.
baseMapper
.
updateById
(
vph2
);
//
}
}
result
.
add
(
vodPlayStateVO
.
getId
());
result
.
add
(
vodPlayStateVO
.
getId
());
// break;
// break;
}
}
...
...
src/main/resources/application.properties
View file @
27f572f
# 环境配置
# 环境配置
spring.profiles.active
=
online
spring.profiles.active
=
prod
#和CPU数
#和CPU数
spring.server.acceptorThreadCount
=
600
spring.server.acceptorThreadCount
=
600
spring.server.minSpareThreads
=
100
spring.server.minSpareThreads
=
100
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment