private function getMetaDataValue($id, $key) {
        $data = $this->getMetaData($id);
        if (isset($data[$key])) {
            return $data[$key];
        }
        throw new \Exception($key . ' is not defined in medatada');
    }