protected function generateVersionTable($name, Annotation $annotation, EntityDefinition &$entityMetadata)
    {
        $annotation = clone $annotation;
        $annotation->name ='ref_' . $annotation->name;
        $annotation->autoIncrement = false;

        // copy primary key to version table
        $entityMetadata['versionTable']['columns'][] = $this->generateColumn($name, $annotation);
    }