Added a limited implementation of the OTP ets interface #1054
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR implements a small subset of the OTP
ets
interface.The following
ets
functions are supported:ets:new/2
ets:insert/2
ets:lookup/2
ets:delete/2
The following parameters to
ets:new/2
are supported:is_named
{keypos, I :: non_neg_integer()}
private
|protected
|public
access typesOnly the
set
table type is supported.This limited functionality allows users to define ETS tables and share term data between processes in a manner that is more efficient than using message passing with a process. The likely initial users of this feature will be the logging subsystem, as well as parts of the (forthcoming) application support, for storing application environment settings.
This PR provides a partial implementation of issue #887. Subsequent PRs can add additional features from this issue.
For information about the OTP
ets
interface, see https://www.erlang.org/doc/man/ets. This implementation attempts to be API-compatible with the OTP implementation.These changes are made under both the "Apache 2.0" and the "GNU Lesser General
Public License 2.1 or later" license terms (dual license).
SPDX-License-Identifier: Apache-2.0 OR LGPL-2.1-or-later