O'Reilly logo

Play Framework Cookbook - Second Edition by Giancarlo Inductivo, Alexander Reelsen

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Integrating a Play application with ElasticSearch

In this recipe, we will create a very common web application functionality to create, index, and search, in our case, products. We will use ElasticSearch as our search service. We will use Docker to create our local ElasticSearch container and to run all search operations.

A prerequisite for this recipe is having access to an ElasticSearch instance, either local or remote, in our recipe, as well as having Docker installed in the local development machine:

    $ docker -v
    Docker version 1.3.3, build d344625

We used Docker to deploy our local ElasticSearch instance using the command:


    docker run -d -p 9200:9200 -p 9300:9300 dockerfile/elasticsearch

The preceding command instructs docker to run the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required