Skip to content

Commit

Permalink
Merge branch 'external-signer' into external-signer-mtls
Browse files Browse the repository at this point in the history
  • Loading branch information
anodar authored Oct 17, 2023
2 parents f285d2e + 1e9b588 commit cfd7132
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 5 deletions.
4 changes: 2 additions & 2 deletions arbnode/dataposter/data_poster.go
Original file line number Diff line number Diff line change
Expand Up @@ -804,7 +804,7 @@ var DefaultDataPosterConfig = DataPosterConfig{
UseNoOpStorage: false,
LegacyStorageEncoding: true,
Dangerous: DangerousConfig{ClearDBStorage: false},
ExternalSigner: ExternalSignerCfg{},
ExternalSigner: ExternalSignerCfg{Method: "eth_signTransaction"},
}

var DefaultDataPosterConfigForValidator = func() DataPosterConfig {
Expand All @@ -826,7 +826,7 @@ var TestDataPosterConfig = DataPosterConfig{
AllocateMempoolBalance: true,
UseDBStorage: false,
UseNoOpStorage: false,
ExternalSigner: ExternalSignerCfg{},
ExternalSigner: ExternalSignerCfg{Method: "eth_signTransaction"},
}

var TestDataPosterConfigForValidator = func() DataPosterConfig {
Expand Down
13 changes: 11 additions & 2 deletions cmd/daserver/daserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ type DAServerConfig struct {

Conf genericconf.ConfConfig `koanf:"conf"`
LogLevel int `koanf:"log-level"`
LogType string `koanf:"log-type"`

Metrics bool `koanf:"metrics"`
MetricsServer genericconf.MetricsServerConfig `koanf:"metrics-server"`
Expand All @@ -62,11 +63,12 @@ var DefaultDAServerConfig = DAServerConfig{
RESTServerTimeouts: genericconf.HTTPServerTimeoutConfigDefault,
DataAvailability: das.DefaultDataAvailabilityConfig,
Conf: genericconf.ConfConfigDefault,
LogLevel: int(log.LvlInfo),
LogType: "plaintext",
Metrics: false,
MetricsServer: genericconf.MetricsServerConfigDefault,
PProf: false,
PprofCfg: genericconf.PProfDefault,
LogLevel: 3,
}

func main() {
Expand Down Expand Up @@ -99,6 +101,8 @@ func parseDAServer(args []string) (*DAServerConfig, error) {
genericconf.PProfAddOptions("pprof-cfg", f)

f.Int("log-level", int(log.LvlInfo), "log level; 1: ERROR, 2: WARN, 3: INFO, 4: DEBUG, 5: TRACE")
f.String("log-type", DefaultDAServerConfig.LogType, "log type (plaintext or json)")

das.DataAvailabilityConfigAddDaserverOptions("data-availability", f)
genericconf.ConfConfigAddOptions("conf", f)

Expand Down Expand Up @@ -178,7 +182,12 @@ func startup() error {
confighelpers.PrintErrorAndExit(errors.New("please specify at least one of --enable-rest or --enable-rpc"), printSampleUsage)
}

glogger := log.NewGlogHandler(log.StreamHandler(os.Stderr, log.TerminalFormat(false)))
logFormat, err := genericconf.ParseLogType(serverConfig.LogType)
if err != nil {
flag.Usage()
panic(fmt.Sprintf("Error parsing log type: %v", err))
}
glogger := log.NewGlogHandler(log.StreamHandler(os.Stderr, logFormat))
glogger.Verbosity(log.Lvl(serverConfig.LogLevel))
log.Root().SetHandler(glogger)

Expand Down
2 changes: 1 addition & 1 deletion execution/gethexec/sequencer.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ type SequencerConfigFetcher func() *SequencerConfig

var DefaultSequencerConfig = SequencerConfig{
Enable: false,
MaxBlockSpeed: time.Millisecond * 100,
MaxBlockSpeed: time.Millisecond * 250,
MaxRevertGasReject: params.TxGas + 10000,
MaxAcceptableTimestampDelta: time.Hour,
Forwarder: DefaultSequencerForwarderConfig,
Expand Down

0 comments on commit cfd7132

Please sign in to comment.