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

lmdb: Unsupported features #1

Open
2 of 6 tasks
bmatsuo opened this issue Oct 14, 2015 · 4 comments
Open
2 of 6 tasks

lmdb: Unsupported features #1

bmatsuo opened this issue Oct 14, 2015 · 4 comments

Comments

@bmatsuo
Copy link
Owner

bmatsuo commented Oct 14, 2015

Unsupported C functions:

* -- It's currently unclear what benefits this brings
** -- If this can be achieved it will not be trivial for users to instrument

Unusable flags:

@bmatsuo bmatsuo changed the title C functions without bindings Missing bindings Oct 14, 2015
@bmatsuo bmatsuo changed the title Missing bindings Unsupported features Oct 14, 2015
bmatsuo added a commit that referenced this issue Oct 19, 2015
For convention, the method returns an error if the environment is not
open even though the C API returns only an invalid file descriptor.

Relates to #1
@bmatsuo
Copy link
Owner Author

bmatsuo commented Oct 27, 2015

Passing a pointer to the mdb_set_userctx function violates the cgo tool restrictions mentioned in #10.

C code must not store any Go pointers into Go memory, even temporarily.

This makes use of the function very dubious. Storing a size_t integer value as user context does not seem very useful.

@bmatsuo
Copy link
Owner Author

bmatsuo commented Oct 29, 2015

I don't plan on implementing mdb_env_set_assert.

This hack should become obsolete as lmdb's error handling matures.

In my own experience its use has not been desired. And if it were to be supported there would be implementation issues. I'm just going to wait for further development.

@bmatsuo
Copy link
Owner Author

bmatsuo commented Oct 29, 2015

I have opened #12 to track the attempt at supporting mdb_set_compare and mdb_set_dupsort, at first in a primitive form to be expanded later when support is added to the C API.

@bmatsuo
Copy link
Owner Author

bmatsuo commented Nov 1, 2015

Re: mdb_set_relfunc/mdb_set_relctx

This feature is not implemented yet in LMDB

Currently the relocation feature is unimplemented and setting this function has no effect.

It looks like its technically possible to bind the API, though. The ctx function would likely have to be co-opted as is done for mdb_reader_list.

Though I don't have a good understanding of when this would be usable or if Go is usable in such environments. And the feature really shouldn't be implemented until there is some understanding of that.

@bmatsuo bmatsuo modified the milestones: Unplanned, Long-term tracking Nov 2, 2015
@bmatsuo bmatsuo changed the title Unsupported features lmdb: Unsupported features Nov 17, 2015
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