Skip to content

Add a Builder pattern to Config #78

@anelson

Description

@anelson

In a PR elastio/elastio#6680 it became clear that because Config is marked non_exhaustive, the Config struct can't be initialized the normal way. Instead an ugly mut was used, so the Default() struct could be permuted with the appropriate config options.

This works fine but it's not particularly idiomatic or pleasant. A builder should be added for Config so that this type can be constructed without mutable state, while retaining the non_exhaustive attribute that is important for future flexibility.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions