Skip to content

Commit

Permalink
README: add batch period in Example
Browse files Browse the repository at this point in the history
  • Loading branch information
ebonnal committed Nov 19, 2023
1 parent 181104e commit e9fce51
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,10 @@ christmas_comments_integration_pipe: Pipe[str] = (
.log(what="christmas comments")

# POST these comments in some endpoint using 2 threads
# by batch of 100 and at a maximum rate of 5 batches per second.
# by batch of maximum size 100 and with at least 1 batch every 10 seconds
# and at a maximum rate of 5 batches per second.
# Also raise if the status code is not 200.
.batch(100)
.batch(size=100, period=10)
.slow(freq=5)
.map(
lambda comment: requests.post(
Expand Down

0 comments on commit e9fce51

Please sign in to comment.