Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mismatch of data in Elastic and DB on deletes #11429

Closed
pinakipb2 opened this issue Sep 19, 2024 · 3 comments
Closed

Mismatch of data in Elastic and DB on deletes #11429

pinakipb2 opened this issue Sep 19, 2024 · 3 comments
Assignees
Labels
bug Bug report

Comments

@pinakipb2
Copy link
Contributor

Describe the bug
When a field in an aspect is updated to empty, DB gets updated, but ES keeps the previous value.
For e.g. there is a field called description in an aspect for some entity. And currently it contains some value, which is present in DB as well as ES. When the description is updated to empty string. DB is updated to empty string and UI shows accordingly, but ES still holds the previous description value. Although the hasDescription field in ES gets updated to false.

To Reproduce
Steps to reproduce the behavior:

  1. Create any entity which has a valid description.
  2. Update / Ingest the description to be empty string.
  3. We can check the value in DB being empty string.
  4. But the value of description in ES is still the previous description.

Expected behavior
Value of the description should be empty as well, matching what is in DB.

Desktop (please complete the following information):

  • OS: MacOS 14.6.1
  • Browser Chrome
  • Datahub-Version - 0.13.3

Additional context
As per initial analysis, its found that the document is upserted. So, the previous and current document are merged, hence the description from the previous document gets retained in the process.

@pinakipb2 pinakipb2 added the bug Bug report label Sep 19, 2024
@pinakipb2 pinakipb2 changed the title Mismatch in data in Elastic and DB on deletes Mismatch iof data in Elastic and DB on deletes Sep 19, 2024
@pinakipb2 pinakipb2 changed the title Mismatch iof data in Elastic and DB on deletes Mismatch of data in Elastic and DB on deletes Sep 19, 2024
@jjoyce0510
Copy link
Collaborator

@david-leifker Do you mind taking a look?

@david-leifker
Copy link
Collaborator

This will treat empty strings as null for ES indexing -> #11514

@pinakipb2
Copy link
Contributor Author

@david-leifker - Thanks !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug report
Projects
None yet
Development

No branches or pull requests

4 participants