kafka.go 665 字节
package constant

import "os"

var (
	// kafka 地址
	KAFKA_HOST = "192.168.0.250:9092,192.168.0.251:9092,192.168.0.252:9092" //"106.75.231.90:9092"
	// kafka  topic log stash
	TOPIC_LOG_STASH = "go_stash_dev" //"pushMessage"
	//  kafka  topic up_block_chain
	TOPIC_UP_BLOCK_CHAIN = "allied_creation_message"
	// 是否启用日志收集 (本地不启用)
	ENABLE_KAFKA_LOG = false
)

func init() {
	//if os.Getenv("KAFKA_HOST") != "" {
	//	POSTGRESQL_HOST = os.Getenv("KAFKA_HOST")
	//}
	//if os.Getenv("TOPIC_LOG_STASH") != "" {
	//	POSTGRESQL_PORT = os.Getenv("TOPIC_LOG_STASH")
	//}
	if os.Getenv("ENABLE_KAFKA_LOG") != "" {
		ENABLE_KAFKA_LOG = true
	}
}