Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
marketing
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
3
Issues
3
List
Board
Labels
Milestones
Merge Requests
3
Merge Requests
3
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
dingjy
marketing
Commits
eeee45e8
Commit
eeee45e8
authored
Mar 27, 2024
by
宋新宇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
短剧APP归因
parent
7b733013
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
5 deletions
+22
-5
DyVideoUniversalProcess.java
...m/lwby/marketing/att/dyvideo/DyVideoUniversalProcess.java
+8
-0
DyvideoBehaviorFlow.java
...wby/marketing/att/dyvideo/handle/DyvideoBehaviorFlow.java
+4
-4
AttrController.java
...in/java/com/lwby/marketing/controller/AttrController.java
+9
-0
application-prod.yml
src/main/resources/application-prod.yml
+1
-1
No files found.
src/main/java/com/lwby/marketing/att/dyvideo/DyVideoUniversalProcess.java
View file @
eeee45e8
...
...
@@ -87,10 +87,18 @@ public class DyVideoUniversalProcess extends UniversalProcess {
oldMarketRedisTemplate
.
opsForValue
().
set
(
key
,
value
,
expires
,
TimeUnit
.
SECONDS
);
}
public
boolean
existsOld
(
String
key
)
{
return
Boolean
.
TRUE
.
equals
(
oldMarketRedisTemplate
.
hasKey
(
key
));
}
public
void
delToken
(
String
key
)
{
oldMarketRedisTemplate
.
delete
(
key
);
}
public
void
hsetNew
(
String
key
,
String
field
,
int
expire
,
String
value
)
{
oldMarketRedisTemplate
.
opsForHash
().
put
(
key
,
field
,
value
);
oldMarketRedisTemplate
.
expire
(
key
,
expire
,
TimeUnit
.
SECONDS
);
}
public
String
getTotalCountKey
(
AttributionType
attributionType
,
int
platformId
,
Long
channelOrPlanId
,
int
sprDedu
,
String
dateStr
)
{
...
...
src/main/java/com/lwby/marketing/att/dyvideo/handle/DyvideoBehaviorFlow.java
View file @
eeee45e8
...
...
@@ -117,7 +117,7 @@ public class DyvideoBehaviorFlow extends NodeSwitchFlow<StoryNovelAction> {
dyMarketPlatformAppIdList
=
Arrays
.
asList
(
dyMarketPlatformAppId
.
split
(
"_"
));
String
tokenDy
=
"token_dy_"
+
dyMarketPlatformAppIdList
.
get
(
0
);
ThirdAccountDy
thirdAccountDy
=
null
;
if
(
up
.
exists
(
tokenDy
))
{
if
(
up
.
exists
Old
(
tokenDy
))
{
thirdAccountDy
=
up
.
get
(
ThirdAccountDy
.
class
,
tokenDy
);
}
else
{
thirdAccountDy
=
up
.
getDyAccessToken
(
dyMarketPlatformAppIdList
.
get
(
0
),
dyMarketPlatformAppIdList
.
get
(
1
),
...
...
@@ -328,9 +328,9 @@ public class DyvideoBehaviorFlow extends NodeSwitchFlow<StoryNovelAction> {
tvcCount
+=
costI
;
}
up
.
hset
(
upcBehaviorKey
,
"tvc"
,
60
*
60
*
24
*
3
,
JSON
.
toJSONString
(
tvcCount
));
up
.
hset
(
upcBehaviorKey
,
"mvc"
,
60
*
60
*
24
*
3
,
JSON
.
toJSONString
(
motivateCount
));
up
.
hset
(
upcBehaviorKey
,
"vec"
,
60
*
60
*
24
*
3
,
JSON
.
toJSONString
(
pecpmCount
));
up
.
hset
New
(
upcBehaviorKey
,
"tvc"
,
60
*
60
*
24
*
3
,
JSON
.
toJSONString
(
tvcCount
));
up
.
hset
New
(
upcBehaviorKey
,
"mvc"
,
60
*
60
*
24
*
3
,
JSON
.
toJSONString
(
motivateCount
));
up
.
hset
New
(
upcBehaviorKey
,
"vec"
,
60
*
60
*
24
*
3
,
JSON
.
toJSONString
(
pecpmCount
));
}
...
...
src/main/java/com/lwby/marketing/controller/AttrController.java
View file @
eeee45e8
...
...
@@ -249,6 +249,15 @@ public class AttrController {
@RequestMapping
(
"/sendVideoApp"
)
public
void
testSendVideoapp
()
{
com
.
alibaba
.
fastjson
.
JSONObject
dyMarketPlatformAppIdJson
=
JSON
.
parseObject
(
"{\n"
+
" \"400\": \"ttf2f6844b6dc9702901_d4ac08a22f80f73256836fdd9655dbb0b6e6de7c\",\n"
+
" \"412\": \"ttd3dda5604ce230b401_5aac82a8c76db9c54f187dea7b43b58b233459db\"\n"
+
"}"
);
String
platformKey
=
String
.
valueOf
(
412
);
//走平台
String
dyMarketPlatformAppId
=
dyMarketPlatformAppIdJson
.
getString
(
platformKey
);
String
msg
=
"{\"clientInfo\":{\"channel\":682000,\"clientIp\":\"183.226.74.112\","
+
"\"dID\":\"2705A240-1875-4C38-9529-0343B56B6C49\",\"fixVersion\":4,\"idfa\":\"00000000-0000-0000-0000-000000000000\","
+
"\"language\":\"zh\",\"mainVersion\":1,\"oaid\":\"2705A240-1875-4C38-9529-0343B56B6C49\",\"os\":\"1\","
...
...
src/main/resources/application-prod.yml
View file @
eeee45e8
...
...
@@ -22,7 +22,7 @@ spring:
initialSize
:
2
minIdle
:
2
video-inland
:
jdbc-url
:
jdbc:mysql://rm-2ze
o09186ukqa8zh1.mysql.rds.aliyuncs.com:3306/video-inland?zeroDateTimeBehavior=CONVERT_TO_NULL&characterEncoding=utf8
&autoReconnect=true
jdbc-url
:
jdbc:mysql://rm-2ze
yw42052h06f905.mysql.rds.aliyuncs.com:3306/video-inland?zeroDateTimeBehavior=CONVERT_TO_NULL&characterEncoding=utf8&serverTimezone=Asia/Shanghai
&autoReconnect=true
username
:
video
password
:
hdTImXLlzOEbP5bk
driver-class-name
:
com.mysql.cj.jdbc.Driver
...
...
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