Implemented batching