{"id":18613478,"url":"https://github.com/frugalos/liberasurecode","last_synced_at":"2025-04-10T23:32:04.366Z","repository":{"id":57634812,"uuid":"150537709","full_name":"frugalos/liberasurecode","owner":"frugalos","description":"A Rust wrapper for `openstack/liberasurecode` ","archived":false,"fork":false,"pushed_at":"2020-10-19T05:24:37.000Z","size":48,"stargazers_count":21,"open_issues_count":8,"forks_count":7,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-03-25T06:41:47.465Z","etag":null,"topics":["c-bindings","erasure-coding","rust"],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/frugalos.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-09-27T06:14:53.000Z","updated_at":"2024-02-11T07:16:13.000Z","dependencies_parsed_at":"2022-09-26T20:20:45.458Z","dependency_job_id":null,"html_url":"https://github.com/frugalos/liberasurecode","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frugalos%2Fliberasurecode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frugalos%2Fliberasurecode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frugalos%2Fliberasurecode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/frugalos%2Fliberasurecode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/frugalos","download_url":"https://codeload.github.com/frugalos/liberasurecode/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248036064,"owners_count":21037092,"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":["c-bindings","erasure-coding","rust"],"created_at":"2024-11-07T03:22:23.878Z","updated_at":"2025-04-10T23:32:04.011Z","avatar_url":"https://github.com/frugalos.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"liberasurecode\n==============\n\n[![Crates.io: liberasurecode](https://img.shields.io/crates/v/liberasurecode.svg)](https://crates.io/crates/liberasurecode)\n[![Documentation](https://docs.rs/liberasurecode/badge.svg)](https://docs.rs/liberasurecode)\n[![Build Status](https://travis-ci.org/frugalos/liberasurecode.svg?branch=master)](https://travis-ci.org/frugalos/liberasurecode)\n[![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)\n\nA Rust wrapper for [openstack/liberasurecode].\n\n[Documentation](https://docs.rs/liberasurecode)\n\n[openstack/liberasurecode]: https://github.com/openstack/liberasurecode\n\n\nPrerequisites to Build\n----------------------\n\nThis crate requires the following packages for building [openstack/liberasurecode] in the build script:\n- C compiler (e.g., `gcc`)\n- `git`\n- `make`\n- `automake`\n- `autoconf`\n- `libtool`\n\nFor example, on Ubuntu, you can install those by executing the following command:\n```console\n$ sudo apt install gcc git make automake autoconf libtool\n```\n\n\nExamples\n--------\n\nBasic usage:\n```rust\nuse liberasurecode::{ErasureCoder, Error};\n\nlet mut coder = ErasureCoder::new(4, 2)?;\nlet input = vec![0, 1, 2, 3];\n\n// Encodes `input` to data and parity fragments\nlet fragments = coder.encode(\u0026input)?;\n\n// Decodes the original data from the fragments (or a part of those)\nassert_eq!(Ok(\u0026input), coder.decode(\u0026fragments[0..]).as_ref());\nassert_eq!(Ok(\u0026input), coder.decode(\u0026fragments[1..]).as_ref());\nassert_eq!(Ok(\u0026input), coder.decode(\u0026fragments[2..]).as_ref());\nassert_eq!(Err(Error::InsufficientFragments), coder.decode(\u0026fragments[3..]));\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrugalos%2Fliberasurecode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffrugalos%2Fliberasurecode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffrugalos%2Fliberasurecode/lists"}