/**
  * @param $document
  */
 public function flush($document = null)
 {
     $this->uow->commit($document);
 }