jolicode / elastically

🔍 JoliCode's Elastica wrapper to bootstrap Elasticsearch PHP integrations
248 stars 37 forks source link

Index is already created, something is wrong #90

Closed cyphos1973 closed 2 years ago

cyphos1973 commented 2 years ago

Hi This is the error Index "post_2021-10-13-084712" is already created, something is wrong

Bug?

lyrixx commented 2 years ago

Hi,

Could you provide a reproducer, or a stack strace? Thanks

cyphos1973 commented 2 years ago

bin/console app:elasticsearch:create-index -vv

09:29:06 INFO      [http_client] Request: "HEAD http://localhost/:9200/post_2021-10-13-092906"
09:29:06 INFO      [http_client] Response: "200 http://localhost/:9200/post_2021-10-13-092906"
In IndexBuilder.php line 44:

  [Elastica\Exception\RuntimeException]                                   
  Index "post_2021-10-13-092906" is already created, something is wrong.  

Exception trace:
  at /shared/httpd/DOCKER-SYMFONY-ELASTICSEARCH-DEMO/app/vendor/jolicode/elastically/src/IndexBuilder.php:44
 JoliCode\Elastically\IndexBuilder->createIndex() at /shared/httpd/DOCKER-SYMFONY-ELASTICSEARCH-DEMO/app/src/Elasticsearch/Command/CreateIndexCommand.php:36
 App\Elasticsearch\Command\CreateIndexCommand->execute() at /shared/httpd/DOCKER-SYMFONY-ELASTICSEARCH-DEMO/app/vendor/symfony/console/Command/Command.php:299
 Symfony\Component\Console\Command\Command->run() at /shared/httpd/DOCKER-SYMFONY-ELASTICSEARCH-DEMO/app/vendor/symfony/console/Application.php:996
 Symfony\Component\Console\Application->doRunCommand() at /shared/httpd/DOCKER-SYMFONY-ELASTICSEARCH-DEMO/app/vendor/symfony/framework-bundle/Console/Application.php:96
 Symfony\Bundle\FrameworkBundle\Console\Application->doRunCommand() at /shared/httpd/DOCKER-SYMFONY-ELASTICSEARCH-DEMO/app/vendor/symfony/console/Application.php:295
 Symfony\Component\Console\Application->doRun() at /shared/httpd/DOCKER-SYMFONY-ELASTICSEARCH-DEMO/app/vendor/symfony/framework-bundle/Console/Application.php:82
 Symfony\Bundle\FrameworkBundle\Console\Application->doRun() at /shared/httpd/DOCKER-SYMFONY-ELASTICSEARCH-DEMO/app/vendor/symfony/console/Application.php:167
 Symfony\Component\Console\Application->run() at /shared/httpd/DOCKER-SYMFONY-ELASTICSEARCH-DEMO/app/bin/console:43

app:elasticsearch:create-index
cyphos1973 commented 2 years ago

I don't know i the data are good

ELASTICSEARCH_PORT=9200

ELASTICSEARCH_HOST=localhost/

ELASTICSEARCH_SCHEME=
damienalexandre commented 2 years ago

Hi there :wave: Did you found a solution to this issue?

Could you show us more code? As it's not reproducible on our side.

damienalexandre commented 2 years ago

I'm closing this issue as we didn't got any feedback to our questions. Feel free to reopen if it does happen again!