simple batch implementation