12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576 |
- package config
- var ExtConfig Extend
- // Extend 扩展配置
- //
- // extend:
- // demo:
- // name: demo-name
- //
- // 使用方法: config.ExtConfig......即可!!
- type Extend struct {
- // AMap AMap // 这里配置对应配置文件的结构即可
- OLAPDB OLAPDB
- Kafka Kafka
- Otel Otel
- Prometheus Prometheus
- ClickhouseMetrics bool
- SmsConfig SmsConfig
- }
- type AMap struct {
- Key string
- }
- type OLAPDB struct {
- Driver string
- Addr string
- Debug bool
- Database string
- Username string
- Password string
- MaxOpenConns int
- MaxIdleConns int
- }
- type Kafka struct {
- Brokers []string
- Topic string
- Consumers int
- MaxConcurrency int
- MetricsGroupId string
- }
- type Otel struct {
- // ServiceName string
- // ServiceVersion string
- // MetricsEndpoint string
- // MetriInterval int64
- Common OTelCommon
- Metrics OTelMetrics
- }
- type OTelCommon struct {
- ServiceName string
- ServiceVersion string
- Endpoint string // http endpoint
- GrpcEndpoint string
- }
- type OTelMetrics struct {
- Interval int64
- }
- type Prometheus struct {
- Address string
- }
- type SmsConfig struct {
- Appkey string //:= "95598109"
- Appsecret string //:= "VXX8H0MzT7"
- Url string `json:"url"`
- AppsGroup string //1:17233413341,18723344112;2:17233413341,18723344112;3:17233413341,18723344112
- SmsTpl string
- // SqlRecord bool
- }
|