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

Feat: extend response api #1607

Merged
merged 17 commits into from
Jul 31, 2024
Merged

Conversation

Flosckow
Copy link
Contributor

@Flosckow Flosckow commented Jul 20, 2024

Description

Please include a summary of the change and specify which issue is being addressed. Additionally, provide relevant motivation and context.

Fixes #1587

Type of change

Please delete options that are not relevant.

  • Documentation (typos, code examples, or any documentation updates)
  • Bug fix (a non-breaking change that resolves an issue)
  • New feature (a non-breaking change that adds functionality)
  • Breaking change (a fix or feature that would disrupt existing functionality)
  • This change requires a documentation update

Checklist

  • My code adheres to the style guidelines of this project (scripts/lint.sh shows no errors)
  • I have conducted a self-review of my own code
  • I have made the necessary changes to the documentation
  • My changes do not generate any new warnings
  • I have added tests to validate the effectiveness of my fix or the functionality of my new feature
  • Both new and existing unit tests pass successfully on my local environment by running scripts/test-cov.sh
  • I have ensured that static analysis tests are passing by running scripts/static-analysis.sh
  • I have included code examples to illustrate the modifications

@Lancetnik Lancetnik added enhancement New feature or request Core Issues related to core FastStream functionality and affects to all brokers labels Jul 20, 2024
@Flosckow Flosckow marked this pull request as ready for review July 21, 2024 07:00
faststream/kafka/response.py Outdated Show resolved Hide resolved
faststream/nats/response.py Outdated Show resolved Hide resolved
faststream/rabbit/response.py Outdated Show resolved Hide resolved
faststream/redis/response.py Outdated Show resolved Hide resolved
faststream/confluent/response.py Outdated Show resolved Hide resolved
@Lancetnik
Copy link
Member

@Flosckow don't forget to initiate classes. Now you have only __init__(): ..., but it should use super and setup custom fields as well

@Lancetnik
Copy link
Member

And finally, don't forget to override Response.as_publish_kwargs for each class

@Flosckow
Copy link
Contributor Author

Can we use AioPikaSendableMessage(need add to base response class inside union), or more correctly strategy use SendableMessage inside rmq response?

Lancetnik
Lancetnik previously approved these changes Jul 30, 2024
@Lancetnik Lancetnik enabled auto-merge July 30, 2024 20:42
Lancetnik
Lancetnik previously approved these changes Jul 30, 2024
Lancetnik
Lancetnik previously approved these changes Jul 30, 2024
@Lancetnik Lancetnik added this pull request to the merge queue Jul 30, 2024
github-merge-queue bot pushed a commit that referenced this pull request Jul 30, 2024
* Feat; init

* Feat: add redis response and fix nats, redis response

* Fix: unificate code

* Fix: remove some args

* Fix: rewrite init method, override as_publish_kwargs

* chore: add DeprecationWarning for ReplyConfig

* tests: check RMQ DeprecationWarning

* lint: fix mypy

* Feat: stage 1 add response to all brokers, need specify to "Broker"Response class

* fix: correct Response subclass usage

* docs: generate API

* fix: wait for connect in Redis ping

* docs: generate API

---------

Co-authored-by: Daniil Dumchenko <[email protected]>
Co-authored-by: Nikita Pastukhov <[email protected]>
@Lancetnik Lancetnik removed this pull request from the merge queue due to a manual request Jul 30, 2024
@Lancetnik Lancetnik enabled auto-merge July 30, 2024 21:06
auto-merge was automatically disabled July 31, 2024 18:01

Head branch was pushed to by a user without write access

@Lancetnik Lancetnik enabled auto-merge July 31, 2024 20:01
@Lancetnik Lancetnik added this pull request to the merge queue Jul 31, 2024
Merged via the queue into airtai:main with commit 36e5a17 Jul 31, 2024
29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Core Issues related to core FastStream functionality and affects to all brokers enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feature: extend Response API
2 participants