Skip to content
This repository has been archived by the owner on Nov 14, 2019. It is now read-only.

Extend the instance schema

Lida Li edited this page Jul 9, 2017 · 2 revisions

ElasticSearch stores each instance as a document. The schema of the document can be extended by creating your own instance class inheriting from EsInstance and factory class inheriting from AbstractEsInstanceFactory . The factory class needs to implement the following method that returns your own EsInstance subclass

 public abstract EsInstance createFromEC2(Instance awsInstance) throws Exception;

In the properties file of the worker, set the factory class to be your own instance factory

instance_factory = com.pinterest.soundwave.aws.BasicEsInstanceFactory
Clone this wiki locally