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
When you use batch tranformer option in your pipeline configuration, you have an error on the batch size after the first occurence.
For exemple , with the batch size to 100 :
-
batch:
merge:
size: 100
Your first batch will contain 100 items, but the other batches will contain 101 items.
The generated code :
public function transform() : \Generator
{
$this->storage = [];
$line = yield;
$count = 1;
while (true) {
if ($count++ >= 100) {
$count = 0;
$this->storage[] = $line;
$line = (yield new \Kiboko\Component\Bucket\AcceptanceResultBucket($this->storage));
$this->storage = [];
} else {
$this->storage[] = $line;
$line = (yield new \Kiboko\Component\Bucket\EmptyResultBucket());
}
}
}
Geoffrey
The text was updated successfully, but these errors were encountered:
Hello,
When you use batch tranformer option in your pipeline configuration, you have an error on the batch size after the first occurence.
For exemple , with the batch size to 100 :
Your first batch will contain 100 items, but the other batches will contain 101 items.
The generated code :
Geoffrey
The text was updated successfully, but these errors were encountered: