{"id":28546156,"url":"https://github.com/fluencelabs/indexer_workshop","last_synced_at":"2025-07-07T06:31:38.191Z","repository":{"id":45285377,"uuid":"511561724","full_name":"fluencelabs/indexer_workshop","owner":"fluencelabs","description":null,"archived":false,"fork":false,"pushed_at":"2022-08-11T11:14:37.000Z","size":903,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-06-09T23:10:12.332Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/fluencelabs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-07-07T14:32:59.000Z","updated_at":"2022-10-07T13:19:04.000Z","dependencies_parsed_at":"2022-09-07T11:01:29.497Z","dependency_job_id":null,"html_url":"https://github.com/fluencelabs/indexer_workshop","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/fluencelabs/indexer_workshop","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluencelabs%2Findexer_workshop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluencelabs%2Findexer_workshop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluencelabs%2Findexer_workshop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluencelabs%2Findexer_workshop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fluencelabs","download_url":"https://codeload.github.com/fluencelabs/indexer_workshop/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fluencelabs%2Findexer_workshop/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264027591,"owners_count":23546103,"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":"2025-06-09T23:09:02.126Z","updated_at":"2025-07-07T06:31:38.179Z","avatar_url":"https://github.com/fluencelabs.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Workshop\nShining diagrams https://drive.google.com/file/d/1Sri578dBHUui5DJfht6RxcncX19MBybF/view?usp=sharing\n\n## Experimenting on IPFS with Aqua\n### What's the value?\n- Write, run and evolve distributed algorithms\n- Quick experimentation\n- Declarative-ish language, focus on algorithms, not nitty-gritty\n- Iterative development: start REALLY simple, go sophisticated gradually\n- Subnet-oriented thinking\n\n### What's this workshop isn't about\n- How to build production-ready decentralized IPFS indexer\n\n### What's the goal?\n- Seed ideas about a quite different approach to distributed systems\n- Request for comments, problems, ideas and approaches: what would YOU do with Aqua?\n- Have fun, melt brains a little bit\n\n### Scenario\nImagine we're building an app, and want to use IPFS as a data plane.\n\n- Take some peers from the p2p network, and command them to obey (they can't resist. yet.)\n- Use these peers as: IPFS-powered data plane, distributed index, orchestrators\n    - These could be all separate peers, but won't bother for the workshop\n- Upload files, store location info to Distributed Index (tm), make nodes lose files, repair from index\n\n### Tooling, moving parts\n- `aqua run` - takes Aqua script, compiles it to AIR, sends to network. Acts as a short-lived JS peer.\n- rust peers - running on cloud, each has go-ipfs as a sidecar\n- `aqua-ipfs` - WASM service wraps IPFS cli and provides it as an API to Fluence network, hosted on all Fluence Rust Peers\n- `ipfs_client.mjs` - JS module that provides ipfs-js peer as an API to Fluence network, works on my laptop\n- indexer service written in rust, compiled to wasm, upload to ipfs and deployed to Fluence\n\nSHOW: picture of topology layout\n\n### Let's run it: make subnet, upload, get index, loose files, repair\nSHOW: pictures of what happened on each step\n\n### Let's review code: upload\n\n### Let's review code: repair\n\n### Let's review code: whos_absent\n\n# On your own\n## Where to start\nRead the [main.aqua](src/aqua/main.aqua)\n\n## How to run\n### Create subnet\n```\nnpm run subnet\n```\n\n### Upload to subnet\n```\nFILE=\"$(pwd)/package-lock.json\" npm run upload\n```\n\n### Get index\nCopy the CID from logs of `upload`, and paste it as `CID=`\n\n```\nCID=QmdQepGdyPro8GQsEUs4Ep8fZ1G1HsPNHAuFNRCEiC3ahY npm run get_index\n```\n\n### Unpin file from some nodes\n```\nipfs --api \"/ip4/134.209.186.43/tcp/5002/p2p/12D3KooWNWW5rX9QWSfsHJZVhuKyUb7rPKDvBNqyCuK21JmjyGPt\" pin rm QmdQepGdyPro8GQsEUs4Ep8fZ1G1HsPNHAuFNRCEiC3ahY\n\nipfs --api \"/ip4/134.209.186.43/tcp/5005/p2p/12D3KooWHtjVS2LSKpQsFFbNxPaLTAV8Si2LiohkK2CrQsyJymMX\" pin rm QmdQepGdyPro8GQsEUs4Ep8fZ1G1HsPNHAuFNRCEiC3ahY\n```\n\n### Check absent\n```\nCID=QmdQepGdyPro8GQsEUs4Ep8fZ1G1HsPNHAuFNRCEiC3ahY npm run absent\n```\n\n### Run repair\n```\nCID=QmdQepGdyPro8GQsEUs4Ep8fZ1G1HsPNHAuFNRCEiC3ahY npm run repair\n```\n\n### Check absent again\n```\nCID=QmdQepGdyPro8GQsEUs4Ep8fZ1G1HsPNHAuFNRCEiC3ahY npm run absent\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffluencelabs%2Findexer_workshop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffluencelabs%2Findexer_workshop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffluencelabs%2Findexer_workshop/lists"}