Clean up remaining NeoFS mentions #1561

Open
opened 2024-12-13 14:59:14 +00:00 by potyarkin · 0 comments
Member

NeoFS is still mentioned in multiple places. Many of those are comments and are easy to fix, but some are in function/variable names and I don't feel confident replacing those myself:

  • roles.NeoFSAlphabet
  • fn.sidechain.NeoFSAlphabetList()
  • (*testMorphClient).UpdateNeoFSAlphabetList()
  • ...

Someone more familiar with the codebase should look at this.

Click to expand the full listing:

git ls-files | grep -v CHANGELOG | grep -vP '^\./neo' | grep -vF go.sum | grep -vw copyright | grep -vF '.proto' | xargs grep -i neofs
.forgejo/ISSUE_TEMPLATE/feature_request.md:- component label (`neofs-adm`, `neofs-storage`, ...)
.gitignore:.neofs-cli.yml
CREDITS.md:FrostFS continues the development of NeoFS.
CREDITS.md:Initial NeoFS research and development (2018-2020) was done by
cmd/frostfs-adm/internal/modules/morph/balance/balance.go:      arr, err := helper.GetDesignatedByRole(inv, desigHash, noderoles.NeoFSAlphabet, height)
cmd/frostfs-adm/internal/modules/morph/config/config.go:                // In NeoFS this is done via Notary contract. Here, however, we can form the
cmd/frostfs-adm/internal/modules/morph/contract/dump_hashes.go:                 // Related https://github.com/nspcc-dev/neofs-contract/issues/316.
cmd/frostfs-adm/internal/modules/morph/helper/netmap.go:        // In NeoFS this is done via Notary contract. Here, however, we can form the
cmd/frostfs-adm/internal/modules/morph/initialize/initialize.go:        // 4. Deploy NeoFS contracts.
cmd/frostfs-adm/internal/modules/morph/initialize/initialize.go:        cmd.Println("Stage 4: deploy NeoFS contracts.")
cmd/frostfs-adm/internal/modules/morph/initialize/initialize_roles.go:          callflag.States|callflag.AllowNotify, int64(noderoles.NeoFSAlphabet), pubs)
cmd/frostfs-adm/internal/modules/morph/initialize/initialize_roles.go:  pubs, err := helper.GetDesignatedByRole(c.ReadOnlyInvoker, rolemgmt.Hash, noderoles.NeoFSAlphabet, height)
cmd/frostfs-adm/internal/modules/storagecfg/config.go:  neofsMainnetAddress   = "2cafa46838e8b564468ebd868dcafdd99dce6221"
cmd/frostfs-adm/internal/modules/storagecfg/config.go:  neofsTestnetAddress   = "b65d8243ac63983206d17e5221af0653a7266fa1"
cmd/frostfs-adm/internal/modules/storagecfg/config.go:  NeoFSContract   string
cmd/frostfs-adm/internal/modules/storagecfg/config.go:          NeoFSContract:   neofsTestnetAddress,
cmd/frostfs-adm/internal/modules/storagecfg/config.go:          NeoFSContract:   neofsMainnetAddress,
cmd/frostfs-adm/internal/modules/storagecfg/root.go:    ok := getConfirmation(false, fmt.Sprintf("Current NeoFS balance is %s, make a deposit? y/[n]: ",
cmd/frostfs-adm/internal/modules/storagecfg/root.go:    neofsHash, _ := util.Uint160DecodeStringLE(n3config[network].NeoFSContract)
cmd/frostfs-adm/internal/modules/storagecfg/root.go:    txHash, _, err := mainGas.Transfer(accSH, neofsHash, amount, nil)
cmd/frostfs-adm/internal/modules/storagecfg/root.go:            fatalOnErr(fmt.Errorf("sending TX to the NeoFS contract: %w", err))
cmd/frostfs-cli/docs/storage-node-xheaders.md:"well-known" headers may also use `__NEOFS__` prefix:
cmd/frostfs-node/config/node/config.go:// Panics if the value is not a string list of valid NeoFS network addresses.
cmd/frostfs-node/container.go:                          // TODO: use owner directly from the event after neofs-contract#256 will become resolved
cmd/frostfs-node/object.go:     keys, err := fn.sidechain.NeoFSAlphabetList()
config/example/cli.yaml:rpc-endpoint: s01.frostfs.devenv:8080         # NeoFS API endpoint of NeoFS node
config/example/cli.yaml:endpoint: localhost:8090                    # Control API endpoint of NeoFS node
config/example/ir.env:FROSTFS_IR_WORKERS_NEOFS=10
config/example/ir.env:FROSTFS_IR_CONTRACTS_NEOFS=ee3dee6d05dc79c24a5b8f6985e10d68b7cacc62
config/example/ir.env:FROSTFS_IR_CONTRACTS_NEOFSID=9f5866decbc751a099e74c7c7bc89f609201755a
config/example/node.yaml:contracts:  # side chain NEOFS contract script hashes; optional, override values retrieved from NNS contract
config/mainnet/README.md:To use NeoFS in the Mainnet, you need to deposit assets to NeoFS contract.
config/testnet/README.md:There is a prepared configuration for NeoFS Storage Node deployment in
config/testnet/README.md:Successfully tagged nspccdev/neofs-storage-testnet:0.25.1
config/testnet/README.md:The Storage Node owner should deposit GAS to NeoFS smart contract. It generates a
config/testnet/README.md:Then, make a deposit by transferring GAS to NeoFS contract in N3 Testnet.
config/testnet/README.md:NeoFS contract scripthash in N3 Testnet is `b65d8243ac63983206d17e5221af0653a7266fa1`,
config/testnet/README.md:NEOFS_GRPC_0_ENDPOINT=65.52.183.157:36512
config/testnet/README.md:NEOFS_NODE_ADDRESSES=65.52.183.157:36512
config/testnet/README.md:NEOFS_GRPC_0_ENDPOINT=65.52.183.157:36512
config/testnet/README.md:NEOFS_NODE_ADDRESSES=65.52.183.157:36512
config/testnet/README.md:NEOFS_NODE_ATTRIBUTE_2=UN-LOCODE:RU LED
config/testnet/README.md:[NeoFS LOCODE database](https://git.frostfs.info/TrueCloudLab/frostfs-locode-db/releases/tag/v0.4.0)
config/testnet/README.md:NeoFS objects will be stored on your machine. By default, docker-compose
config/testnet/README.md:       - NEOFS_LOGGER_LEVEL=debug
pkg/innerring/fetcher.go:// InnerRingKeys fetches list of innerring keys from NeoFSAlphabet
pkg/innerring/fetcher.go:       return fN.cli.NeoFSAlphabetList()
pkg/innerring/initialization.go:                // if mainchain is disabled we should use NeoFSAlphabetList client method according to its docs
pkg/innerring/processors/governance/handlers.go:                if et.Role != noderoles.NeoFSAlphabet {
pkg/innerring/processors/governance/handlers_test.go:           Role:   noderoles.NeoFSAlphabet,
pkg/innerring/processors/governance/handlers_test.go:func (c *testMorphClient) UpdateNeoFSAlphabetList(_ context.Context, prm client.UpdateAlphabetListPrm) error {
pkg/innerring/processors/governance/handlers_test.go:func (c *testMainnetClient) NeoFSAlphabetList() (res keys.PublicKeys, err error) {
pkg/innerring/processors/governance/process_update.go:  mainnetAlphabet, err := gp.mainnetClient.NeoFSAlphabetList()
pkg/innerring/processors/governance/process_update.go:  // 2. Update NeoFSAlphabet role in the sidechain.
pkg/innerring/processors/governance/process_update.go:  gp.updateNeoFSAlphabetRoleInSidechain(ctx, sidechainAlphabet, newAlphabet, txHash)
pkg/innerring/processors/governance/process_update.go:func (gp *Processor) updateNeoFSAlphabetRoleInSidechain(ctx context.Context, sidechainAlphabet, newAlphabet keys.PublicKeys, txHash util.Uint256) {
pkg/innerring/processors/governance/process_update.go:  if err = gp.morphClient.UpdateNeoFSAlphabetList(ctx, updPrm); err != nil {
pkg/innerring/processors/governance/processor.go:               NeoFSAlphabetList() (res keys.PublicKeys, err error)
pkg/innerring/processors/governance/processor.go:               UpdateNeoFSAlphabetList(ctx context.Context, prm client.UpdateAlphabetListPrm) error
pkg/morph/client/client.go:// NeoFSAlphabetList returns keys that stored in NeoFS Alphabet role. Main chain
pkg/morph/client/client.go:func (c *Client) NeoFSAlphabetList() (res keys.PublicKeys, err error) {
pkg/morph/client/client.go:     list, err := c.roleList(noderoles.NeoFSAlphabet)
pkg/morph/client/notary.go:// UpdateAlphabetListPrm groups parameters of UpdateNeoFSAlphabetList operation.
pkg/morph/client/notary.go:// UpdateNeoFSAlphabetList updates list of alphabet nodes in designate contract.
pkg/morph/client/notary.go:func (c *Client) UpdateNeoFSAlphabetList(ctx context.Context, prm UpdateAlphabetListPrm) error {
pkg/morph/client/notary.go:             noderoles.NeoFSAlphabet,
pkg/morph/event/rolemanagement/designate_test.go:               args := []stackitem.Item{stackitem.Make(int(noderoles.NeoFSAlphabet)), stackitem.Make(123)}
pkg/morph/event/rolemanagement/designate_test.go:               require.Equal(t, noderoles.NeoFSAlphabet, e.(Designate).Role)
NeoFS is still mentioned in multiple places. Many of those are comments and are easy to fix, but some are in function/variable names and I don't feel confident replacing those myself: - `roles.NeoFSAlphabet` - `fn.sidechain.NeoFSAlphabetList()` - `(*testMorphClient).UpdateNeoFSAlphabetList()` - ... Someone more familiar with the codebase should look at this. Click to expand the full listing: <details><summary><code>git ls-files | grep -v CHANGELOG | grep -vP '^\./neo' | grep -vF go.sum | grep -vw copyright | grep -vF '.proto' | xargs grep -i neofs</code></summary> ```console .forgejo/ISSUE_TEMPLATE/feature_request.md:- component label (`neofs-adm`, `neofs-storage`, ...) .gitignore:.neofs-cli.yml CREDITS.md:FrostFS continues the development of NeoFS. CREDITS.md:Initial NeoFS research and development (2018-2020) was done by cmd/frostfs-adm/internal/modules/morph/balance/balance.go: arr, err := helper.GetDesignatedByRole(inv, desigHash, noderoles.NeoFSAlphabet, height) cmd/frostfs-adm/internal/modules/morph/config/config.go: // In NeoFS this is done via Notary contract. Here, however, we can form the cmd/frostfs-adm/internal/modules/morph/contract/dump_hashes.go: // Related https://github.com/nspcc-dev/neofs-contract/issues/316. cmd/frostfs-adm/internal/modules/morph/helper/netmap.go: // In NeoFS this is done via Notary contract. Here, however, we can form the cmd/frostfs-adm/internal/modules/morph/initialize/initialize.go: // 4. Deploy NeoFS contracts. cmd/frostfs-adm/internal/modules/morph/initialize/initialize.go: cmd.Println("Stage 4: deploy NeoFS contracts.") cmd/frostfs-adm/internal/modules/morph/initialize/initialize_roles.go: callflag.States|callflag.AllowNotify, int64(noderoles.NeoFSAlphabet), pubs) cmd/frostfs-adm/internal/modules/morph/initialize/initialize_roles.go: pubs, err := helper.GetDesignatedByRole(c.ReadOnlyInvoker, rolemgmt.Hash, noderoles.NeoFSAlphabet, height) cmd/frostfs-adm/internal/modules/storagecfg/config.go: neofsMainnetAddress = "2cafa46838e8b564468ebd868dcafdd99dce6221" cmd/frostfs-adm/internal/modules/storagecfg/config.go: neofsTestnetAddress = "b65d8243ac63983206d17e5221af0653a7266fa1" cmd/frostfs-adm/internal/modules/storagecfg/config.go: NeoFSContract string cmd/frostfs-adm/internal/modules/storagecfg/config.go: NeoFSContract: neofsTestnetAddress, cmd/frostfs-adm/internal/modules/storagecfg/config.go: NeoFSContract: neofsMainnetAddress, cmd/frostfs-adm/internal/modules/storagecfg/root.go: ok := getConfirmation(false, fmt.Sprintf("Current NeoFS balance is %s, make a deposit? y/[n]: ", cmd/frostfs-adm/internal/modules/storagecfg/root.go: neofsHash, _ := util.Uint160DecodeStringLE(n3config[network].NeoFSContract) cmd/frostfs-adm/internal/modules/storagecfg/root.go: txHash, _, err := mainGas.Transfer(accSH, neofsHash, amount, nil) cmd/frostfs-adm/internal/modules/storagecfg/root.go: fatalOnErr(fmt.Errorf("sending TX to the NeoFS contract: %w", err)) cmd/frostfs-cli/docs/storage-node-xheaders.md:"well-known" headers may also use `__NEOFS__` prefix: cmd/frostfs-node/config/node/config.go:// Panics if the value is not a string list of valid NeoFS network addresses. cmd/frostfs-node/container.go: // TODO: use owner directly from the event after neofs-contract#256 will become resolved cmd/frostfs-node/object.go: keys, err := fn.sidechain.NeoFSAlphabetList() config/example/cli.yaml:rpc-endpoint: s01.frostfs.devenv:8080 # NeoFS API endpoint of NeoFS node config/example/cli.yaml:endpoint: localhost:8090 # Control API endpoint of NeoFS node config/example/ir.env:FROSTFS_IR_WORKERS_NEOFS=10 config/example/ir.env:FROSTFS_IR_CONTRACTS_NEOFS=ee3dee6d05dc79c24a5b8f6985e10d68b7cacc62 config/example/ir.env:FROSTFS_IR_CONTRACTS_NEOFSID=9f5866decbc751a099e74c7c7bc89f609201755a config/example/node.yaml:contracts: # side chain NEOFS contract script hashes; optional, override values retrieved from NNS contract config/mainnet/README.md:To use NeoFS in the Mainnet, you need to deposit assets to NeoFS contract. config/testnet/README.md:There is a prepared configuration for NeoFS Storage Node deployment in config/testnet/README.md:Successfully tagged nspccdev/neofs-storage-testnet:0.25.1 config/testnet/README.md:The Storage Node owner should deposit GAS to NeoFS smart contract. It generates a config/testnet/README.md:Then, make a deposit by transferring GAS to NeoFS contract in N3 Testnet. config/testnet/README.md:NeoFS contract scripthash in N3 Testnet is `b65d8243ac63983206d17e5221af0653a7266fa1`, config/testnet/README.md:NEOFS_GRPC_0_ENDPOINT=65.52.183.157:36512 config/testnet/README.md:NEOFS_NODE_ADDRESSES=65.52.183.157:36512 config/testnet/README.md:NEOFS_GRPC_0_ENDPOINT=65.52.183.157:36512 config/testnet/README.md:NEOFS_NODE_ADDRESSES=65.52.183.157:36512 config/testnet/README.md:NEOFS_NODE_ATTRIBUTE_2=UN-LOCODE:RU LED config/testnet/README.md:[NeoFS LOCODE database](https://git.frostfs.info/TrueCloudLab/frostfs-locode-db/releases/tag/v0.4.0) config/testnet/README.md:NeoFS objects will be stored on your machine. By default, docker-compose config/testnet/README.md: - NEOFS_LOGGER_LEVEL=debug pkg/innerring/fetcher.go:// InnerRingKeys fetches list of innerring keys from NeoFSAlphabet pkg/innerring/fetcher.go: return fN.cli.NeoFSAlphabetList() pkg/innerring/initialization.go: // if mainchain is disabled we should use NeoFSAlphabetList client method according to its docs pkg/innerring/processors/governance/handlers.go: if et.Role != noderoles.NeoFSAlphabet { pkg/innerring/processors/governance/handlers_test.go: Role: noderoles.NeoFSAlphabet, pkg/innerring/processors/governance/handlers_test.go:func (c *testMorphClient) UpdateNeoFSAlphabetList(_ context.Context, prm client.UpdateAlphabetListPrm) error { pkg/innerring/processors/governance/handlers_test.go:func (c *testMainnetClient) NeoFSAlphabetList() (res keys.PublicKeys, err error) { pkg/innerring/processors/governance/process_update.go: mainnetAlphabet, err := gp.mainnetClient.NeoFSAlphabetList() pkg/innerring/processors/governance/process_update.go: // 2. Update NeoFSAlphabet role in the sidechain. pkg/innerring/processors/governance/process_update.go: gp.updateNeoFSAlphabetRoleInSidechain(ctx, sidechainAlphabet, newAlphabet, txHash) pkg/innerring/processors/governance/process_update.go:func (gp *Processor) updateNeoFSAlphabetRoleInSidechain(ctx context.Context, sidechainAlphabet, newAlphabet keys.PublicKeys, txHash util.Uint256) { pkg/innerring/processors/governance/process_update.go: if err = gp.morphClient.UpdateNeoFSAlphabetList(ctx, updPrm); err != nil { pkg/innerring/processors/governance/processor.go: NeoFSAlphabetList() (res keys.PublicKeys, err error) pkg/innerring/processors/governance/processor.go: UpdateNeoFSAlphabetList(ctx context.Context, prm client.UpdateAlphabetListPrm) error pkg/morph/client/client.go:// NeoFSAlphabetList returns keys that stored in NeoFS Alphabet role. Main chain pkg/morph/client/client.go:func (c *Client) NeoFSAlphabetList() (res keys.PublicKeys, err error) { pkg/morph/client/client.go: list, err := c.roleList(noderoles.NeoFSAlphabet) pkg/morph/client/notary.go:// UpdateAlphabetListPrm groups parameters of UpdateNeoFSAlphabetList operation. pkg/morph/client/notary.go:// UpdateNeoFSAlphabetList updates list of alphabet nodes in designate contract. pkg/morph/client/notary.go:func (c *Client) UpdateNeoFSAlphabetList(ctx context.Context, prm UpdateAlphabetListPrm) error { pkg/morph/client/notary.go: noderoles.NeoFSAlphabet, pkg/morph/event/rolemanagement/designate_test.go: args := []stackitem.Item{stackitem.Make(int(noderoles.NeoFSAlphabet)), stackitem.Make(123)} pkg/morph/event/rolemanagement/designate_test.go: require.Equal(t, noderoles.NeoFSAlphabet, e.(Designate).Role) ``` </details>
potyarkin added the
enhancement
good first issue
labels 2024-12-13 14:59:14 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: TrueCloudLab/frostfs-node#1561
No description provided.