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

Should we add node address utils in SDK? #381

Open
rkonfj opened this issue Feb 21, 2023 · 3 comments
Open

Should we add node address utils in SDK? #381

rkonfj opened this issue Feb 21, 2023 · 3 comments
Labels
feature Completely new functionality I3 Minimal impact S4 Routine U4 Nothing urgent
Milestone

Comments

@rkonfj
Copy link

rkonfj commented Feb 21, 2023

Like this:
https://github.com/nspcc-dev/neofs-node/blob/d4b108d8065f8268a988cf3966e181f02e1e5af7/pkg/network/address.go

@rkonfj
Copy link
Author

rkonfj commented Feb 21, 2023

Such a scene:

  1. get address from command line arg
    https://github.com/nspcc-dev/neofs-s3-gw/blob/74f31c31498f397ee415f92d1883349c8400947c/cmd/s3-gw/app.go#L121
  2. dial this address directly
    https://github.com/nspcc-dev/neofs-s3-gw/blob/74f31c31498f397ee415f92d1883349c8400947c/internal/neofs/tree.go#L95

If the command line needs to support multiaddr, where and how to parse it?

@roman-khimov
Copy link
Member

I guess what you need is https://pkg.go.dev/github.com/nspcc-dev/neofs-api-go/v2/rpc/client#ParseURI
I'm not sure it should be a part of the SDK though, SDK provides a client that operates with https://pkg.go.dev/github.com/nspcc-dev/[email protected]/client#PrmDial.SetServerURI

@roman-khimov roman-khimov added U4 Nothing urgent S4 Routine I3 Minimal impact feature Completely new functionality labels Dec 20, 2023
cthulhu-rider added a commit that referenced this issue Nov 26, 2024
The function is placed inside the lib to facilitate its support and as a
preliminary preparation for the obsolescence of
`github.com/nspcc-dev/neofs-api-go/v2` module.

Refs #381.

Signed-off-by: Leonard Lyubich <[email protected]>
@roman-khimov
Copy link
Member

Relevant for the node, nspcc-dev/neofs-node#3057.

@roman-khimov roman-khimov added this to the v1.0.0-rc13 milestone Dec 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Completely new functionality I3 Minimal impact S4 Routine U4 Nothing urgent
Projects
None yet
Development

No branches or pull requests

2 participants