2017 © Pedro Peláez
 

magento-module elastic-search

image

kalenjordan/elastic-search

  • Friday, October 18, 2013
  • by kalenjordan
  • Repository
  • 10 Watchers
  • 24 Stars
  • 51 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 4 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Elastic Search for Magento

Speed up that slow global admin search., (*1)

Before

Before, (*2)

After

After, (*3)

Installation via composer

1. Install elasticsearch

Pretty easy to install, if you already have java installed, as I did in my local., (*4)

wget https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-0.90.5.zip
unzip elasticsearch-0.90.5.zip
elasticsearch-0.90.5/bin/elasticsearch -f

Boom - it's installed and running now., (*5)

2. Install elastic search module

"require": {
    "kalenjordan/elastic-search": "dev-master",
    "ruflin/elastica": "dev-master"
}

3. Speed up the onKeyPress timeout

This will speed up the rate at which the autocomplete fires., (*6)

# app/design/adminhtml/default/default/template/page/header.phtml

new Ajax.Autocompleter(
    'global_search',
    'global_search_autocomplete',
    '<?php echo $this->getUrl('adminhtml/index/globalSearch') ?>',
    {
        paramName:"query",
        minChars:2,
        indicator:"global_search_indicator",
        updateElement:getSelectionId,
        evalJSON:'force',
        **frequency: 0.01**
    }
);

To Do

This is just in early development., (*7)

  • Might need a more bulletproof authentication scheme, but bootstrapping Magento isn't an option for performance reasons., (*8)

  • Some people will probably want support for URL keys in the autocomplete results, (*9)

  • Use bulk API to insert documents when doing reindexAll(), (*10)

The Versions