A small (one might even say 'micro') service that hooks into rethinkdb-orm models and generates elasticsearch indices.
rubber-soul exposes a REST API to reindex/backfill specific models.
- Set the tables to be mirrored in ES through setting
RubberSoul::MANAGED_TABLESwith an array of
(T < RethinkORM::Base).class
- Configure Elastic client through
ES_PORTenv vars, or through switches on the command line
- Configure RethinkDB connection
Deletes indexes and recreates index mappings. Backfills the indices by default (toggle with backfill boolean).
Backfills all indexes with data from RethinkDB.
- Each RethinkDB table receives an ES index, with a mapping generated from the attributes of a RethinkORM model.
- RethinkORM attributes can accept a tag
es_typeto specify the correct field datatype for the index schema.
belongs_toassociations are modeled with ES
joindatatypes, associated documents are replicated in their parent's index. This is necessary for
RubberSoul::TableManager hooks into the changefeed of a table, resolves associations of the model and creates/updates documents in the appropriate ES indices.
ENV: a value of
productionlowers log verbosity
ES_HOST: elasticsearch host
ES_PORT: elasticsearch port
ES_TLS: use elasticsearch https, default is
ES_URI: elasticsearch uri, detects whether to use TLS off schema
RUBBER_SOUL_HOST: host to bind server to
RUBBER_SOUL_PORT: port for server to listen on
LOGSTASH_HOST: Logstash host for sending JSON formatted logs to
LOGSTASH_PORT: Logstash port that UDP input service is listening on
- rethinkdb 2.3.6
- elasticsearch 7.0.0
- Fork it
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Add some feature')
- Push to the branch (
git push origin my-new-feature)
- Create a new Pull Request
- Caspian Baska - creator and maintainer
- 8 days ago
- March 7, 2019
Sun, 01 Aug 2021 23:36:51 GMT