{"id":17279727,"url":"https://github.com/str4d/memuse","last_synced_at":"2025-10-30T16:10:07.764Z","repository":{"id":47071819,"uuid":"402870536","full_name":"str4d/memuse","owner":"str4d","description":"Traits for inspecting memory usage of Rust types","archived":false,"fork":false,"pushed_at":"2024-12-16T16:49:56.000Z","size":37,"stargazers_count":25,"open_issues_count":9,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-04-04T15:45:45.085Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/str4d.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-09-03T18:54:39.000Z","updated_at":"2024-12-13T22:46:12.000Z","dependencies_parsed_at":"2025-01-14T12:09:43.860Z","dependency_job_id":"64f179b0-ec19-49d6-a5f2-325fe168dc63","html_url":"https://github.com/str4d/memuse","commit_stats":{"total_commits":31,"total_committers":1,"mean_commits":31.0,"dds":0.0,"last_synced_commit":"8ddcbcb4a26098a73b79764b4550ae62b2632dac"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/str4d%2Fmemuse","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/str4d%2Fmemuse/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/str4d%2Fmemuse/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/str4d%2Fmemuse/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/str4d","download_url":"https://codeload.github.com/str4d/memuse/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247557767,"owners_count":20958047,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-15T09:18:25.770Z","updated_at":"2025-10-30T16:10:02.715Z","avatar_url":"https://github.com/str4d.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# memuse\n\nThis crate contains traits for measuring the dynamic memory usage of Rust types.\n\n## About\n\nMemory-tracking is a common activity in large applications, particularly ones\nthat receive data from a network and store it in memory. By monitoring how much\nmemory is used by different areas of the application, memory pressure can be\nalleviated by ignoring new packets, or implementing random drop logic for DoS\nmitigation.\n\nMeasuring memory use on the stack is easy, with [`std::mem::size_of`] and\nfriends. Measuring memory allocated on the heap is more tricky. Applications can\nuse a custom global allocator to track the memory usage of different areas. This\nisn't an option for reusable library code however, and the nearest alternative\n(using custom allocators for individual types) is currently only an experimental\nfeature in nightly Rust ([`allocator_api`]).\n\n[`std::mem::size_of`]: https://doc.rust-lang.org/stable/std/mem/fn.size_of.html\n[`allocator_api`]: https://github.com/rust-lang/rust/issues/32838\n\nThis crate takes a different approach: it provides traits that library authors\ncan use to expose dynamic memory usage information on their types. By composing\nthese implementations, we gain the ability to query the amount of heap-allocated\nmemory in use by specific instances of types at any point in time, without any\nchanges to the way in which these types are constructed.\n\n## Minimum Supported Rust Version\n\nRust **1.51** or newer.\n\nIn the future, we reserve the right to change MSRV (i.e. MSRV is out-of-scope\nfor this crate's SemVer guarantees), however when we do it will be accompanied\nby a minor version bump.\n\n## License\n\nLicensed under either of\n\n * Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or\n   http://www.apache.org/licenses/LICENSE-2.0)\n * MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)\n\nat your option.\n\n### Contribution\n\nUnless you explicitly state otherwise, any contribution intentionally\nsubmitted for inclusion in the work by you, as defined in the Apache-2.0\nlicense, shall be dual licensed as above, without any additional terms or\nconditions.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstr4d%2Fmemuse","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstr4d%2Fmemuse","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstr4d%2Fmemuse/lists"}