protected final function validateModelEndpoint()
{
if (!$this->getIndex()) {
throw new InvalidModelEndpointException(sprintf('Please specify the index for your Elasticsearch model %s', static::class));
}
if (!$this->getType()) {
throw new InvalidModelEndpointException(sprintf('Please specify the type for your Elasticsearch model %s', static::class));
}
}