You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* added produce without creating producer
* fix destroy functions + add is_connected func
* internal station name + producer name to lower
* fix is connected
* rearrange args places in call for produce
* fix produce args + add is_connected to readme
message='bytearray/protobuf class/dict/string/graphql.language.ast.DocumentNode', # bytearray / protobuf class (schema validated station - protobuf) or bytearray/dict (schema validated station - json schema) or string/bytearray/graphql.language.ast.DocumentNode (schema validated station - graphql schema)
206
+
generate_random_suffix=False, #defaults to false
207
+
ack_wait_sec=15, # defaults to 15
208
+
headers=headers, # default to {}
209
+
async_produce=False, #defaults to false
210
+
msg_id="123"
211
+
)
212
+
```
213
+
200
214
215
+
Creating a producer first
201
216
```python
202
217
await prod.produce(
203
218
message='bytearray/protobuf class/dict/string/graphql.language.ast.DocumentNode', # bytearray / protobuf class (schema validated station - protobuf) or bytearray/dict (schema validated station - json schema) or string/bytearray/graphql.language.ast.DocumentNode (schema validated station - graphql schema)
"""Produces a message into a station without the need to create a producer.
477
493
Args:
478
-
key (string): header key.
479
-
value (string): header value.
494
+
station_name (str): station name to produce messages into.
495
+
producer_name (str): name for the producer.
496
+
message (bytearray/dict): message to send into the station - bytearray/protobuf class (schema validated station - protobuf) or bytearray/dict (schema validated station - json schema) or string/bytearray/graphql.language.ast.DocumentNode (schema validated station - graphql schema)
497
+
generate_random_suffix (bool): false by default, if true concatenate a random suffix to producer's name
498
+
ack_wait_sec (int, optional): max time in seconds to wait for an ack from memphis. Defaults to 15.
499
+
headers (dict, optional): Message headers, defaults to {}.
500
+
async_produce (boolean, optional): produce operation won't wait for broker acknowledgement
501
+
msg_id (string, optional): Attach msg-id header to the message in order to achieve idempotency
0 commit comments