Build for Elasticsearch-1.4.1

Compatibility fixes and build for Elasticsearch-1.4.1
**Note:**  ReadonlyRestAction interface is changed in ES-1.4 so might be `<version>1.3</version>` should be changed to 1.4 to distinguish interfaces.