Skip to content

Commit

Permalink
rm obsolete alertinginterface
Browse files Browse the repository at this point in the history
  • Loading branch information
snadrus committed Jul 12, 2024
1 parent 81387ca commit 7272177
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 18 deletions.
2 changes: 0 additions & 2 deletions node/builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ import (
"github.com/filecoin-project/lotus/node/modules/testing"
"github.com/filecoin-project/lotus/node/repo"
"github.com/filecoin-project/lotus/storage/paths"
"github.com/filecoin-project/lotus/storage/paths/alertinginterface"
"github.com/filecoin-project/lotus/system"
)

Expand Down Expand Up @@ -161,7 +160,6 @@ func defaults() []Option {
Override(new(journal.DisabledEvents), journal.EnvDisabledEvents),
Override(new(journal.Journal), modules.OpenFilesystemJournal),
Override(new(*alerting.Alerting), alerting.NewAlertingSystem),
Override(new(alertinginterface.AlertingInterface), alerting.NewAlertingSystem),
Override(new(dtypes.NodeStartTime), FromVal(dtypes.NodeStartTime(time.Now()))),

Override(CheckFDLimit, modules.CheckFdLimit(build.DefaultFDLimit)),
Expand Down
11 changes: 0 additions & 11 deletions storage/paths/alertinginterface/ai.go

This file was deleted.

10 changes: 5 additions & 5 deletions storage/paths/db_index.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ import (

"github.com/filecoin-project/go-state-types/abi"

"github.com/filecoin-project/lotus/journal/alerting"
"github.com/filecoin-project/lotus/lib/harmony/harmonydb"
"github.com/filecoin-project/lotus/metrics"
"github.com/filecoin-project/lotus/storage/paths/alertinginterface"
"github.com/filecoin-project/lotus/storage/sealer/fsutil"
"github.com/filecoin-project/lotus/storage/sealer/storiface"
)
Expand All @@ -31,18 +31,18 @@ const URLSeparator = ","
var errAlreadyLocked = errors.New("already locked")

type DBIndex struct {
alerting alertinginterface.AlertingInterface
pathAlerts map[storiface.ID]alertinginterface.AlertType
alerting *alerting.Alerting
pathAlerts map[storiface.ID]alerting.AlertType

harmonyDB *harmonydb.DB
}

func NewDBIndex(al alertinginterface.AlertingInterface, db *harmonydb.DB) *DBIndex {
func NewDBIndex(al *alerting.Alerting, db *harmonydb.DB) *DBIndex {
return &DBIndex{
harmonyDB: db,

alerting: al,
pathAlerts: map[storiface.ID]alertinginterface.AlertType{},
pathAlerts: map[storiface.ID]alerting.AlertType{},
}
}

Expand Down

0 comments on commit 7272177

Please sign in to comment.