Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove log field of config because it is no longer used / 从config配置中删除不再使用的log字段 #356

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import (
type Config struct {
DB DbConfig `toml:"db"`
JWT JWTConfig `toml:"jwt"`
Log LogConfig `toml:"log"`
API APIConfig `toml:"api"`
Node NodeConfig `toml:"node"`
MessageService MessageServiceConfig `toml:"messageService"`
Expand All @@ -26,11 +25,6 @@ type NodeConfig struct {
Token string `toml:"token"`
}

type LogConfig struct {
Path string `toml:"path"`
Level string `toml:"level"`
}

type APIConfig struct {
Address string
}
Expand Down Expand Up @@ -141,10 +135,6 @@ func DefaultConfig() *Config {
JWT: JWTConfig{
AuthURL: "http://127.0.0.1:8989",
},
Log: LogConfig{
Path: "",
Level: "info",
},
API: APIConfig{
Address: "/ip4/127.0.0.1/tcp/39812",
},
Expand Down
2 changes: 1 addition & 1 deletion integration_test/mock_messager_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ func mockMessagerServer(ctx context.Context, repoPath string, cfg *config.Config

provider := fx.Options(
// prover
fx.Supply(cfg, &cfg.DB, &cfg.API, &cfg.JWT, &cfg.Node, &cfg.Log, &cfg.MessageService, cfg.Libp2pNet,
fx.Supply(cfg, &cfg.DB, &cfg.API, &cfg.JWT, &cfg.Node, &cfg.MessageService, cfg.Libp2pNet,
&cfg.Gateway, &cfg.RateLimit, cfg.Trace, cfg.Metrics, cfg.Publisher),
fx.Supply(fullNode),
fx.Supply(networkParams.NetworkName),
Expand Down
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ func runAction(cctx *cli.Context) error {
provider := fx.Options(
fx.Logger(fxLogger{}),
// prover
fx.Supply(cfg, &cfg.DB, &cfg.API, &cfg.JWT, &cfg.Node, &cfg.Log, &cfg.MessageService, cfg.Libp2pNet,
fx.Supply(cfg, &cfg.DB, &cfg.API, &cfg.JWT, &cfg.Node, &cfg.MessageService, cfg.Libp2pNet,
&cfg.Gateway, &cfg.RateLimit, cfg.Trace, cfg.Metrics, cfg.Publisher),
fx.Supply(networkParams.NetworkName),
fx.Supply(networkParams),
Expand Down