Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
crawler
Project
Project
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
backend
crawler
Commits
95b18bf2
Commit
95b18bf2
authored
Dec 03, 2020
by
litaolemo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
73e7add8
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
temp_service_to_redis.py
test/temp_service_to_redis.py
+7
-2
No files found.
test/temp_service_to_redis.py
View file @
95b18bf2
...
@@ -1494,7 +1494,7 @@ headers = {
...
@@ -1494,7 +1494,7 @@ headers = {
'X-GM-Rpc-Method'
:
'rims/search/cpt_service'
,
'X-GM-Rpc-Method'
:
'rims/search/cpt_service'
,
}
}
r
edis_old_gaia
=
redis
.
StrictRedis
.
from_url
(
"redis://:XfkMCCdWDIU
%
ls$h3@172.16.50.159:6379/
9"
,
decode_responses
=
True
)
r
ds
=
redis
.
StrictRedis
.
from_url
(
"redis://:XfkMCCdWDIU
%
ls$h3@172.16.50.159:637
9"
,
decode_responses
=
True
)
for
query
in
query_list
:
for
query
in
query_list
:
res
=
json
.
dumps
(
query
)
res
=
json
.
dumps
(
query
)
...
@@ -1511,5 +1511,9 @@ for query in query_list:
...
@@ -1511,5 +1511,9 @@ for query in query_list:
}
}
# print(data)
# print(data)
response
=
requests
.
post
(
'http://172.16.50.10:8170/v1/batch'
,
headers
=
headers
,
data
=
data
)
response
=
requests
.
post
(
'http://172.16.50.10:8170/v1/batch'
,
headers
=
headers
,
data
=
data
)
print
(
response
.
json
())
data
=
json
.
dumps
(
response
.
json
())
time
.
sleep
(
1
)
time
.
sleep
(
1
)
key
=
"meigou_"
+
city
+
"_"
+
query
print
(
key
)
rds
.
set
(
key
,
data
)
break
\ No newline at end of file
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