J'ai simplement ajouter ceci dans #app/config/config.yml :
foq_elastica:
clients:
default: { host: localhost, port: 9200 }
indexes:
website:
client: default
types:
user:
mappings:
username: { boost: 5 }
firstName: { boost: 3 }
lastName: { boost: 3 }
aboutMe: ~
post: {_parent: { type: "post", identifier: "id" } }
date: { boost: 5 }
content: ~
comments:
type: "nested"
properties:
date: { boost: 5 }
content: ~
persistence:
driver: orm
model: Application\UserBundle\Entity\User
identifier: id
provider:
query_builder_method: createIsActiveQueryBuilder
batch_size: 100
Partager