Releases: airtai/faststream
v0.5.34
What's Changed
- fix: when / present in virtual host name and passing as uri by @pepellsd in #1979
- fix (#2013): allow to create publisher in already connected broker by @Lancetnik in #2024
- feat: add BatchBufferOverflowException by @spataphore1337 in #1990
- feat: add static instrumentation info by @draincoder in #1996
- docs: remove reference of "faststream.access" by @rishabhc32 in #1995
- docs: fixed typo in publishing/test.md by @AlexPetul in #2009
- docs: ability to declare queue/exchange binding by @MagicAbdel in #2011
- docs: fix spelling mistake of
/health
by @herotomg in #2023 - docs: update aio-pika external docs URL as it has been moved by @HybridBit in #1984
- refactor: add type annotations for RabbitQueue and enum for queue type by @pepellsd in #2002
New Contributors
- @HybridBit made their first contribution in #1984
- @rishabhc32 made their first contribution in #1995
- @AlexPetul made their first contribution in #2009
- @MagicAbdel made their first contribution in #2011
- @herotomg made their first contribution in #2023
Full Changelog: 0.5.33...0.5.34
v0.5.33
What's Changed
Just a Confluent & Kafka hotfix. Messages without body (with key only) parsing correctly now.
- fix: Confluent, read messages under lock by @Lancetnik in #1963
- fix #1967: correct empty kafka message body processing by @Lancetnik in #1968
Full Changelog: 0.5.32...0.5.33
v0.5.32
What's Changed
Thanks to @Flosckow one more time for a new release! Now you have an ability to consume Confluent messages (in autocommit mode) concurrently!
from faststream.confluent import KafkaBroker
broker = KafkaBroker()
@broker.subscriber("topic", max_workers=10)
async def handler():
"""Using `max_workers` option you can process up to 10 messages by one subscriber concurrently"""
Also, thanks to @Sehat1137 for his ASGI CLI support bugfixes
- fix #1959: propagate logger to Confluent by @Lancetnik in #1960
- Concurrent confluent kafka by @Flosckow in #1961
- fix: extend validation for --factory param by @Sehat1137 in #1964
- fix: support only uvicorn ASGI Runner by @Sehat1137 in #1965
Full Changelog: 0.5.31...0.5.32
v0.5.31
What's Changed
Well, you (community) made a new breathtaken release for us!
Thanks to all of this release contributors.
Special thanks to @Flosckow . He promotes a new perfect feature - concurrent Kafka subscriber (with autocommit mode)
from faststream.kafka import KafkaBroker
broker = KafkaBroker()
@broker.subscriber("topic", max_workers=10)
async def handler():
"""Using `max_workers` option you can process up to 10 messages by one subscriber concurrently"""
Also, thanks to @Sehat1137 with his ASGI CLI start fixins - now you can use FastStream CLI to scale your AsgiFastStream application by workers
faststream run main:asgi --workers 2
There are a lot of other incredible changes you made:
- feat: add NatsMessage ack_sync method #1906 by @wpn10 in #1909
- feat: support running ASGI app with Uvicorn using file descriptor by @minhyeoky in #1923
- feat: Add kafka concurrent subscriber by @Flosckow in #1912
- fix: bug when using one register for several middleware by @roma-frolov in #1921
- fix: change oauth type in asyncapi schema by @spataphore1337 in #1926
- fix: HandlerException ignored by @roma-frolov in #1928
- fix: Pomo/nats router by @Drakorgaur in #1932
- fix: RabbitBroker's ping is more objective by @roma-frolov in #1933
- fix: AsyncAPI 2.6.0 fix empty channels for KafkaSubscriber and ConfluentSubscriber if partitions provided by @KrySeyt in #1930
- fix: #1874 support workers for ASGI FastStream by @Sehat1137 in #1936
- fix: correct middlewares order by @sheldygg in #1935
- chore: run PR altering automated check in same CI job by @kumaranvpl in #1942
- chore: pin typer version by @Lancetnik in #1947
New Contributors
- @wpn10 made their first contribution in #1909
- @minhyeoky made their first contribution in #1923
Full Changelog: 0.5.30...0.5.31
v0.5.30
What's Changed
- Introducing FastStream Guru on Gurubase.io by @kursataktas in #1903
- docs: add gurubase badge to the doc by @Lancetnik in #1905
- fix: allow users to pass
nkeys_seed_str
as argument for NATS broker. by @Drakorgaur in #1908 - Add more warning's to nats subscription factory by @sheldygg in #1907
- fix: correct working with dependencies versions by @Lancetnik in #1918
New Contributors
- @kursataktas made their first contribution in #1903
- @Drakorgaur made their first contribution in #1908
Full Changelog: 0.5.29...0.5.30
v0.5.29
What's Changed
- feat: add explicit message source enum by @Lancetnik in #1866
- Change uv manual installation to setup-uv in CI by @pavelepanov in #1871
- refactor: make Task and Concurrent mixins broker-agnostic by @Lancetnik in #1873
- Add support for environment variables in faststream run command by @ulbwa in #1876
- fastapi example update by @xodiumx in #1875
- Do not import
fake_context
if not needed by @sobolevn in #1877 - build: add warning about manual lifespan_context by @vectorvp in #1878
- Add trending badge by @davorrunje in #1882
- feat: add class method to create a baggage instance from headers by @vectorvp in #1885
- ops: update docker compose commands to compose V2 in scripts by @vectorvp in #1889
New Contributors
- @pavelepanov made their first contribution in #1871
- @xodiumx made their first contribution in #1875
- @sobolevn made their first contribution in #1877
- @vectorvp made their first contribution in #1878
Full Changelog: 0.5.28...0.5.29
v0.5.28
What's Changed
There were a lot of time since 0.5.7 OpenTelemetry release and now we completed Observability features we planned! FastStream supports Prometheus metrics in a native way!
Special thanks to @roma-frolov and @draincoder (again) for it!
To collect Prometheus metrics for your FastStream application you just need to install special distribution
pip install faststream[prometheus]
And use PrometheusMiddleware. Also, it could be helpful to use our ASGI to serve metrics endpoint in the same app.
from prometheus_client import CollectorRegistry, make_asgi_app
from faststream.asgi import AsgiFastStream
from faststream.nats import NatsBroker
from faststream.nats.prometheus import NatsPrometheusMiddleware
registry = CollectorRegistry()
broker = NatsBroker(
middlewares=(
NatsPrometheusMiddleware(registry=registry),
)
)
app = AsgiFastStream(
broker,
asgi_routes=[
("/metrics", make_asgi_app(registry)),
]
)
Moreover, we have a ready-to-use Grafana dashboard you can just import and use!
To find more information about Prometheus support, just visit our documentation.
All changes
- docs: Correct minimum FastAPI version for lifespan handling by @tim-hutchinson in #1853
- add aiogram example by @IvanKirpichnikov in #1858
- Feature: Prometheus Middleware by @roma-frolov in #1791
- Add in-progress tutorial to how-to section by @sheldygg in #1859
- docs: Add info about Grafana dashboard by @draincoder in #1863
New Contributors
- @tim-hutchinson made their first contribution in #1853
Full Changelog: 0.5.27...0.5.28
v0.5.27
v0.5.26
What's Changed
This it the official Python 3.13 support! Now, FastStream works (and tested) at Python 3.8 - 3.13 versions!
Warning: Python3.8 is EOF since 3.13 release and we plan to drop it support in FastStream 0.6.0 version.
Also, current release has little bugfixes related to CLI and AsyncAPI schema.
- fix: asgi docs by @Sehat1137 in #1828
- docs: add link to RU TG community by @Lancetnik in #1831
- docs: add dynaconf NATS HowTo example by @sheldygg in #1832
- Fix AsyncAPI 2.6.0 operation label by @KrySeyt in #1835
- fix: correct CLI factory behavior by @Lancetnik in #1838
- Autocommit precommit changes by @kumaranvpl in #1840
- Add devcontainers supporting all the brokers by @kumaranvpl in #1839
- Replace async Event with bool by @Olegt0rr in #1846
- Add support for Python 3.13 by @davorrunje in #1845
Full Changelog: 0.5.25...0.5.26