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

KeyValueDataSource.keys() will not work as intended #1541

Open
SergioDemianLerner opened this issue May 20, 2021 · 2 comments
Open

KeyValueDataSource.keys() will not work as intended #1541

SergioDemianLerner opened this issue May 20, 2021 · 2 comments

Comments

@SergioDemianLerner
Copy link
Contributor

The method is defined as : public Set<byte[]> keys();
A java byte[] does not implement hashCode() and therefore the resulting map will not support the contains() method (only iteration).

The resulting type should be Set.

@SergioDemianLerner
Copy link
Contributor Author

For example, LevelDbDataSource.java returns a HashSet.

@SergioDemianLerner
Copy link
Contributor Author

It's also possible to change it to a Collection, with potential duplicates.

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

No branches or pull requests

1 participant