private function getCollection() {
        if ($this->collection === null) {
            try {
                $this->collection = $this->getMongoClient()->selectCollection(
                    $this->params['databaseName'],
                    'imagevariation'
                );
            } catch (MongoException $e) {
                throw new DatabaseException('Could not select collection', 500, $e);
            }
        }

        return $this->collection;
    }