config

package
v0.0.0-...-1897b02 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 20, 2018 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	NameSrv NameSrvConfig `toml:"namesrv"` // 参数配置
	Log     LogConfig     `toml:"log"`     // 日志
}

func ParseConfig

func ParseConfig(path string) (*Config, error)

ParseConfig 解析配置文件

type LogConfig

type LogConfig struct {
	CfgFilePath string `toml:"config_file_path"` // 日志配置文件路径
}

LogConfig 日志配置

type NameSrvConfig

type NameSrvConfig struct {
	Host      string `toml:"host"`           // 监听地址
	Port      int    `toml:"port"`           // 监听端口
	KVCfgPath string `toml:"kv_config_path"` // kv文件存储路径
}

NameSrvConfig namesrv相关配置

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL