-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
59b4176
commit 19c5599
Showing
481 changed files
with
134,152 additions
and
60,688 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,4 @@ | |
from .streaming_client import StreamingClient | ||
|
||
|
||
__version__ = "1.2.5" | ||
__version__ = "1.3.2" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import dataclasses | ||
|
||
from . import enums | ||
from .abstract import _ApiClassFactory | ||
from .dataset import DatasetConfig | ||
|
||
|
||
@dataclasses.dataclass | ||
class StreamingConnectorDatasetConfig(DatasetConfig): | ||
""" | ||
An abstract class for dataset configs specific to streaming connectors. | ||
Args: | ||
streaming_connector_type (StreamingConnectorType): The type of streaming connector | ||
""" | ||
streaming_connector_type: enums.StreamingConnectorType = dataclasses.field(default=None, repr=False, init=False) | ||
|
||
@classmethod | ||
def _get_builder(cls): | ||
return _StreamingConnectorDatasetConfigFactory | ||
|
||
|
||
@dataclasses.dataclass | ||
class KafkaDatasetConfig(StreamingConnectorDatasetConfig): | ||
""" | ||
Dataset config for Kafka Streaming Connector | ||
Args: | ||
topic (str): The kafka topic to consume | ||
""" | ||
topic: str | ||
|
||
def __post_init__(self): | ||
self.streaming_connector_type = enums.StreamingConnectorType.KAFKA | ||
|
||
|
||
@dataclasses.dataclass | ||
class _StreamingConnectorDatasetConfigFactory(_ApiClassFactory): | ||
config_abstract_class = StreamingConnectorDatasetConfig | ||
config_class_key = 'streaming_connector_type' | ||
config_class_map = { | ||
enums.StreamingConnectorType.KAFKA: KafkaDatasetConfig, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.