Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
enoch
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DevOps
enoch
Commits
31c30d34
Commit
31c30d34
authored
Mar 14, 2019
by
Node- 门 忠鑫
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改开发环境配置文件
parent
44b6fd0e
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
12 deletions
+4
-12
main.go
main.go
+0
-2
conf.json
service/conf/dev/conf.json
+2
-2
kafka_conf.go
service/conf/kafka_conf.go
+2
-8
No files found.
main.go
View file @
31c30d34
...
@@ -35,8 +35,6 @@ func main() {
...
@@ -35,8 +35,6 @@ func main() {
//初始化redis连接池
//初始化redis连接池
data
.
RedisPoolInit
()
data
.
RedisPoolInit
()
//go service.AgentClusterConsumer()
//go service.ClusterConsumer()
go
service
.
AgentClusterConsumer
(
conf
.
HealthTopic
(),
service
.
HealthMessageHandler
{})
go
service
.
AgentClusterConsumer
(
conf
.
HealthTopic
(),
service
.
HealthMessageHandler
{})
go
service
.
AgentClusterConsumer
(
conf
.
BraveTopic
(),
service
.
BraveMessageHandler
{})
go
service
.
AgentClusterConsumer
(
conf
.
BraveTopic
(),
service
.
BraveMessageHandler
{})
intPort
,
_
:=
strconv
.
Atoi
(
port
)
intPort
,
_
:=
strconv
.
Atoi
(
port
)
...
...
service/conf/dev/conf.json
View file @
31c30d34
...
@@ -12,7 +12,7 @@
...
@@ -12,7 +12,7 @@
"brokers"
:
[
"192.168.4.100:15091"
,
"192.168.4.100:15092"
,
"192.168.4.100:15093"
]
"brokers"
:
[
"192.168.4.100:15091"
,
"192.168.4.100:15092"
,
"192.168.4.100:15093"
]
},
},
"influx_db"
:
{
"influx_db"
:
{
"host"
:
"
http://localhost
"
,
"host"
:
"
192.168.4.100
"
,
"port"
:
"
9001
"
"port"
:
"
8066
"
}
}
}
}
service/conf/kafka_conf.go
View file @
31c30d34
package
conf
package
conf
var
(
//agentBrokers = []string{"192.168.4.100:15091", "192.168.4.100:15092", "192.168.4.100:15093"}
agentBrokers
=
[]
string
{
"172.30.12.19:9092"
,
"172.30.12.20:9092"
,
"172.30.12.21:9092"
}
agentKafkaTopic
=
"quantGroup.tech.enoch.pro"
agentKafkaGroup
=
"quantGroup-enoch-agent"
)
type
KafkaConf
struct
{
type
KafkaConf
struct
{
Broker
[]
string
Broker
[]
string
...
@@ -15,14 +9,14 @@ type KafkaConf struct {
...
@@ -15,14 +9,14 @@ type KafkaConf struct {
func
HealthTopic
()
KafkaConf
{
func
HealthTopic
()
KafkaConf
{
return
KafkaConf
{
return
KafkaConf
{
[]
string
{
"172.30.12.19:9092"
,
"172.30.12.20:9092"
,
"172.30.12.21:9092"
}
,
GlobalConfig
.
Kafka
.
Brokers
,
"quantGroup.tech.enoch.pro"
,
"quantGroup.tech.enoch.pro"
,
"quantGroup-enoch-agent"
}
"quantGroup-enoch-agent"
}
}
}
func
BraveTopic
()
KafkaConf
{
func
BraveTopic
()
KafkaConf
{
return
KafkaConf
{
return
KafkaConf
{
[]
string
{
"172.30.12.19:9092"
,
"172.30.12.20:9092"
,
"172.30.12.21:9092"
}
,
GlobalConfig
.
Kafka
.
Brokers
,
"quantGroup.tech.brave.pro"
,
"quantGroup.tech.brave.pro"
,
"enoch-group"
}
"enoch-group"
}
}
}
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