[#1388] governance: Drop unused

Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
Dmitrii Stepanov 2024-09-23 09:06:19 +03:00 committed by Dmitrii Stepanov
parent b69e07da7a
commit aedb55f913
3 changed files with 0 additions and 25 deletions

View file

@ -163,7 +163,6 @@ func (s *Server) createAlphaSync(cfg *viper.Viper, frostfsCli *frostfsClient.Cli
Log: s.log, Log: s.log,
Metrics: s.irMetrics, Metrics: s.irMetrics,
FrostFSClient: frostfsCli, FrostFSClient: frostfsCli,
NetmapClient: s.netmapClient,
AlphabetState: s, AlphabetState: s,
EpochState: s, EpochState: s,
Voter: s, Voter: s,

View file

@ -8,7 +8,6 @@ import (
"git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/client" "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/client"
frostfscontract "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/client/frostfs" frostfscontract "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/client/frostfs"
nmClient "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/client/netmap"
"git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/event/rolemanagement" "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/morph/event/rolemanagement"
"git.frostfs.info/TrueCloudLab/frostfs-node/pkg/util/logger/test" "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/util/logger/test"
"github.com/nspcc-dev/neo-go/pkg/core/native/noderoles" "github.com/nspcc-dev/neo-go/pkg/core/native/noderoles"
@ -38,7 +37,6 @@ func TestHandleAlphabetSyncEvent(t *testing.T) {
alphabetKeys: testKeys.mainnetKeys, alphabetKeys: testKeys.mainnetKeys,
} }
f := &testFrostFSClient{} f := &testFrostFSClient{}
nm := &testNetmapClient{}
proc, err := New( proc, err := New(
&Params{ &Params{
@ -50,7 +48,6 @@ func TestHandleAlphabetSyncEvent(t *testing.T) {
MorphClient: m, MorphClient: m,
MainnetClient: mn, MainnetClient: mn,
FrostFSClient: f, FrostFSClient: f,
NetmapClient: nm,
}, },
) )
@ -73,10 +70,6 @@ func TestHandleAlphabetSyncEvent(t *testing.T) {
}, },
}, v.votes, "invalid vote calls") }, v.votes, "invalid vote calls")
var irUpdateExp []nmClient.UpdateIRPrm
require.EqualValues(t, irUpdateExp, nm.updates, "invalid IR updates")
var expAlphabetUpdate client.UpdateAlphabetListPrm var expAlphabetUpdate client.UpdateAlphabetListPrm
expAlphabetUpdate.SetHash(ev.txHash) expAlphabetUpdate.SetHash(ev.txHash)
expAlphabetUpdate.SetList(testKeys.newInnerRingExp) expAlphabetUpdate.SetList(testKeys.newInnerRingExp)
@ -119,7 +112,6 @@ func TestHandleAlphabetDesignateEvent(t *testing.T) {
alphabetKeys: testKeys.mainnetKeys, alphabetKeys: testKeys.mainnetKeys,
} }
f := &testFrostFSClient{} f := &testFrostFSClient{}
nm := &testNetmapClient{}
proc, err := New( proc, err := New(
&Params{ &Params{
@ -131,7 +123,6 @@ func TestHandleAlphabetDesignateEvent(t *testing.T) {
MorphClient: m, MorphClient: m,
MainnetClient: mn, MainnetClient: mn,
FrostFSClient: f, FrostFSClient: f,
NetmapClient: nm,
}, },
) )
@ -155,9 +146,6 @@ func TestHandleAlphabetDesignateEvent(t *testing.T) {
}, },
}, v.votes, "invalid vote calls") }, v.votes, "invalid vote calls")
var irUpdatesExp []nmClient.UpdateIRPrm
require.EqualValues(t, irUpdatesExp, nm.updates, "invalid IR updates")
var alpabetUpdExp client.UpdateAlphabetListPrm var alpabetUpdExp client.UpdateAlphabetListPrm
alpabetUpdExp.SetList(testKeys.newInnerRingExp) alpabetUpdExp.SetList(testKeys.newInnerRingExp)
alpabetUpdExp.SetHash(ev.TxHash) alpabetUpdExp.SetHash(ev.TxHash)
@ -293,12 +281,3 @@ func (c *testFrostFSClient) AlphabetUpdate(p frostfscontract.AlphabetUpdatePrm)
c.updates = append(c.updates, p) c.updates = append(c.updates, p)
return nil return nil
} }
type testNetmapClient struct {
updates []nmClient.UpdateIRPrm
}
func (c *testNetmapClient) UpdateInnerRing(p nmClient.UpdateIRPrm) error {
c.updates = append(c.updates, p)
return nil
}

View file

@ -79,7 +79,6 @@ type (
metrics metrics.Register metrics metrics.Register
pool *ants.Pool pool *ants.Pool
frostfsClient FrostFSClient frostfsClient FrostFSClient
netmapClient NetmapClient
alphabetState AlphabetState alphabetState AlphabetState
epochState EpochState epochState EpochState
@ -105,7 +104,6 @@ type (
MorphClient MorphClient MorphClient MorphClient
MainnetClient MainnetClient MainnetClient MainnetClient
FrostFSClient FrostFSClient FrostFSClient FrostFSClient
NetmapClient NetmapClient
} }
) )
@ -146,7 +144,6 @@ func New(p *Params) (*Processor, error) {
metrics: metricsRegister, metrics: metricsRegister,
pool: pool, pool: pool,
frostfsClient: p.FrostFSClient, frostfsClient: p.FrostFSClient,
netmapClient: p.NetmapClient,
alphabetState: p.AlphabetState, alphabetState: p.AlphabetState,
epochState: p.EpochState, epochState: p.EpochState,
voter: p.Voter, voter: p.Voter,