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: align text about send receive and publisher and subscriber #934

Merged
merged 4 commits into from
Jun 29, 2023

Conversation

derberg
Copy link
Member

@derberg derberg commented May 11, 2023

  • it is mainly to align definitions with current actions. So instead of Producer and Consumer we have Sender and Receiver. Later in docs we can have more details with diagrams, that receiver can be, that it can be processor, or consumer and what is the difference. So basically Sender and Receiver are more generic and match the new action prop
  • application can also be a broker
  • operations are not mandatory really

some more context https://youtu.be/7urTb207V-8?t=229

spec/asyncapi.md Outdated Show resolved Hide resolved
spec/asyncapi.md Outdated Show resolved Hide resolved
spec/asyncapi.md Outdated Show resolved Hide resolved
spec/asyncapi.md Outdated
@@ -1932,7 +1932,7 @@ The following properties are taken from the JSON Schema definition but their def

- description - [CommonMark syntax](https://spec.commonmark.org/) can be used for rich text representation.
- format - See [Data Type Formats](#dataTypeFormat) for further details. While relying on JSON Schema's defined formats, the AsyncAPI Specification offers a few additional predefined formats.
- default - The default value represents what would be assumed by the consumer of the input as the value of the schema if one is not provided. Unlike JSON Schema, the value MUST conform to the defined type for the Schema Object defined at the same level. For example, of `type` is `string`, then `default` can be `"foo"` but cannot be `1`.
- default - The default value represents what would be assumed by the receiver of the input as the value of the schema if one is not provided. Unlike JSON Schema, the value MUST conform to the defined type for the Schema Object defined at the same level. For example, of `type` is `string`, then `default` can be `"foo"` but cannot be `1`.
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 this change applies. This consumer has nothing to do with producer/consumer stuff.

Suggested change
- default - The default value represents what would be assumed by the receiver of the input as the value of the schema if one is not provided. Unlike JSON Schema, the value MUST conform to the defined type for the Schema Object defined at the same level. For example, of `type` is `string`, then `default` can be `"foo"` but cannot be `1`.
- default - The default value represents what would be assumed by the consumer of the input as the value of the schema if one is not provided. Unlike JSON Schema, the value MUST conform to the defined type for the Schema Object defined at the same level. For example, of `type` is `string`, then `default` can be `"foo"` but cannot be `1`.

Copy link
Member Author

Choose a reason for hiding this comment

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

but in the end it related to schema of message,

The default value represents what would be assumed by the consumer

I think consumer here means the consumer of the message described with the schema

Copy link
Member

Choose a reason for hiding this comment

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

But "consumer" of the JSON Schema may just be a code generation tool for the producer. So the "consumer" here would really be the producer, actually 😅

Copy link
Member Author

Choose a reason for hiding this comment

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

to be honest, in general The default value represents what would be assumed by the receiver of the input as the value of the schema if one is not provided sentence is complicated, but the concept is easy.

chatGPT gave me this as better option and I love it: It acts as a standard value to be assumed in case no specific value is provided. or Use it to specify that property has a predefined value if no other value is present

no receiver, subscriber, producer, or whatever

thoughts?

Copy link
Member

Choose a reason for hiding this comment

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

Love this one:

Use it to specify that a property has a predefined value if no other value is present

@derberg derberg requested a review from fmvilas May 11, 2023 11:52
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

dalelane
dalelane previously approved these changes May 14, 2023
Copy link
Collaborator

@dalelane dalelane left a comment

Choose a reason for hiding this comment

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

not as bad as the can of worms I feared when I saw the title about "publisher/subscriber" "send/receive" ;-)

@derberg
Copy link
Member Author

derberg commented Jun 19, 2023

@smoya @fmvilas @char0n all good from your side?

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@derberg
Copy link
Member Author

derberg commented Jun 26, 2023

one small sentence change

@dalelane wanna have a look?

@fmvilas 🙏🏼

Copy link
Member

@fmvilas fmvilas left a comment

Choose a reason for hiding this comment

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

👍

Copy link
Member

@smoya smoya left a comment

Choose a reason for hiding this comment

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

LGTM! 🚀🌔 Thanks for the changes @derberg 🙌

As a side note, I had to think about why we moved from Subscribe/Publish to Send/Receive.

Even though I actively participated in the original discussion and I completely agreed with that.

That means It could make sense to add a line in the docs clarifying why we do not use the words Subscribe/Publish anymore. WDYT? Obviously, all in a separate issue and PR.

@derberg
Copy link
Member Author

derberg commented Jun 29, 2023

@smoya good point, issue created asyncapi/website#1873

/rtm

@asyncapi-bot asyncapi-bot merged commit d89a1a6 into asyncapi:next-major-spec Jun 29, 2023
@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 3.0.0-next-major-spec.13 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants