lightning

所属分类:加密解密
开发工具:Rust
文件大小:0KB
下载次数:0
上传日期:2023-08-03 00:37:09
上 传 者sh-1993
说明:  Fleek Network,一个去中心化的边缘平台。,
(Fleek Network, a decentralized edge platform.,)

文件列表:
.cargo/ (0, 2023-12-15)
.cargo/config (47, 2023-12-15)
CODE_OF_CONDUCT.md (3114, 2023-12-15)
CONTRIBUTING.md (8698, 2023-12-15)
Cargo.lock (245960, 2023-12-15)
Cargo.toml (2551, 2023-12-15)
Dockerfile (1494, 2023-12-15)
LICENSE (35103, 2023-12-15)
codecov.yml (190, 2023-12-15)
core/ (0, 2023-12-15)
core/application/ (0, 2023-12-15)
core/application/Cargo.toml (952, 2023-12-15)
core/application/genesis.toml (4185, 2023-12-15)
core/application/src/ (0, 2023-12-15)
core/application/src/app.rs (3688, 2023-12-15)
core/application/src/config.rs (1234, 2023-12-15)
core/application/src/env.rs (19252, 2023-12-15)
core/application/src/genesis.rs (4573, 2023-12-15)
core/application/src/lib.rs (159, 2023-12-15)
core/application/src/query_runner.rs (18733, 2023-12-15)
core/application/src/state.rs (68796, 2023-12-15)
core/application/src/storage.rs (4019, 2023-12-15)
core/application/src/table.rs (2300, 2023-12-15)
core/application/src/tests.rs (99013, 2023-12-15)
core/archive/ (0, 2023-12-15)
core/archive/Cargo.toml (654, 2023-12-15)
core/archive/src/ (0, 2023-12-15)
core/archive/src/archive.rs (14450, 2023-12-15)
core/archive/src/config.rs (576, 2023-12-15)
core/archive/src/lib.rs (57, 2023-12-15)
core/archive/src/tests.rs (7540, 2023-12-15)
... ...

![bannergithub](https://github.com/fleek-network/lightning/assets/73345016/43696987-31df-418d-8eba-2ded59d483e0) Lightning is the open-source Rust implementation of Fleek Network. # Lightning - Fleek Network Node [![Commits](https://github.com/fleek-network/lightning/actions/workflows/commits.yml/badge.svg)](https://github.com/fleek-network/lightning/actions/workflows/commits.yml) [![Build & Tests](https://github.com/fleek-network/lightning/actions/workflows/cron.yml/badge.svg)](https://github.com/fleek-network/lightning/actions/workflows/cron.yml) [![Code Coverage](https://codecov.io/github/fleek-network/lightning/branch/main/graph/badge.svg?token=7SN9432OHC)](https://codecov.io/github/fleek-network/lightning) This repository contains the source code for the implementation of *Fleek Network*. Here is the directory schema: ```txt lightning ├── lib │ ├── affair │ ├── atomo │ ├── blake3-stream │ ├── blake3-tree │ ├── fleek-crypto │ ├── hp-fixed │ ├── ink-quill │ ├── sdk │ ├── sdk-macros │ └── simulon ├── core │ ├── application │ ├── blockstore │ ├── consensus │ ├── handshake │ ├── interfaces │ ├── mock │ ├── node │ ├── notifier │ ├── origin-arweave │ ├── origin-filecoin │ ├── origin-ipfs │ ├── pod │ ├── rep-collector │ ├── reputation │ ├── rpc │ ├── signer │ ├── table │ ├── test-utils │ └── topology └── services └── cdn ``` There are 3 top level directories `lib` & `core` and `services`: 1. `lib`: Any open source libraries we create to solve our own problems, these libraries are released with the friendly licenses with the Rust ecosystem (`MIT` | `Apache`). 2. `core`: This is all of the implementation of the core protocol, the main crate is `node` which contains our most important and released `main.rs`. Another important crate that is advised to everyone to get familiar with is `interfaces` which contains the top-down specification of all of the project. 3. `services`: Our services which we build using the `SDK`. # Interfaces The design pattern adopted for this software is highly inspired by the Object-Oriented model described by Alan Kay, which may be a bit different from OOP that grew to fame due to Java. In a nutshell this is similar to the same idea, and we represent different units of computation and process as objects that communicate with each other by message passing. # Rust Version To get the best of the ecosystem by default the nightly version of Rust is set in the `rust-toolchain` file, the version in use is `nightly-2023-07-01`, which is the version used by the `rustfmt` project itself which is a good sign of reliability. This is set so that the default that the IDEs will pick and default invocation of `cargo fmt` is consistent between everyone and also we get to use some of the nightly options when it comes to clippy and fmt. But this does not mean we're going to use this for building and releasing the binary, building the binary for any actual use cases should use the `cargo +stable build` command and the coming scripts and CI config will ease this process. So in summary: We use the default that is set in the `rust-toolchain` to have consistent formatting of the code. And does not necessarily indicate that it is the version of the compiler we are going to use for builds. # Development To run the node and perform a simple healthcheck, do the following: ```bash # Start the node up $ cargo run -r -- run # In another terminal, send a request to the ping rpc endpoint $ curl -X POST -H "Content-Type: application/json" -d '{ "jsonrpc": "2.0", "method": "flk_ping", "params": [], "id": 1 }' http://127.0.0.1:4069/rpc/v0 # Response: {"jsonrpc":"2.0","result":"pong","id":1} ```

近期下载者

相关文件


收藏者