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

docs: add new consumer concept doc #991

Merged
merged 14 commits into from
Oct 25, 2022

Conversation

Annysah
Copy link
Contributor

@Annysah Annysah commented Sep 29, 2022

Description

  • New concept doc: Consumer concept

Related issue(s)
Fixes #975

@netlify
Copy link

netlify bot commented Sep 29, 2022

Deploy Preview for asyncapi-website ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 637ba03
🔍 Latest deploy log https://app.netlify.com/sites/asyncapi-website/deploys/6357299497530800083676ee
😎 Deploy Preview https://deploy-preview-991--asyncapi-website.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@Annysah
Copy link
Contributor Author

Annysah commented Sep 29, 2022

Hello @alequetzalli & @derberg, I will love your feedbacks.
Thank you!

@github-actions
Copy link

github-actions bot commented Sep 29, 2022

⚡️ Lighthouse report for the changes in this PR:

Category Score
🔴 Performance 44
🟠 Accessibility 88
🟠 Best practices 83
🟢 SEO 90
🔴 PWA 30

Lighthouse ran on https://deploy-preview-991--asyncapi-website.netlify.app/

@quetzalliwrites quetzalliwrites added 📑 docs area/docs Specify what technical area given issue relates to. Its goal is to ease filtering good first issues. gsod This label should be used for issues or discussions related to ideas for Google Season of Docs labels Sep 29, 2022
@quetzalliwrites
Copy link
Member

quetzalliwrites commented Sep 29, 2022

AMAZING WORK on your first Concept Doc and nice new diagram! Thank you for your contribution ✨✨✨

Let's get a technical review from folks like @derberg, @fmvilas and/or @smoya first, and once technical feedback is done, I will conduct an editorial review.

## What is a Consumer?
In an Event Driven Architecture (EDA), a consumer is a component of an application or messaging system that listens for a particular event from a broker and takes the necessary action in response.

## Why do we need Consumers?
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
## Why do we need Consumers?
## What is the purpose of Consumers?

This is the outline all Concept Docs will have: What is the purpose of _____?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Okay, I will correct that asap!

Copy link
Member

Choose a reason for hiding this comment

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

don't hate but i changed my mind :D haha!

Let's stick with your original one, I went ahead and fixed it :D

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Alrighty!

Copy link
Member

@derberg derberg left a comment

Choose a reason for hiding this comment

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

Nice! Left some comments

thought: since we have producer document already in master
maybe, maybe it is good it interlink them? So at the end of your document you can add a note like: "yo, subscribers can actually also be producers. Go to this blabla to learn what producer is". and similar note could be added to the producer doc. Thoughts?

---

## What is a Consumer?
In an Event Driven Architecture (EDA), a consumer is a component of an application or messaging system that listens for a particular event from a broker and takes the necessary action in response.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
In an Event Driven Architecture (EDA), a consumer is a component of an application or messaging system that listens for a particular event from a broker and takes the necessary action in response.
In an Event Driven Architecture (EDA), a consumer is an application that listens for a particular event from a broker and reacts to it.

application

I think it is good to be consistent with producer document that was just released

takes the necessary action in response

I would avoid response as it is known term in request/response pattern, and might be suggest consumer sends a response

In an Event Driven Architecture (EDA), a consumer is a component of an application or messaging system that listens for a particular event from a broker and takes the necessary action in response.

## What is the purpose of Consumers?
Unlike traditional RestAPIs, EDA creates a setting where there is never a wait for requests or responses to an event. In this pattern, a consumer is unaware of the producer or other consumers; all they know is that when a broker sends them an event they are subscribed to, they receive it.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
Unlike traditional RestAPIs, EDA creates a setting where there is never a wait for requests or responses to an event. In this pattern, a consumer is unaware of the producer or other consumers; all they know is that when a broker sends them an event they are subscribed to, they receive it.
Unlike traditional REST APIs, in EDA, consumers of the event are not expected to respond immediately on the same connection. In this architecture, a consumer is unaware of the producer or other consumers; all they know is that when a broker sends them an event, it is because they subscribed to it.

how about this? just to clarify about communication that it is not on sync, because sometimes people do request/response in EDA, but it is still async. Like in DM on Slack, you send question, you do not know who will answer, but you definitely expect that in a thread at some point of time someone will send a response. Makes sense

you can freely adjust the paragraph, my suggestions are just to "visualize" what I mean

f
end
```
The diagram above depicts an example of the flow of events from a producer to a broker and then to the consumers. In this instance, the producer publishes two events, A & B and sends to the broker. Then each consumer receives events from what it is subscribed to.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
The diagram above depicts an example of the flow of events from a producer to a broker and then to the consumers. In this instance, the producer publishes two events, A & B and sends to the broker. Then each consumer receives events from what it is subscribed to.
The diagram above depicts an example of the flow of events from a producer to a broker and then to the consumers. In this instance, the producer publishes two events, A & B, and sends them to the broker. Then each consumer receives events that they are subscribed to.

@Annysah
Copy link
Contributor Author

Annysah commented Oct 7, 2022

Nice! Left some comments

thought: since we have producer document already in master maybe, maybe it is good it interlink them? So at the end of your document you can add a note like: "yo, subscribers can actually also be producers. Go to this blabla to learn what producer is". and similar note could be added to the producer doc. Thoughts?

Great idea!

@Annysah
Copy link
Contributor Author

Annysah commented Oct 7, 2022

I will make all the requested changes. Thanks @derberg

@Annysah
Copy link
Contributor Author

Annysah commented Oct 7, 2022

Dear @alequetzalli & @derberg, I just updated the content to be in sync with the requested changes

Copy link
Member

@derberg derberg left a comment

Choose a reason for hiding this comment

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

Perfect! I just noticed one formatting issue

The above diagram depicts a sample flow of events from producer to broker and consumer. In this instance, the producer publishes two events, A & B, and sends them to the broker. Then each consumer subscribes to receive those events.

<Remember>
`Subscribers` can also be [`producers`](https://www.asyncapi.com/docs/concepts/producer).
Copy link
Member

Choose a reason for hiding this comment

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

I don't think markdown render well in the component

Screenshot 2022-10-12 at 09 52 08

isn't it better to just do markdown note/quote >

Copy link
Member

Choose a reason for hiding this comment

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

Ahhh haha noooo. ✌🏽😂

In this scenario, I believe Anisat's original idea to use our React Remember component is a good idea because it's a helpful visual reminder that stands out.

The solution (to me) is to instead use appropriate HTML tags within our React Remember component, and then teach Anisat that we can't use MD syntax in these components. 😄🙌🏽

I fixed it and think this looks good to merge now too 🎉🎉🎉
Screen Shot 2022-10-24 at 5 13 42 PM

@derberg
Copy link
Member

derberg commented Oct 18, 2022

@Annysah heyo, just pinging you as looks like just one tiny change is needed and we can merge

@Annysah
Copy link
Contributor Author

Annysah commented Oct 21, 2022

@Annysah heyo, just pinging you as looks like just one tiny change is needed and we can merge

Thanks @derberg, I will do the update now.

Copy link
Member

@quetzalliwrites quetzalliwrites left a comment

Choose a reason for hiding this comment

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

🚢 🛳 🚢 🛳 🚢 🛳 🚢 🛳 🚢 🛳 🚢 🛳 🚢 🛳

@quetzalliwrites quetzalliwrites merged commit 3854508 into asyncapi:master Oct 25, 2022
@derberg
Copy link
Member

derberg commented Oct 25, 2022

@all-contributors please add @Annysah for docs

@allcontributors
Copy link
Contributor

@derberg

I've put up a pull request to add @Annysah! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/docs Specify what technical area given issue relates to. Its goal is to ease filtering good first issues. 📑 docs gsod This label should be used for issues or discussions related to ideas for Google Season of Docs
Projects
Status: Done 🚀
Development

Successfully merging this pull request may close these issues.

[📑 Docs]: new consumer concept doc
3 participants