Skip to content

fix: rebuild index when clear storage#837

Merged
JohannesMessner merged 8 commits into
mainfrom
fix-clear-storage
Nov 25, 2022
Merged

fix: rebuild index when clear storage#837
JohannesMessner merged 8 commits into
mainfrom
fix-clear-storage

Conversation

@AnneYang720

@AnneYang720 AnneYang720 commented Nov 23, 2022

Copy link
Copy Markdown
Contributor

Signed-off-by: AnneY evangeline-lun@foxmail.com

Goals:

This PR is related to issue #829 and will rebuild index for Redis and ElasticSearch when _clear_storage is called.

  • change for Redis
  • change for ElasticSearch
  • add related test

Signed-off-by: AnneY <evangeline-lun@foxmail.com>
Signed-off-by: AnneY <evangeline-lun@foxmail.com>
Signed-off-by: AnneY <evangeline-lun@foxmail.com>
@codecov-commenter

codecov-commenter commented Nov 23, 2022

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 94.11765% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 83.40%. Comparing base (7ddbb87) to head (df982f4).
⚠️ Report is 620 commits behind head on main.

Files with missing lines Patch % Lines
docarray/array/storage/redis/backend.py 87.50% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main     #837       +/-   ##
===========================================
+ Coverage   59.97%   83.40%   +23.43%     
===========================================
  Files         138      138               
  Lines        7040     7046        +6     
===========================================
+ Hits         4222     5877     +1655     
+ Misses       2818     1169     -1649     
Flag Coverage Δ
docarray 83.40% <94.11%> (+23.43%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Signed-off-by: AnneY <evangeline-lun@foxmail.com>
@AnneYang720 AnneYang720 marked this pull request as ready for review November 24, 2022 08:15
Comment thread docarray/array/storage/elastic/backend.py
Comment thread docarray/array/storage/redis/backend.py Outdated
Comment thread docarray/array/storage/redis/backend.py
Signed-off-by: AnneY <evangeline-lun@foxmail.com>
@github-actions github-actions Bot added size/s and removed size/m labels Nov 25, 2022
@AnneYang720 AnneYang720 enabled auto-merge (squash) November 25, 2022 13:47
@AnneYang720 AnneYang720 disabled auto-merge November 25, 2022 13:47
@JohannesMessner JohannesMessner merged commit eeaba13 into main Nov 25, 2022
@JohannesMessner JohannesMessner deleted the fix-clear-storage branch November 25, 2022 14:53
guenthermi pushed a commit to guenthermi/docarray that referenced this pull request Nov 28, 2022
* fix: rebuild index of redis when clear storage

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* refactor: change build index funtion name

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* fix: rebuild index of elastic when clear storage

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* test: add tests for getset subindex in store

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* fix: fix elastic __setstate__ client

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* refactor: keep _build_client

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

Signed-off-by: AnneY <evangeline-lun@foxmail.com>
guenthermi pushed a commit to guenthermi/docarray that referenced this pull request Nov 28, 2022
* fix: rebuild index of redis when clear storage

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* refactor: change build index funtion name

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* fix: rebuild index of elastic when clear storage

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* test: add tests for getset subindex in store

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* fix: fix elastic __setstate__ client

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

* refactor: keep _build_client

Signed-off-by: AnneY <evangeline-lun@foxmail.com>

Signed-off-by: AnneY <evangeline-lun@foxmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants