Skip to content

Commit

Permalink
Update dagsync README
Browse files Browse the repository at this point in the history
  • Loading branch information
gammazero committed Jan 31, 2024
1 parent 6bd1244 commit d4d82f5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions dagsync/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Typically an application will be either a provider or a subscriber, but may be b

### Publisher

Create a dagsync publisher. Update its root to cause it to publish.
Create a dagsync publisher. Update its root to publish a new advertisement. Send announcement messages to inform indexers a new advertisement is available.

```golang
publisher, err := ipnisync.NewPublisher(linkSys, privKey,
Expand All @@ -19,7 +19,7 @@ if err != nil {
panic(err)
}

// Create an announce senders to send advertisement announcements..
// Create announcement senders to send advertisement announcements to indexers.
var senders []announce.Sender
httpSender, err := httpsender.New(announceURLs, id)
if err != nil {
Expand Down Expand Up @@ -49,7 +49,7 @@ if err != nil {

### Subscriber

The `Subscriber` handles subscribing to a topic, reading messages from the topic and tracking the state of each publisher.
The `Subscriber` reads advertisement chains from index-providers. Its announcement receiver receives libp2p pubsub messages from a topic and direct HTTP announcements. The Subscriber reads advertisements is response to announcement messages.

Create a `Subscriber`:

Expand Down

0 comments on commit d4d82f5

Please sign in to comment.