Skip to content

Add in-memory lease option #63

@leshow

Description

@leshow

I'd like to have the option, specified in the dora config file, to store leases in memory rather than using sqlite directly.

This could be added in multiple stages, the first one being the option to exclusively store leases in memory and not persist them at all. A future change could store leases in-memory and then persist them also to the db or a file in append-only mode.

I have experimented with a few crates for storing IPs. A few options come to mind:

The roaring bitmap might not work for IPv6. I'd be curious to see a comparison of how much memory it takes to store a bunch of IPs in both. one sparse and one dense comparison would be most useful.

After that, it would be cool to be able to change the allocation strategy. Right now we just increment. Might be interesting to be able to specify forward | reverse | random etc

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions