Skip to content

Commit

Permalink
remove unused group option for RQ
Browse files Browse the repository at this point in the history
  • Loading branch information
Yifan Zhang committed May 26, 2022
1 parent 8c4a951 commit 85b05bc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions src/pipeline/backends/rq.py
Expand Up @@ -18,7 +18,6 @@

class RQSourceSettings(SourceSettings):
redis: str = Field("redis://localhost:6379/0", title="redis url")
group: str = Field(..., title="redis consumer group name")
min_idle_time: int = Field(
3600000,
title="messages not acknowledged after min-idle-time will be reprocessed",
Expand All @@ -30,7 +29,7 @@ class RQSource(SourceTap):
>>> import logging
>>> from unittest.mock import patch
>>> settings = RQSourceSettings(group="reader")
>>> settings = RQSourceSettings()
>>> RQSource(settings=settings, logger=logging)
RQSource(host="redis://localhost:6379/0", topic="in-topic")
"""
Expand All @@ -45,7 +44,6 @@ def __init__(
) -> None:
super().__init__(settings, logger)
self.settings = settings
self.group = settings.group
self.topic = namespaced_topic(settings.topic, settings.namespace)
self.timeout = settings.timeout
self.redis = Redis.from_url(settings.redis)
Expand Down
2 changes: 1 addition & 1 deletion tests/test_backends.py
Expand Up @@ -117,7 +117,7 @@ def test_rq(self, mock_redis):
destination.close()

source_and_settings_classes = SourceTap.of(TapKind.RQ)
settings = source_and_settings_classes.settings_class(group="group")
settings = source_and_settings_classes.settings_class()
settings.parse_args("--in-topic test".split())
source = source_and_settings_classes.source_class(settings)
message_read = next(source.read())
Expand Down

0 comments on commit 85b05bc

Please sign in to comment.