Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
services
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
tencent
services
Commits
d2568e2c
Commit
d2568e2c
authored
Dec 05, 2018
by
xmy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
# 1.0.27
- cmq 内外网切换
parent
1fe6e16b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
3 deletions
+7
-3
UPGRADE.md
+2
-0
src/Cmq/Account.php
+3
-1
src/Common/Config/config.php
+2
-2
No files found.
UPGRADE.md
View file @
d2568e2c
# 1.0.27
-
cmq 内外网切换
# 1.0.26
-
卖家分销 消息队列枚举
# 1.0.25
...
...
src/Cmq/Account.php
View file @
d2568e2c
...
...
@@ -29,7 +29,9 @@ class Account
{
$config
=
include
alias
(
'@vendor/hdll/services/src/Common/Config'
)
.
'/config.php'
;
$config
=
$config
[
'cmq'
];
$this
->
host
=
empty
(
$host
)
?
$config
[
'host'
]
:
$host
;
if
(
empty
(
$host
)){
$this
->
host
=
empty
(
env
(
'ENVIRONMENT'
,
''
))
?
$config
[
'intranet_host'
]
:
$config
[
'internet_host'
];
}
$this
->
secretId
=
empty
(
$secretId
)
?
$config
[
'secretId'
]
:
$secretId
;
$this
->
secretKey
=
empty
(
$secretKey
)
?
$config
[
'secretKey'
]
:
$secretKey
;
$this
->
cmq_client
=
new
CMQClient
(
$this
->
host
,
$this
->
secretId
,
$this
->
secretKey
);
...
...
src/Common/Config/config.php
View file @
d2568e2c
...
...
@@ -18,8 +18,8 @@ return [
'secretKey'
=>
'IPL5g5PaaSAzd6NSO8gEmLxcN4pTzJSQ'
,
],
'cmq'
=>
[
// '
host' => 'http://cmq-topic-bj.api.tencentyun.com',//内网
'host'
=>
'https://cmq-topic-bj.api.qcloud.com'
,
//外网
'intranet_
host'
=>
'http://cmq-topic-bj.api.tencentyun.com'
,
//内网
'
internet_
host'
=>
'https://cmq-topic-bj.api.qcloud.com'
,
//外网
'secretId'
=>
'AKIDYRW1cG2iVIg8dAoCe86vhNuA7A5oNknk'
,
'secretKey'
=>
'z0ymS7xfLrP6Sk2EKHWaXN6d0EIxX0IQ'
,
],
...
...
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