Skip to content
This repository has been archived by the owner on May 26, 2022. It is now read-only.

describe how to use options in README #105

Merged
merged 1 commit into from Dec 14, 2021
Merged

Conversation

marten-seemann
Copy link
Contributor

No description provided.

To use TCP transport options, pass them to the `libp2p.Transport` constructor:
```go
h, err := libp2p.New(
libp2p.Transport(tcp.NewTCPTransport, tcp.DisableReuseport(), tcp.WithConnectionTimeout(20*time.Second))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seams like a good way to do this, but it's not currently supported. Are you planning on implementing it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As of libp2p/go-libp2p#1205, it is implemented. It's just not released yet

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We probably should hold this PR back until we've cut the next go-libp2p release.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, that's really cool!

@BigLep
Copy link

BigLep commented Oct 24, 2021

@marten-seemann : can this be merged?

@marten-seemann
Copy link
Contributor Author

Not yet, we haven't cut the next go-libp2p release yet.

@BigLep
Copy link

BigLep commented Oct 24, 2021 via email

@marten-seemann marten-seemann merged commit 1c17791 into master Dec 14, 2021
@marten-seemann marten-seemann deleted the readme-options branch December 14, 2021 08:33
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants