Jeromy
bbbc040b60
incorporate lgierths opinions
7 years ago
Jeromy
8d84ecd01b
functional parameters
7 years ago
Jeromy
d04268054f
use new constructor for examples
7 years ago
Errol Chevannes
835b66ab73
Fixed typo.
7 years ago
Steven Allen
6b6687f9e4
reset on error in echo
7 years ago
Steven Allen
d2dd60a285
reset on error in proxy example.
7 years ago
ssikdar1
7f03ab4b6f
Fixing build insctuction so copy and pasting from Readme works
As is go build ./examples/protocol-multiplexing-with-multicodecs
will make the binary name protocol-multiplexing-with-multicodecs
so the next command ./multicodecs won't run
using -o will name the outputfile
7 years ago
verysimplyms
7990195e5f
docs: fix typo in README
7 years ago
Steven Allen
00cf69eb49
examples/echo: recommend -secio
When not using -secio, this command prints a warning. This confuses users so we
should just tell users to use it in the instructions.
fixes #179
7 years ago
David Dias
2c7c62ee3a
docs(examples): give a pass through remaining examples
7 years ago
David Dias
a8926ed732
docs(examples): small refresh to the echo example
7 years ago
David Dias
564e2ba314
docs(examples): reorganize examples and tutorials, add an index
7 years ago
Jeromy
5132c763e3
update example to make it easy to swap out stream muxer
8 years ago
Eric Tang
5b297b7160
typo
8 years ago
Hector Sanjuan
93802a4007
Add http proxy example
The example proxies http requests through a libp2p stream.
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
8 years ago
Hector Sanjuan
9706590149
Add example on how to use multicodecs to encode/decode data on a stream
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
8 years ago
Hector Sanjuan
7e11c6008b
Docs: Improve echo example
* Do not use testutil to generate random keys and ids since this is a testing
dependency. Use crypto.GenerateKeyPair() instead.
* Echo full lines
* Improve output by telling the user what to run
* More code comments
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
8 years ago
Jeromy
ff5be0e63b
seed rand for generation of peer IDs in echo example
8 years ago
Eric Harris-Braun
0f0a36c62c
more imports cleanup, another dup.
8 years ago
Eric Harris-Braun
db919af600
imports cleanup, remove dup
8 years ago
Justin
a92558f752
More fixes
8 years ago
Justin
6ac1064a93
Fix port number of echo example
8 years ago
Justin
6e35a38789
More example fixes
8 years ago
Justin
b7fdb1f20b
Fix path
8 years ago
Hector Sanjuan
7c5d076dc6
Improve echo example:
* Extended explanations and links to relevant godocs
* Some renames (the host is not dummy, it's a basic)
* Use addAddr() and let NewStream open the connection
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
8 years ago
Lars Gierth
f3812decb8
Rename hosts to echo example, remove justtcp example
8 years ago
Lars Gierth
4150c40ebf
Fix hosts example
8 years ago
Jeromy
7aced371c7
extract libp2p-swarm
8 years ago
Jeromy
70872ff663
update deps
8 years ago
Jeromy
1a53ad77b9
extract host interface
8 years ago
Jeromy
cea1fe131f
extract net interface and metrics
8 years ago
Jeromy
0f3ffb2d07
extract conn, addr-util, and testutil
8 years ago
Jeromy
4dd30d824b
switch to using stdlib context package
8 years ago
Jeromy
2eef5a702e
split tcp transports out of the base package
8 years ago
Jeromy
ab39c6f524
don't use ipfsaddr
8 years ago
Jeromy
f9cd03e625
allow hosts example to use secio
8 years ago
Jeromy
a56440a9c7
swarm: pass in stream muxer on construct
8 years ago
Jeromy
713d9a8798
examples: example using swarm and raw tcp (no muxing)
8 years ago
Jeromy
7a3394b1da
host: remember which protocols work for a given peer
8 years ago
Jeromy
8744e460da
update local import paths to reflect org change
8 years ago
Jeromy
c0e2b930e3
update multistream deps and fix code to work with new changes
8 years ago
Jeromy
5100dcec6e
update hosts example
9 years ago
Jeromy
dbbd9bb1e9
add hosts example
9 years ago