LARAVEL + ELASTICSEARCH

Igor Rjabinin

Slovak National Gallery

lab.SNG

Elasticsearch is a real-time distributed search and analytics engine. It allows you to explore your data at a speed
and at a scale never before possible. It is used for full-text search, structured search, analytics, and all three in combination.

–Elasticsearch: The Definitive Guide

DISTRIBUTED

horizontálne škálovatelný

APACHE LUCENE

umožňuje vysoko výkonné pokročilé vyhľadávanie

RESTful API

integrovatelné s hocičím

vs

elastic je vyhľadávací engine

fulltext vyhľadávanie +
filtrovanie na binárnej úrovni

SQL je relačná databáza

filtrovanie na binárnej úrovni

vs

index → type → document

database → table → row 

prečo?

fulltext search

faceted search (aggregations)

autocomplete (n-gram)

more-like-this

querying data (+ e.g. random)

(real world usage) 

prečo?

on-line katalóg výtvarných diel zo zbierok slovenských a českých galérií umenia

Launch: 2015 (64.000 artworks)

Elastic Search, Laravel, Bootstrap, IIP + OpenSeaDragon ...

Install

Integrate

custom repository

https://github.com/SlovakNationalGallery/webumenia.sk/tree/develop/app/Elasticsearch/Repositories

 

generate index + mapping

https://github.com/SlovakNationalGallery/webumenia.sk/blob/develop/app/Console/Commands/SetupElasticsearch.php

php artisan es:setup

 

observers

https://github.com/SlovakNationalGallery/webumenia.sk/blob/develop/app/Observers/ItemObserver.php

 

Alternatives

elasticquent/elasticquent

laravel scout

TODO

- fallback to sql
- deploy scenario (links)

Get in touch!

Made with Slides.com