Skip to content

Commit 08ef9f4

Browse files
authored
docs(concepts): improve writing style (#3354)
1 parent 2fb1634 commit 08ef9f4

File tree

9 files changed

+44
-42
lines changed

9 files changed

+44
-42
lines changed

markdown/docs/concepts/application.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@ weight: 23
55

66

77
## What is an application?
8-
An application is any computer program or a group of them.
8+
An _application_ is a computer program or a group of them.
99

10-
An application could also be a micro-service, IoT device (sensor), mainframe process, etc. Users may even write applications in different programming languages if they support one of the selected protocols.
10+
An application can be a micro-service, IoT (Internet of things) device (for example, a sensor), mainframe process, and more. Users can create applications using various programming languages that support the chosen protocols.
1111

1212
## Why do we need applications?
13-
In Event-Driven Architecture (EDA), an application must be a `producer`, a `consumer`, or both. Applications must also use the protocols the server supports if they wish to connect and exchange messages.
13+
In Event-Driven Architecture (EDA), an application can either be a producer, a consumer, or both. Additionally, if an application wants to connect and exchange messages with the server, it must adhere to the protocols supported by the server.
1414

1515
### Applications: producers and consumers
1616
```mermaid
@@ -20,4 +20,5 @@ flowchart TD
2020
C --> D[message]
2121
D --> F[CONSUMER application]
2222
```
23-
The above diagram describes a message communication traveling through a channel between a **PRODUCER application** and a **CONSUMER application**.
23+
24+
The diagram above illustrates a message transmission between a Producer application and a Consumer application through a channel.

markdown/docs/concepts/asyncapi-document/index.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ title: 'Introduction'
33
weight: 50
44
---
55

6-
The AsyncAPI Specification defines a set of fields that can be used in an AsyncAPI document to describe an application's API. The document may reference other files for additional details or shared fields, but it is typically a single, primary document that encapsulates the API description.
6+
The AsyncAPI Specification defines a set of fields that can be used in an AsyncAPI document to describe an applications API. While the document may reference other files for additional details or shared fields, it usually serves as a single, primary document that encapsulates the API description.
77

8-
Furthermore, the AsyncAPI document acts as a communication contract between `receivers` and `senders` within an event-driven system. It specifies the payload content required when a service sends a message and offers clear guidance to the receiver regarding the message's properties.
8+
Furthermore, the AsyncAPI document acts as a communication contract between receivers and senders within an event-driven system. It specifies the payload content necessary for a service to send a message and provides clear guidance to the receiver about the message's properties.
99

10-
```YAML
10+
```yaml
1111
asyncapi: 3.0.0
1212
info:
1313
title: Cool Example
@@ -37,7 +37,5 @@ operations:
3737
```
3838
3939
<Remember>
40-
You might have additional fields depending on the implemented protocol (i.e., MQTT, AMQP, Kafka, etc.).
41-
42-
For example, your AsyncAPI document could have additional fields for <a href= "https://github.com/asyncapi/bindings/tree/master/kafka">configuring Kafka bindings</a>.
40+
Depending on the implemented protocol (such as MQTT, AMQP, Kafka, etc.), you may have additional fields in your AsyncAPI document. For example, for <a href= "https://github.com/asyncapi/bindings/tree/master/kafka">configuring Kafka bindings</a>.
4341
</Remember>

markdown/docs/concepts/channel.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,10 @@ weight: 20
44
---
55

66
# What is a channel?
7-
A `channel` is a mechanism created by the server for the organization and transmission of messages. Users can define channels as a _topic, queue, routing key, path,_ or _subject_ depending on the protocol used.
7+
A _channel_ is a mechanism created by the server that facilitates the organization and transmission of messages. Depending on the used protocol, users can define channels as a _topic_, _queue_, _routing key_, _path_, or _subject_.
88

99
# Why do we need channels?
10-
Channels play a crucial role in communication between `producers` and `consumers`. A producer can send a message through the channel, and the consumer receives messages from a particular channel. A channel's sole purpose is to ensure the right messages route to the right consumers.
11-
12-
10+
Channels are pivotal for establishing communication between producers and consumers. They enable producers to send messages, while consumers receive messages from specific channels. The primary function of a channel is to ensure that the intended messages reach the appropriate consumers.
1311

1412
```mermaid
1513
graph LR
@@ -19,4 +17,6 @@ graph LR
1917
C --> E[Consumer]
2018
C --> F[Consumer]
2119
```
22-
The diagram above shows the communication between a `producer` and `consumer`, with the producer sending a `message` through the `channel`. The channel then queues the message to the specific consumer.
20+
21+
The diagram above illustrates the communication process between a producer and a consumer. The producer sends a message through the channel, which then queues the message for delivery to the specific consumer.
22+
The diagram above illustrates the communication process between a producer and multiple consumers. The producer sends a message through the channel, which then queues the message for delivery to the appropriate consumers.

markdown/docs/concepts/consumer.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ weight: 4
44
---
55

66
## What is a consumer?
7-
In an Event Driven Architecture (EDA), a consumer is an application that listens for a particular event from a broker and reacts to it.
7+
A _consumer_ is an application that subscribes to a specific event from a broker and responds accordingly.
88

99
## Why do we need consumers?
10-
Unlike traditional REST APIs, in EDA, event consumers 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.
10+
Unlike traditional REST APIs, in Event-Driven Architecture (EDA), event consumers are asynchronous, which means they are not required to respond immediately on the same connection. In this architecture, consumers are unaware of the producers or other consumers. All they know is that when a broker sends them an event, it is because they have subscribed to it.
1111

12-
When you want events processed asynchronously in your application, the consumer plays an important role in completing that event data flow in the event channel.
12+
When you want your application to process events asynchronously, the consumer plays a crucial role in completing the event data flow through the event channel.
1313

1414
```mermaid
1515
flowchart LR
@@ -26,7 +26,8 @@ flowchart LR
2626
end
2727
```
2828

29-
The above diagram depicts a sample flow of events from `producer` to `broker` to `consumer`. In this instance, the `producer` publishes two events _(A and B)_ and sends them to the `broker`. Then each `consumer` subscribes to receive those events.
29+
The diagram above illustrates a sample flow of events from the `producer` to the `broker` to the `consumers`. In this scenario, the `producer` publishes two events _(A and B)_ and sends them to the `broker`. Subsequently, each `consumer` subscribes to receive those events.
30+
3031
<Remember>
3132
<b>Subscribers</b> can also be <a href="https://www.asyncapi.com/docs/concepts/producer">producers</a>.
3233
</Remember>

markdown/docs/concepts/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ weight: 1
55

66
import ContributionNotes from '@/assets/docs/fragments/contribution-notes.md';
77

8-
## Concepts: Define AsyncAPI features and capabilities
8+
## Concepts
99

10-
Welcome to AsyncAPI **Concepts**! Our Concepts section will define the concepts of AsyncAPI features and capabilities.
10+
Welcome to AsyncAPI **Concepts**! This section defines AsyncAPI features and capabilities.
1111

1212
<Remember>
1313

markdown/docs/concepts/message.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,9 @@ weight: 30
44
---
55

66
## What is a message?
7-
A `message` is a communication asset used to transmit or exchange information from a sender to the receiver through `channels`. A single `message` can be consumed by multiple independent receivers and can also be defined as an _event_ or _command_. The sender includes a payload of data (that has been serialized into an appropriate format, e.g., JSON, XML, binary, etc.) that needs to be processed by the receiver. It may also include metadata; information that describes the message itself. This metadata is often known as _headers_ or _properties_.
7+
A _message_ is a communication asset that transmits or exchanges information from a sender to the receiver through channels.
88

9+
One message can also be defined as an event or command and can be consumed by multiple independent receivers. The sender encodes a payload of data (serialized into a suitable format, such as JSON, XML, binary, or others) that requires processing by the receiver. Additionally, the message may include _metadata_, which is information that describes the message itself. This metadata is commonly referred to as _headers_ or _properties_.
910

1011
``` mermaid
1112
graph LR
@@ -17,11 +18,10 @@ A{{sender application}} --> b --> C{{receiver application}}
1718
1819
```
1920

20-
In the diagram above, the sender application transmits a `message` to the receiver application.
21+
The diagram above illustrates how a sender application transmits a message through a channel to a receiver application, demonstrating the basic flow of message-based communication.
2122

2223
## Messages vs Events
23-
A `message` carries information from one application to the other, while an `event` is a message that provides details of something that has already occurred. One important aspect to note is that depending on the type of information a `message` contains, it can fall under an _event_, _query_, or _command_.
24-
*See the diagram below.*
24+
A **message** conveys information between applications, while an **event** is a message that provides details of something that has already occurred. A crucial aspect to note is that depending on the type of information a message carries, it can either be an event, query, or command. Check the diagram below.
2525

2626
``` mermaid
2727
graph TD
@@ -32,4 +32,4 @@ graph TD
3232
C --> E(Command)
3333
```
3434

35-
Overall, `events` are `messages` but not all `messages` are `events`.
35+
Summing up, events are messages, but not all messages are events.

markdown/docs/concepts/producer.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,24 +4,26 @@ weight: 3
44
---
55

66
## What is a Producer?
7-
A producer is an application that senses state changes (events) and publishes those events as messages. An event indicates a state change or update triggered by a user's/device's action.
7+
A _producer_ is an application that detects state changes (_events_) and publishes these events as messages. An event signifies a state change or update triggered by a user’s or devices action.
88

99
The following are sample events:
10-
* Placing an item in a shopping cart on an e-commerce website.
10+
* Adding an item to a shopping cart on an e-commerce website.
1111
* Clicking the subscribe button on a YouTube channel.
12-
* A temperature change in a sensor.
12+
* Detecting a temperature change using a sensor.
13+
1314

1415
## Why do we need Producers?
15-
One of the core concepts of event-driven architecture is the publish/subscribe communication model. Producers are publishers in this model; they're the first logical layer responsible for distributing messages to the broker so that others can subscribe to receive messages.
16+
The publish/subscribe communication model is one of the core concepts of event-driven architecture. In this model, producers are publishers, acting as the first logical layer responsible for distributing messages to the broker, enabling others to subscribe and receive these messages.
1617

1718
```mermaid
1819
flowchart TD
1920
a[Producer]-- Message 1 --->d[(Broker)]
2021
d -- Message 1 --->g[Consumer]
2122
```
22-
The diagram above depicts the communication between a **producer** publishing events to a specific channel in a **broker** and a **consumer** subscribed to the same channel.
2323

24-
In some cases, an entity can be both a producer publishing messages to a specific channel in the broker and a consumer subscribing to messages from a different channel in the broker.
24+
The diagram above illustrates the communication flow between a producer who publishes events to a specific channel in a broker and a consumer who subscribes to the same channel.
25+
26+
In some cases, an entity can simultaneously function as both a producer, publishing messages to a specific channel in the broker, and a consumer, subscribing to messages from a different channel in the broker.
2527

2628
```mermaid
2729
flowchart LR
@@ -31,4 +33,4 @@ flowchart LR
3133
c -- Message 2 ---> d[Consumer]
3234
```
3335

34-
In the diagram above, we see a producer publishing messages to a specific channel and a consumer subscribing to messages from that channel. We also have a second producer who publishes to one channel, but subscribes to messages from another.
36+
In the diagram above, there is a producer publishing messages to a specific channel and a consumer subscribing to messages from that channel. Also, there is a second producer publishing to one channel and subscribing to messages from another channel.

markdown/docs/concepts/protocol.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ weight: 25
55

66

77
## What is a protocol?
8-
A protocol is a set of rules that specifies how information is exchanged between applications and/or servers.
8+
A _protocol_ is a set of rules that governs the exchange of information between applications and/or servers.
99

1010
Protocol examples:
1111
* [WebSockets](https://developer.mozilla.org/en-US/docs/Web/API/WebSocket)
@@ -14,7 +14,7 @@ Protocol examples:
1414
* [MQTT](https://mqtt.org/)
1515

1616
## Why do we need protocols?
17-
Whenever a producer detects a state change (events) and publishes those events as messages, a protocol carries those messages to the channel and then to a consumer. Protocol plays a vital role in message transmission.
17+
Protocols play a crucial role in message transmission. Whenever a producer detects a state change (events) and publishes those events as messages, a protocol carries those messages to the channel and then to the consumer.
1818

1919
```mermaid
2020
sequenceDiagram
@@ -23,8 +23,8 @@ sequenceDiagram
2323
Publisher->>+Publisher: Delete(Msg)
2424
```
2525

26-
The diagram above depicts the message exchange flow from `producer` to `broker` to `consumer` using the MQTT protocol with QoS0 (quality of service 0). This means that information exchanged from `producer` to `broker` to `consumer` is delivered at most once.
26+
The diagram above illustrates the message exchange flow from `producer` to `broker` to `consumer` using the MQTT protocol with QoS0 (quality of service 0). In other words, the information transferred from the producer to broker to consumer is delivered at most once.
2727

28-
The quality of service information rule is specified on a protocol level. Broker implementations and other involved actors must act accordingly.
28+
The quality of service information rule is defined at the protocol level. Broker implementations and other involved parties must adhere to this rule.
2929

30-
In AsyncAPI documents, all protocol-specific details that the application follows can be described using [bindings](/docs/reference/specification/v2.5.0#definitionsBindings).
30+
In AsyncAPI documents, all protocol-specific details that the application follows can be described using [bindings](https://www.asyncapi.com/docs/reference/specification/latest#definitionsBindings).

markdown/docs/concepts/server.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ weight: 2
55

66

77
## What is a server?
8-
A server represents a messaging broker system where connections and communication between a producer and a consumer are established. Unlike traditional API servers which are dependent on request/response, message broker interactions occur back and forth over different channels.
8+
A _server_ acts as a _messaging broker_ system, establishing connections and facilitating communication between [_producers_](producer) and [_consumers_](consumer). Unlike traditional API servers that rely on request-response interactions, message broker interactions occur bidirectionally across various channels.
99

1010
## What is the purpose of servers?
11-
Servers play an important role in maintaining a relationship between producers and consumers. When designing and setting up an event-driven application, servers are in charge of delivering asynchronous messages from the producer to the consumers through the use of channels. By integrating different messaging protocols, servers can transmit and exchange messages between clients.
11+
Servers play a crucial role in establishing a connection between producers and consumers. In the context of designing and setting up an event-driven application, servers are responsible for delivering asynchronous messages from the producer to the consumers through the use of [_channels_](channel). Additionally, servers can integrate various messaging [_protocols_](protocol) to facilitate the transmission and exchange of messages between _clients_.
1212

1313
### Clients and Server
1414
```mermaid
@@ -18,7 +18,7 @@ flowchart TD
1818
c[Client Mobile] --> b[(server)]
1919
b --> c
2020
```
21-
The diagram above describes a bi-directional communication between several **clients** and one **server**. In this case, in your AsyncAPI file, you describe the `server`, and therefore the [`Server Object`](https://www.asyncapi.com/docs/reference/specification/latest#serverObject) holds information about the actual server, including its physical location.
21+
The diagram above illustrates a bidirectional communication between one server and several clients. In this case, in your AsyncAPI file, you describe the `server`, so the [`Server Object`](https://www.asyncapi.com/docs/reference/specification/latest#serverObject) holds information about the actual server, including its physical location.
2222

2323

2424
### Broker Centric
@@ -35,4 +35,4 @@ flowchart TD
3535
a2 --> C[consumer2]
3636
```
3737

38-
The diagram above shows the *Broker Centric Architecture*. In this case, we created three AsyncAPI files for the `producer`, `consumer1`, and `consumer2`. In these AsyncAPI files, the [`Server Object`](https://www.asyncapi.com/docs/reference/specification/latest#serverObject) provides information about the `broker`, so that API users know where to connect to start receiving or sending messages.
38+
The diagram above illustrates the Broker-centric Architecture. In this case, there are three AsyncAPI files for the `producer`, `consumer1`, and `consumer2`. In these AsyncAPI files, the [`Server Object`](https://www.asyncapi.com/docs/reference/specification/latest#serverObject) provides information about the `broker`, so that API users know where to connect to start receiving or sending messages.

0 commit comments

Comments
 (0)