2020-12-14
4326
#rust#web3
Mario Zupan
30541
Dec 14, 2020 ⋅ 15 min read

libp2p tutorial: Build a peer-to-peer app in Rust

Mario Zupan I'm a self-employed Software Engineer and Trainer living in Vienna, Austria. I've worked at several companies and in multiple fields building, maintaining and operating distributed systems at scale using Java, Kotlin, Node, Go and Rust. I also taught advanced software engineering courses for several years at the University of Applied Sciences FH Joanneum in Graz and worked as a technical trainer, empowering other software engineers to reach their full potential. Currently, I work as a freelance software engineer and trainer again, looking to help companies build high-quality software solutions. Check out my personal blog: http://www.zupzup.org.

Recent posts:

Rxjs Adoption Guide: Overview, Examples, And Alternatives

RxJS adoption guide: Overview, examples, and alternatives

Get to know RxJS features, benefits, and more to help you understand what it is, how it works, and why you should use it.

Emmanuel Odioko
Jul 26, 2024 ⋅ 13 min read
Decoupling Monoliths Into Microservices With Feature Flags

Decoupling monoliths into microservices with feature flags

Explore how to effectively break down a monolithic application into microservices using feature flags and Flagsmith.

Kayode Adeniyi
Jul 25, 2024 ⋅ 10 min read
Lots of multi-colored blue and purplish rectangles.

Animating dialog and popover elements with CSS @starting-style

Native dialog and popover elements have their own well-defined roles in modern-day frontend web development. Dialog elements are known to […]

Rahul Chhodde
Jul 24, 2024 ⋅ 10 min read
Using Llama Index To Add Personal Data To Large Language Models

Using LlamaIndex to add personal data to LLMs

LlamaIndex provides tools for ingesting, processing, and implementing complex query workflows that combine data access with LLM prompting.

Ukeje Goodness
Jul 23, 2024 ⋅ 5 min read
View all posts

3 Replies to "libp2p tutorial: Build a peer-to-peer app in Rust"

  1. Nice, extending bit basic example available in source, but I think it should be fair to highlight that this example is oversimplified:
    1) it’s using only mDNS for peers discovery so it’ll never get beyond local network
    2) Using floodsub for for responses to particular query is real overkill – response needs to go one node, but it’s amplified all overlay (taking into consideration already inefficient floodsub message replication)

    So couple more things to try:
    1) Enable bootstrap nodes (as already used in libp2p examples)
    2) Use RequestReply NetworkBehaviour to send replies to list query just to interested nodes (might require to include requestor in list broadcast)
    3) Use more efficient Gossipsub instead of Floodsub – basically same interface, so not so much changes

Leave a Reply