Questions tagged [foselasticabundle]

FOSElasticaBundle - Elasticsearch PHP integration for your Symfony2 project using Elastica.

Elasticsearch client is comparable to a database connection. Most of the time, you will need only one.

Elastica can handle objects instead of data arrays if a serializer callable is configured

Elasticsearch index is comparable to Doctrine entity manager. Most of the time, you will need only one.

Elasticsearch type is comparable to Doctrine entity repository.

If you are using the JMSSerializerBundle for serializing objects passed to elastica you can define serializer groups per type.

241 questions
1
vote
0 answers

How to add some filter based on "custom score" using FOSElasticaBundle?

I am doing a service to apply some custom filters to ebay results. For that I am using Symfony 4 and FOSElasticaBundle in the following way: fos_elastica.yaml: # Read the documentation:…
1
vote
1 answer

FOSElasticaBundle: Root mapping definition has unsupported parameters:

I get the following error when populating elastic search: Root mapping definition has unsupported parameters: [product : {dynamic_date_formats=[], _meta={model=App\Entity\Product}, properties={name={type=text}, description={type=text}}}] [reason:…
Roel Veldhuizen
  • 4,613
  • 8
  • 44
  • 78
1
vote
0 answers

FOSElastica don't recognize my ElasticSearch username and password

I've setup users and roles on my ElasticSearch and while it works like a charm with curl it doesn't seem to work through FOSElastica. I'm using it to populate my ElasticSearch indices. I've tried to setup username and password through fos_elastica…
Malcom HAMELIN
  • 305
  • 1
  • 3
  • 11
1
vote
0 answers

How to serialize an object "datetime" property into a "date" elasticsearch type, not "text"

I am creating a website using Symfony 4. Visitors will need to search through thousands of articles ordered by "dynamic_date". I use Elasticsearch 6.7, FOSElasticaBundle and JMS Serializer to index "Article" objects. Serialization seems to somehow…
1
vote
0 answers

Error in bulk request : index : ... caused failed to parse

I'm having trouble with the FOSElastica bundle config. I'm trying to use the Symfony serializer to populate Elastic search with FOSElastica, and it works well for simple objects which don't need to have groups of attributes, but when I try to…
Malcom HAMELIN
  • 305
  • 1
  • 3
  • 11
1
vote
1 answer

Symfony Elasticsearch configuration file is not working with 1 index for multiple types

I have the following configuration in my config.yml fos_elastica: clients: default: { host: localhost, port: 9200 } indexes: app: finder: ~ types: product: …
Noob
  • 732
  • 8
  • 30
1
vote
0 answers

Keeping ElasticSearch in sync with updates through Doctrine

We're using FOSElasticaBundle for integration between Doctrine and ElasticSearch. We have a lot of fields indexed in ES. When updating one of the mapped entities directly FOSElasticaBundle makes sure the changes are reflected in ES. But for cases…
Waaghals
  • 2,029
  • 16
  • 30
1
vote
1 answer

FosElasticaBundle populate with serializer don't index all fields

I'm working with FOS Elastica bundle and trying to index some datas inside Elasticsearch. I followed the doc so I wrote this conf fos_elastica: clients: default: { host: '%env(ELASTICSEARCH_HOST)%', port: '%env(ELASTICSEARCH_PORT)%' } …
Jérôme
  • 1,966
  • 4
  • 24
  • 48
1
vote
1 answer

FOSElasticaBundle: ManyToMany relationship

I'm trying to use FOSElasticaBundle on my symfony 4 project and I have some problems. I have an entity, "Users", with the next annotation in the property "segments": * @var Collection $segments * @ORM\ManyToMany(targetEntity="App\Entity\Segment",…
Juan Valls
  • 11
  • 1
1
vote
2 answers

Get Elasticsearch Score in Symfony

Elasticsearch provides a score field if you do a get request via cURL. { "_index": "twitter", "_type": "tweet", "_id": "123", "_score": 4.2, "firstName": "Max" "lastName": "Mustermann" } Is there a way to get this score inside symfony.…
Rob Bauer
  • 737
  • 2
  • 14
  • 24
1
vote
1 answer

Elastica, KNP Paginator and Resultset > 10000

Pagination works fine even for large Results. It even shows that there are 25k Results for the Query. Pagination works fine for the first 10000 entries. Though, if i want to display entry 10000 - 10010 (for example) everything breaks with this…
user1512255
1
vote
0 answers

How to integrate elasticsearch with sonata-admin bundle

Hi everyone I'm using SonataAdminBundle and I want to integrate Elasticsearch in order to improve performance. I have setup the elasticsearch and I have configured the fos_elastica. I have one Entity for testing, and now I want to use elasticsearch…
1
vote
0 answers

How create parent mapping in FOS_elasticBundle with Elasticsearch 6?

Elasticsearch 6 doesn't support parent mapping anymore. Do I have to use "type:join" now? How can I map entity parent in FOS_elasticBundle with Elasticsearch 6?
1
vote
1 answer

Automatic service loading inside Controller using FOSElasticaBundle and Symfony 3.3

Here's my autowiring configuration in app/config/services.yml : My controller : Problem is when I use the new feature in Symfony 3.3 to automatically load service "fos_elastica.index.app.cv" in my bundle : , the container can no longer find the…
space110
  • 109
  • 1
  • 1
  • 10
1
vote
1 answer

Define elasticsearch field type using FOSelastica TransformEvent

I'm working on a existing Symfony project that uses FOS Elastica Bundle, and especially the TransformEvent. elastica.yml types: object: mappings: ~ persistence: identifier: id …
G.P
  • 39
  • 5