Skip to content

Commit 3c261d3

Browse files
Update documentation (#862)
Co-authored-by: daniil-quix <[email protected]>
1 parent 3a7968a commit 3c261d3

File tree

5 files changed

+163
-174
lines changed

5 files changed

+163
-174
lines changed

docs/api-reference/application.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,8 @@ Linked Environment Variable: `Quix__State__Dir`.
131131
Default - `"state"`.
132132
- `rocksdb_options`: RocksDB options.
133133
If `None`, the default options will be used.
134-
- `consumer_poll_timeout`: timeout for `RowConsumer.poll()`. Default - `1.0`s
135-
- `producer_poll_timeout`: timeout for `RowProducer.poll()`. Default - `0`s.
134+
- `consumer_poll_timeout`: timeout for `InternalConsumer.poll()`. Default - `1.0`s
135+
- `producer_poll_timeout`: timeout for `InternalProducer.poll()`. Default - `0`s.
136136
- `on_message_processed`: a callback triggered when message is successfully
137137
processed.
138138
- `loglevel`: a log level for "quixstreams" logger.
@@ -160,11 +160,11 @@ To handle errors, `Application` accepts callbacks triggered when
160160
exceptions occur on different stages of stream processing. If the callback
161161
returns `True`, the exception will be ignored. Otherwise, the exception
162162
will be propagated and the processing will eventually stop.
163-
- `on_consumer_error`: triggered when internal `RowConsumer` fails
163+
- `on_consumer_error`: triggered when internal `InternalConsumer` fails
164164
to poll Kafka or cannot deserialize a message.
165165
- `on_processing_error`: triggered when exception is raised within
166166
`StreamingDataFrame.process()`.
167-
- `on_producer_error`: triggered when `RowProducer` fails to serialize
167+
- `on_producer_error`: triggered when `InternalProducer` fails to serialize
168168
or to produce a message to Kafka.
169169
<br><br>***Quix Cloud Parameters***<br>
170170
- `quix_config_builder`: instance of `QuixKafkaConfigsBuilder` to be used

docs/api-reference/kafka.md

+7-19
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
class Producer()
1111
```
1212

13-
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L45)
13+
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L65)
1414

1515
<a id="quixstreams.kafka.producer.Producer.__init__"></a>
1616

@@ -23,10 +23,11 @@ def __init__(broker_address: Union[str, ConnectionConfig],
2323
logger: logging.Logger = logger,
2424
error_callback: Callable[[KafkaError], None] = _default_error_cb,
2525
extra_config: Optional[dict] = None,
26-
flush_timeout: Optional[float] = None)
26+
flush_timeout: Optional[float] = None,
27+
transactional: bool = False)
2728
```
2829

29-
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L46)
30+
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L66)
3031

3132
A wrapper around `confluent_kafka.Producer`.
3233

@@ -66,7 +67,7 @@ def produce(topic: str,
6667
on_delivery: Optional[DeliveryCallback] = None)
6768
```
6869

69-
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L84)
70+
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L117)
7071

7172
Produce a message to a topic.
7273

@@ -101,7 +102,7 @@ for the produced message.
101102
def poll(timeout: float = 0)
102103
```
103104

104-
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L145)
105+
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L178)
105106

106107
Polls the producer for events and calls `on_delivery` callbacks.
107108

@@ -122,7 +123,7 @@ Polls the producer for events and calls `on_delivery` callbacks.
122123
def flush(timeout: Optional[float] = None) -> int
123124
```
124125

125-
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L153)
126+
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L213)
126127

127128
Wait for all messages in the Producer queue to be delivered.
128129

@@ -139,19 +140,6 @@ None use producer default or -1 is infinite. Default: None
139140

140141
number of messages remaining to flush
141142

142-
<a id="quixstreams.kafka.producer.TransactionalProducer"></a>
143-
144-
### TransactionalProducer
145-
146-
```python
147-
class TransactionalProducer(Producer)
148-
```
149-
150-
[[VIEW SOURCE]](https://github.com/quixio/quix-streams/blob/main/quixstreams/kafka/producer.py#L184)
151-
152-
A separate producer class used only internally for transactions
153-
(transactions are only needed when using a consumer).
154-
155143
<a id="quixstreams.kafka.consumer"></a>
156144

157145
## quixstreams.kafka.consumer

0 commit comments

Comments
 (0)