logdna / logdna/logdna-rust

KeyValueMap easier to populate/transform to

Open
#26 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
3
Forks
4
PR merge metrics
No merged PRs in 30d

Description

Thank you for `Tags::parse(..)`.

We probably don't need/want any out-of-the box parsing for key-value pairs, since the separators... may vary. But how about
- `KeyValueMap::new(given_map: HashMap)` that would take its ownership (especially since the current implementation is a wrapper), and optionally:
- a conversion function like `KeyValueMap::new(it: Iterator) -> Self`? (Or implementing `TryFrom`, but something tells me that `TryFrom` is not a good way to go here.)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading the current KeyValueMap implementation and the Tags::parse(..) API, paying attention to how the wrapper stores its data. Compare the proposed HashMap ownership and iterator conversion options with existing callers. Done means the supported construction paths are decided, implemented, and covered by tests for the requested key-value inputs.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
backend-api-design
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.