Skip to content

๐Ÿ‘Š 0-downtime elasticsearch reindex functional utility. Automatically detect ES mapping modification and reindex modified records. Use namespaces in your indexes. Create aggregated filtering for shops.

License

Notifications You must be signed in to change notification settings

Mati365/searchpunch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

39 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

searchpunch ๐Ÿ‘Š

License: MIT GitHub code size in bytes GitHub issues PRs Welcome

Banner

Tired of writing elasticsearch reindex scripts? Are you constantly encountering data synchronization problems between the database and elasticsearch? Are you crying about the lack of namespaces in the organization of indexes in your cluster? Nothing lost! Here is searchpunch and punch this shit out!

What does it offer? โญ

  1. 0-downtime reindex
  2. automatic removing unused indices
  3. synchronization of data between any database using async generators
  4. automatic detection of index settings / mappings modification and reindex modified indices
  5. bulk reindex of records
  6. group indices into namespaces
  7. fully typed error handling using Either monad
  8. failure tolerance, automatic rollback if index does not match healthy criteria
  9. CLI tools

Work in Progress ๐Ÿšง

  • ๐Ÿšง Monadic elasticsearch layer
  • ๐Ÿšง Synchronization of Elasticsearch indices
  • ๐Ÿšง CLI utilities

Installation ๐Ÿš€

yarn add @searchpunch/reindex

How index synchronization works? ๐Ÿ› ๏ธ

  1. Load current mapping schema into memory
  2. Check if specified index exists in ElasticSearch
    1. If not:
      1. Create new index
      2. Perform reindex of all records in storage
    2. If exists compare mappings with ElasticSearch index stored in meta fields as hash
      1. If equal skip reindex
      2. If differs perform full reindex

Where it can be used? ๐Ÿ—๏ธ

  1. Building ecommerce shops with aggregated products
  2. Searching logs in dashboard
  3. Autocomplete select inputs
  4. ... and in many many other places

License

MIT License

Copyright (c) 2023 Mateusz Bagiล„ski

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

About

๐Ÿ‘Š 0-downtime elasticsearch reindex functional utility. Automatically detect ES mapping modification and reindex modified records. Use namespaces in your indexes. Create aggregated filtering for shops.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published