Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
Amazon-Selection-Data
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
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
abel_cjy
Amazon-Selection-Data
Commits
b109b0b7
Commit
b109b0b7
authored
Jun 24, 2025
by
chenyuanjie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
c965875b
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
15 additions
and
9 deletions
+15
-9
es_update_with_info.py
Pyspark_job/es_handle/es_update_with_info.py
+1
-1
es_update_with_usr_mask.py
Pyspark_job/es_handle/es_update_with_usr_mask.py
+1
-1
export_dwt_asin_related_traffic.py
Pyspark_job/sqoop_export/export_dwt_asin_related_traffic.py
+9
-3
db_util.py
Pyspark_job/utils/db_util.py
+1
-1
es_util.py
Pyspark_job/utils/es_util.py
+1
-1
templates.sh
run_shell/sqoop_shell/templates.sh
+2
-2
No files found.
Pyspark_job/es_handle/es_update_with_info.py
View file @
b109b0b7
...
@@ -11,7 +11,7 @@ from utils.DorisHelper import DorisHelper
...
@@ -11,7 +11,7 @@ from utils.DorisHelper import DorisHelper
__es_ip__
=
"192.168.10.217"
__es_ip__
=
"192.168.10.217"
__es_port__
=
"9200"
__es_port__
=
"9200"
__es_user__
=
"elastic"
__es_user__
=
"elastic"
__es_passwd__
=
"
selection2021.
+"
__es_passwd__
=
"
Selection20251#
+"
__warehouse_dir__
=
"hdfs://nameservice1:8020/home/big_data_selection"
__warehouse_dir__
=
"hdfs://nameservice1:8020/home/big_data_selection"
__metastore_uris__
=
"thrift://hadoop16:9083"
__metastore_uris__
=
"thrift://hadoop16:9083"
...
...
Pyspark_job/es_handle/es_update_with_usr_mask.py
View file @
b109b0b7
...
@@ -17,7 +17,7 @@ from utils.DorisHelper import DorisHelper
...
@@ -17,7 +17,7 @@ from utils.DorisHelper import DorisHelper
__es_ip__
=
"192.168.10.217"
__es_ip__
=
"192.168.10.217"
__es_port__
=
"9200"
__es_port__
=
"9200"
__es_user__
=
"elastic"
__es_user__
=
"elastic"
__es_passwd__
=
"
selection2021.
+"
__es_passwd__
=
"
Selection20251#
+"
__warehouse_dir__
=
"hdfs://nameservice1:8020/home/big_data_selection"
__warehouse_dir__
=
"hdfs://nameservice1:8020/home/big_data_selection"
__metastore_uris__
=
"thrift://hadoop16:9083"
__metastore_uris__
=
"thrift://hadoop16:9083"
...
...
Pyspark_job/sqoop_export/export_dwt_asin_related_traffic.py
View file @
b109b0b7
...
@@ -24,7 +24,8 @@ if __name__ == '__main__':
...
@@ -24,7 +24,8 @@ if __name__ == '__main__':
export_cols
=
[
export_cols
=
[
'asin'
,
'asin'
,
'related_asin'
,
'related_asin'
,
'related_type'
'related_type'
,
'related_time'
]
]
if
date_type
==
'month'
:
if
date_type
==
'month'
:
...
@@ -41,8 +42,13 @@ if __name__ == '__main__':
...
@@ -41,8 +42,13 @@ if __name__ == '__main__':
sql
=
f
"""
sql
=
f
"""
DROP TABLE IF EXISTS {export_tb};
DROP TABLE IF EXISTS {export_tb};
CREATE TABLE {export_tb} (LIKE us_asin_related_template INCLUDING ALL);
CREATE TABLE {export_tb} (
id serial8,
asin varchar(10) NOT NULL,
related_asin varchar(10)[] NOT NULL,
related_type int2[] NOT NULL,
related_time varchar(10) NOT NULL
);
ALTER TABLE {export_tb} ALTER COLUMN related_asin TYPE text;
ALTER TABLE {export_tb} ALTER COLUMN related_asin TYPE text;
ALTER TABLE {export_tb} ALTER COLUMN related_type TYPE text;
ALTER TABLE {export_tb} ALTER COLUMN related_type TYPE text;
"""
"""
...
...
Pyspark_job/utils/db_util.py
View file @
b109b0b7
...
@@ -35,7 +35,7 @@ class DBUtil(object):
...
@@ -35,7 +35,7 @@ class DBUtil(object):
__mysql_host__
=
"rm-wz9yg9bsb2zf01ea4yo.mysql.rds.aliyuncs.com"
__mysql_host__
=
"rm-wz9yg9bsb2zf01ea4yo.mysql.rds.aliyuncs.com"
__mysql_port__
=
"3306"
__mysql_port__
=
"3306"
__mysql_username__
=
"XP_Yswg2025"
__mysql_username__
=
"XP_Yswg2025"
__mysql_pwd__
=
"X
p_Yswg2025@
300"
__mysql_pwd__
=
"X
P2025@Yswg
300"
# pg连接参数正式库-h15
# pg连接参数正式库-h15
__pgsql_host__
=
"192.168.10.224"
__pgsql_host__
=
"192.168.10.224"
...
...
Pyspark_job/utils/es_util.py
View file @
b109b0b7
...
@@ -8,7 +8,7 @@ class EsUtils(object):
...
@@ -8,7 +8,7 @@ class EsUtils(object):
__es_url_us_old_month__
=
"http://120.79.147.190:9200"
__es_url_us_old_month__
=
"http://120.79.147.190:9200"
__es_url__
=
"http://192.168.10.217:9200"
__es_url__
=
"http://192.168.10.217:9200"
__es_user__
=
"elastic"
__es_user__
=
"elastic"
__es_passwd__
=
"
selection2021.
+"
__es_passwd__
=
"
Selection20251#
+"
__basic_auth__
=
"ZWxhc3RpYzpzZWxlY3Rpb24yMDIxLis="
__basic_auth__
=
"ZWxhc3RpYzpzZWxlY3Rpb24yMDIxLis="
__basic_auth_test__
=
"ZWxhc3RpYzpzZWxlY3Rpb24yMDIxLis="
__basic_auth_test__
=
"ZWxhc3RpYzpzZWxlY3Rpb24yMDIxLis="
__es_port__
=
'9200'
__es_port__
=
'9200'
...
...
run_shell/sqoop_shell/templates.sh
View file @
b109b0b7
...
@@ -12,8 +12,8 @@ get_db_info(){
...
@@ -12,8 +12,8 @@ get_db_info(){
db_url
=
mysql
db_url
=
mysql
host
=
rm-wz9yg9bsb2zf01ea4yo.mysql.rds.aliyuncs.com
host
=
rm-wz9yg9bsb2zf01ea4yo.mysql.rds.aliyuncs.com
port
=
3306
port
=
3306
username
=
adv_yswg
username
=
XP_Yswg2025
password
=
HCL1zcUgQesaaXNLbL37O5KhpSAy0c
password
=
XP2025@Yswg300
elif
[
$db_type
==
postgresql
]
elif
[
$db_type
==
postgresql
]
then
then
db_url
=
postgresql
db_url
=
postgresql
...
...
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