27 lines
974 B
Markdown
Raw Permalink Normal View History

2021-08-12 18:13:53 +03:00
# IPFS Compute Web Demo
2021-07-21 11:37:25 +03:00
2021-08-12 18:13:53 +03:00
It's possible to implement any kind of computations on top of IPFS with Fluence. In this demo, we use a simple example that calculates size of a file. It's easily extendable to any kind of file processing or manipulation.
## Connect to the Fluence Network
You're presented with 3 random relays, connect to any of them.
2021-09-04 18:20:01 -05:00
![connect](images/ipfs_comp_web_1.png)
2021-08-12 18:13:53 +03:00
## Deploy a service from IPFS
You will download `process_files.wasm` from IPFS network to a Fluence node, and deploy it.
2021-09-04 18:20:01 -05:00
![deploy](images/ipfs_comp_web_2.png)
2021-08-12 18:13:53 +03:00
## Call a function on the deployed service
You've just deployed [ProcessFiles](/aqua/src/process_files.aqua) service. It allows you to query file size of a file downloaded from IPFS. Enter IPFS CID, and press `get size` button.
2021-09-04 18:20:01 -05:00
![get file size](images/ipfs_comp_web_3.png)
2021-08-12 18:13:53 +03:00
## Observe the result
File size has been calculated, you can see it at the bottom of the web page.
2021-09-04 18:20:01 -05:00
![observe file size](images/ipfs_comp_web_4.png)