---
title: 'Fleek Network - Decentralized Edge'
disqus: hackmd
---
Fleek Network: Unleashing the Power of Decentralized Cloud and Edge Computing
===
## Table of Contents
[TOC]
## Introduction
### Brief overview of Fleek Network
Fleek Network is a protocol designed to enhance web-based computing by distributing cloud and edge resources. It uses unused computing power to provide a cost-effective and accessible system. Focusing on secure computing, the Network maintains privacy and reliability for many users, such as developers and computer owners.
### The need for decentralized cloud and edge computing
As technology advances, dependence on centralized cloud services increases. However, these centralized systems possess inherent drawbacks and risks, such as single points of failure, possible data breaches, and delays. Decentralized cloud and edge computing seeks to resolve these issues by dispersing computing resources across numerous nodes, improving security, privacy, and performance. This approach addresses concerns related to specific centralized systems like AWS Nitro and confidential computation.
#### Resilience and Security
Decentralized systems improve resilience by eliminating single points of failure. With data and computational resources spread across a network of nodes, the system can continue operating even if some nodes go offline. This distributed architecture enhances security by making it more challenging for bad actors to compromise the system.
#### Privacy
Centralized cloud services often access sensitive user data, raising privacy concerns. In contrast, decentralized systems emphasize user-controlled cryptographic identities, enabling users to manage access to their data. This approach ensures greater privacy and control over personal information.
#### Performance and Efficiency
Edge computing, a core aspect of decentralized systems, moves computation closer to data sources and end-users. This proximity reduces latency and improves user experience. Furthermore, decentralized systems can allocate resources more effectively and handle computational loads efficiently, reducing data transfer costs and enhancing performance.
#### Cost Savings and Accessibility
Decentralized cloud and edge computing can save costs by utilizing spare computing resources worldwide. By contributing these resources to an open market, computing costs are lowered, and profits are distributed among participants. This approach also democratizes access to computing resources, allowing smaller teams and individuals to develop and scale applications without prohibitive costs.
### The Vision Behind Fleek Network
Fleek Network offers a decentralized cloud and edge computing platform. The goal is to make computing more accessible and affordable, fostering a strong, secure, and privacy-centric ecosystem.
The Network uses existing decentralized storage solutions, promoting global participation to reduce computing costs. A key aspect of the vision is edge computing, which brings processing closer to data sources and users, increasing efficiency and enhancing user experiences.
Fleek Network is dedicated to creating an easy infrastructure for developers to use and addresses the challenges of executing computations in distributed peer-to-peer systems. Striving to balance privacy, verifiability, and performance in trustless computing, it caters to a wide range of user needs and encourages innovation.
Furthermore, Fleek Network provides a framework for building other networks using its existing components, allowing developers to save time and focus on creating unique cryptographic or economic models.
In a nutshell, Fleek Network aims to reshape the web3 landscape with a decentralized cloud and edge computing platform that fosters innovation, lowers costs, and supports a safe and inclusive computing environment.
### Background and motivation
Today the demand for efficient and reliable computing resources is ever-increasing. Traditional cloud computing services, while helpful, often face issues related to centralization, privacy, and security. As our reliance on these services grows, the need for an alternative solution becomes increasingly apparent. Decentralized cloud and edge computing offer a promising alternative that addresses many challenges centralized models face.
#### Centralization Challenges
Centralized cloud computing providers control most of the market, like Amazon Web Services, Microsoft Azure, and Google Cloud Platform. This centralization has several drawbacks, including:
1. **Single points of failure:** A single company controls the infrastructure, making the entire system vulnerable to outages, cyber-attacks, or even corporate decisions that may not align with users' best interests.
2. **Data privacy concerns:** Centralized providers have access to vast amounts of user data, raising concerns about privacy and the potential misuse of information.
3. **Vendor lock-in:** Users often find switching providers or migrating their applications and data challenging, leading to dependence on a single vendor.
#### Decentralized Cloud and Edge Computing Advantages
Decentralized cloud and edge computing aim to address the challenges of centralization by distributing resources across a network of independent nodes. This approach offers several advantages:
1. **Enhanced security and privacy:** Decentralized systems use cryptographic techniques to secure data and transactions, making it difficult for malicious actors to compromise the system or access sensitive information.
2. **Greater resilience:** By distributing resources across multiple nodes, the risk of a single point of failure is reduced, resulting in a more resilient and reliable infrastructure.
3. **Improved performance:** Edge computing allows data processing to occur closer to the data source, reducing latency and improving user experience.
4. **Cost-effectiveness:** Decentralized systems can harness underutilized computing resources, creating a more competitive market that can drive down user costs.
5. **Flexibility and innovation:** Decentralized cloud and edge computing enable a more open and collaborative environment, fostering innovation and the development of novel applications and services.
### Future of app development
The future of app development will allow app creators to be more accessible and inclusive, empowering people with diverse backgrounds and skill levels to develop and deploy their applications. Decentralized cloud and edge computing play a significant role in fostering this democratization by reducing costs, promoting innovation, and enabling more equitable access to resources.
#### Reduced Costs
Centralized cloud services often impose high costs on developers, creating barriers to entry for small teams and individuals. By leveraging spare computing resources from around the world, decentralized systems can significantly lower these costs, enabling more developers to create and scale their applications without prohibitive expenses.
#### Innovation and Collaboration
By making app development more accessible, decentralized cloud and edge computing encourage innovation and collaboration. A diverse range of voices and perspectives can contribute to the development process, leading to novel applications and solutions that address various user needs. This collaborative environment fosters learning and growth, allowing developers to improve their skills and share their knowledge with others.
#### Equitable Access to Resources
Traditional cloud computing resources are often concentrated in specific geographic locations, leading to disparities in access and performance. On the other hand, decentralized systems distribute resources across a global network of nodes, ensuring that users and developers can access computing resources regardless of location. This equal distribution of resources promotes inclusivity and helps bridge the digital divide.
### Cloudless computing: the next big step
Cloudless computing represents a paradigm shift in how applications are built, deployed, and managed, focusing on using protocols instead of centralized services. This approach enables greater portability, resilience, and cost savings while fostering new business models and opportunities.
#### Why Cloudless Computing Matters
1. **Cryptographic Signatures**: With the increasing adoption of blockchain and the widespread understanding of cryptographic signing, cloudless computing has become more practical and accessible. Key-handling infrastructure is now an integral part of modern browsers, making it easier to adopt cloudless computing principles.
2. **Security**: By upgrading the current use of tokens to include signatures from client device keys, cloudless computing improves security.
3. **Efficiency and Cost Savings**: Cloudless computing allows for moving computation closer to the data source and end-users. Cloudless computing enables significant cost savings and enhanced efficiency by commuting multiple operations, including permission checks, and avoiding proxy copying.
#### The Future of Cloudless Computing
As cloudless computing continues to gain momentum, we can expect to see a greater emphasis on the following aspects:
- **Decentralized hosting and resource management**: Overcoming resource limitations and handling computational loads more effectively will become increasingly important, enabling edge computing and reducing data transfers.
- **Competitive market for computing infrastructure**: The cryptographic verifiability and trust inherent in cloudless computing will lead to a competitive enterprise market, resulting in lower costs and more robust applications.
- **Resilience and trust through cloudless protocols**: Using location-independent links to data and computation will enable new applications and business models, enhancing the interconnectedness and efficiency of the computing landscape.
## Core Components of Fleek Network
```mermaid
graph TB
A[User] --> B[Web Interface/APIs]
B --> C[Fleek Network]
C --> D[API Gateway & Encrypted Relay]
D --> E[Modular Verifiable Computation]
D --> F[Decentralized Storage]
D --> G[AI Services]
D --> H[GPU Services]
E --> I[Edge Compute Nodes]
E --> J[Universal Fair Delivery Protocol]
I --> K[Serverless Functions]
I --> L[Compute]
F --> M[IPFS]
F --> N[Filecoin]
F --> O[Arweave]
J --> P[CDN]
P --> Q[Gateway Nodes]
P --> R[Edge Nodes]
P --> S[Origin Nodes]
P --> T[Content Providers]
subgraph "Fleek Network"
E; F; G; H; I; J; P;
end
subgraph "Edge Nodes"
R; K; L;
end
subgraph "Decentralized Storage"
M; N; O;
end
subgraph "User Interface"
B; A;
end
subgraph "Decentralized CDN"
Q; R; S; T;
end
subgraph "API Gateway and Encrypted Relay"
D;
end
subgraph "AI & GPU Services"
G; H;
end
```
### Overview of the system architecture
Fleek Network's system architecture is designed to support decentralized cloud and edge computing, leveraging global spare computing power and contributing it to an open market. The following sections provide a high-level overview of Fleek Network's architecture's key components and features.
| Entity | Attributes |
| -------- | -------- |
| User | user_id, username, email, password, storage_quota, balance |
| Applications | application ID, name, description, owner (linked to Users)|
| Functions | function ID, name, description, code, user_id, content_type, content_size, ipfs_cid, storage_duration, upload_time, expiration_time |
| Edge Compute Node | node_id, node_address, compute_capacity, compute_price |
| Transaction | transaction_id, user_id, node_id, file_id, compute_time, transaction_time, transaction_fee |
| Database | data ID, type (file or object), location (linked to IPFS and Filecoin), owner (linked to Users) |
| Storage (IPFS, Filecoin, Arweave) | location, status, capacity, availability |
| Runtime | runtime_id, runtime_type, memory_limit, timeout_limit |
#### Key Components
```mermaid
erDiagram
Users ||--o{ Applications : Owns
Applications ||--o{ Functions : Contains
Functions }|--|| Runtimes : Executed on
EdgeNodes }|--|| Runtimes : Run on
Storage }|--|| Applications : Stores
Storage }|--|| IPFS : Uses
Storage }|--|| Filecoin : Uses
Users {
int user_id
varchar name
varchar email
varchar password
}
Applications {
int app_id
varchar name
varchar description
int user_id
}
Functions {
int func_id
varchar name
varchar description
text code
int app_id
}
EdgeNodes {
int node_id
varchar ip_address
varchar resources
}
Runtimes {
int runtime_id
varchar type
int func_id
varchar resource_limits
}
Storage {
int data_id
varchar type
varchar location
int user_id
}
IPFS {
varchar location
varchar status
}
Filecoin {
varchar location
int capacity
varchar availability
}
```
```mermaid
sequenceDiagram
participant User
participant APIGateway
participant CDN
participant Functions
participant Runtimes
participant EdgeNodes
User->>APIGateway: Sends HTTP request with API key
APIGateway->>Functions: Looks up function in a database
Functions->>Runtimes: Spawns user runtime instance
Runtimes->>EdgeNodes: Sends the request to execute function
EdgeNodes->>Runtimes: Sends response with results
Runtimes->>APIGateway: Returns results to API gateway
APIGateway->>User: Returns results to a user
```
The architecture comprises six main subgraphs: User Interface, Fleek Network, Edge Nodes, Decentralized Storage, Decentralized CDN, and Gateway. The components within each subgraph work together to provide a seamless experience for users while ensuring the system's security, scalability, and performance. The Decentralized CDN subgraph supports content request, caching, replication, and delivery, making it a complete solution for Web 3.0 applications.
The other two subgraphs showcase support for both deterministic and non-deterministic code execution: Deterministic Code and Non-Deterministic Code. The Deterministic Code subgraph handles cases where code execution is deterministic, utilizing multiple verifiers for cross-checking results and reaching consensus. In contrast, the Non-Deterministic Code subgraph addresses non-deterministic code execution by leveraging Trusted Execution Environments, Secure Multi-Party Computation, and Zero-Knowledge Proofs to ensure security and privacy. These additions provide a more robust and flexible solution for various use cases and requirements in the Web 3.0 ecosystem.
```mermaid
graph LR
A[User] --> B[Web Interface/APIs]
B --> C[Fleek Network]
C --> AE[API Gateway & Encrypted Relay]
AE -->|Define serverless function| D{Modular Verifiable Computation}
AE -->|Store/Retrieve data| E[Decentralized Storage]
AE -->|GPU| E[GPU]
D --> F[Partitioning]
F --> G[Computation Fragments]
G --> H[Execute]
F --> I[Verifier]
I --> J[Verify Fragment 1]
I --> K[Verify Fragment 2]
I --> L[Verify Fragment 3]
J --> M[Proof Fragment 1]
K --> N[Proof Fragment 2]
L --> O[Proof Fragment 3]
E --> P[IPFS]
E --> Q[Filecoin]
E --> R[Arweave]
H --> S[Edge Node 1]
H --> T[Edge Node 2]
H --> U[Edge Node 3]
S -->|Return output| AE
T -->|Return output| AE
U -->|Return output| AE
B --> V[User Dashboard]
V --> W[Usage Analytics]
V --> X[Resource Management]
V --> Y[Developer Tools]
AE -->|Request content| Z[Decentralized CDN]
Z --> AA[Gateway Nodes]
Z --> AB[Edge Nodes]
Z --> AC[Origin Nodes]
Z --> AD[Content Providers]
D --> E1[Case: Deterministic Code]
D --> E2[Case: Non-Deterministic Code]
D --> AG[Deterministic Execution Engine]
D --> AH[Non-deterministic Execution Engine]
E1 --> E3[Multiple Verifiers]
E3 --> E4[Cross-Checking Results]
E4 --> E5[Consensus]
E2 --> E6[Trusted Execution Environments]
E2 --> E6[Trusted Execution Environments]
E6 --> E7[Secure Multi-Party Computation]
E6 --> E8[Zero-Knowledge Proofs]
E5 --> F1[Validators]
subgraph "Fleek Network"
D; E; H; I; Z;
end
subgraph "Edge Nodes"
S; T; U;
end
subgraph "Decentralized Storage"
P; Q; R;
end
subgraph "User Interface"
B; V; W; X; Y;
end
subgraph "Decentralized CDN"
AA; AB; AC; AD;
end
subgraph "Deterministic Code"
E1; E3; E4; E5;
end
subgraph "Non-Deterministic Code"
E2; E6; E7; E8;
end
subgraph "Validators (BFT)"
F1;
end
subgraph "API Gateway and Encrypted Relay"
AE;
end
```
```mermaid!
+-------------+ +------------+ +------------+ +-------------+
| | | | | | | |
| User +-----> Relay +-----> App/API +-----> 3rd Party |
| (Frontend) | | (Ingress) | | Server | | Services |
| | | | | | | |
+------+------+ +------+-----+ +------+-----+ +------+------+
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
+------+------+ +------+-----+ +------+-----+ +------+------+
| | | | | | | |
| 3rd Party <-----+ Relay <-----+ App/API <-----+ User |
| Services | | (Egress) | | Server | | (Frontend) |
| | | | | | | |
+-------------+ +------------+ +------------+ +-------------+
```
##### In this diagram:
- User (Frontend) sends a request to the Relay ingress gateway.
Relay ingress gateway encrypts sensitive data in the request using forwards the encrypted request to the App/API Server.
- App/API Server processes the request and sends the response (with encrypted data) back to the Relay ingress gateway.
- Relay ingress gateway decrypts the encrypted data in the response forwards the decrypted response to the User (Frontend).
- App/API Server sends a request to the Relay egress gateway to forward data to a trusted 3rd Party Service.
- Relay egress gateway decrypts sensitive data in the request using forwards the decrypted request to the 3rd Party Service.
- 3rd Party Service processes the request and sends the response back to the Relay egress gateway.
- Relay egress gateway forwards the response to the App/API Server without any modification.
- Relay is a globally distributed encryption proxy that provides industry-standard encryption, simplifying the integration and management of encryption. It allows for field-level encryption and decryption without affecting user experience
##### Decentralized Storage
- **IPFS**: Fleek Network utilizes the InterPlanetary File System (IPFS) for distributed, peer-to-peer storage, allowing content-addressed, distributed file sharing.
- **Filecoin**: Filecoin, a decentralized storage network built on top of IPFS, is used by Fleek Network to provide a marketplace for data storage, allowing users to rent out their storage space and earn rewards.
- **Arweave**: expand.
#### Decentralized Content Delivery
- **Fleek Network**:
##### Decentralized Compute
- **Edge Compute Nodes**: Fleek Network's architecture includes edge compute nodes, which are responsible for executing users' code in a decentralized manner. These nodes contribute their spare computing resources to the Network, enabling a more cost-effective and scalable computing infrastructure.
- **User Runtime**: The user runtime is an instance responsible for executing user code. Limits on memory and timeouts are set to ensure the efficient use of resources.
- **MicroVMs**: The main VMs are an entry point before running user functions, handling tasks like authentication and proxying transactions to the user runtime. It is powered by a Hypervisor layer such as Firecracker.
#### Key Features
##### Programmable Infrastructure
Fleek Network provides a programmable infrastructure for developers to build and deploy decentralized applications. This infrastructure is designed to be enjoyable, despite the inherent challenges and complexities of executing arbitrary computation in distributed, peer-to-peer trustless systems.
```rust
pub struct Job {
id: String,
payload: Vec<u8>,
requirements: Requirements,
status: JobStatus,
}
pub struct Requirements {
cpu: u32,
memory: u32,
}
pub enum JobStatus {
Pending,
Running,
Completed,
Failed,
}
```
##### Trustless Computing
Fleek Network focuses on balancing the triad of trustless computing: privacy, verifiability, and performance. The platform accommodates various user needs and encourages innovation by exploring and implementing state-of-the-art approaches.
Add Triad digram
##### Modular Framework
Fleek Network offers a modular framework for the community to develop other networks using their existing building blocks. This framework allows blockchain developers to accelerate their time to market and focus on novel cryptography or economic models rather than reinventing the wheel.
```mermaid
flowchart LR
A(Modular Framework) --> B(Execute Modules)
B --> C{Module Type}
C -->|Nondeterministic| D[Execute]
C -->|Deterministic| E[Verify Execution]
E --> F[Re-execute]
E --> G[Verify Output]
G -->|Valid| H[Return Result]
G -->|Invalid| F
D --> H
```
** Add the design of the modular compute we have
### Edge functions and serverless approach
Fleek Network seeks to redefine how applications are developed and hosted by incorporating edge functions and serverless architecture. This approach enhances the efficiency, scalability, and user experience of web3 applications while reducing costs and complexities.
#### Edge Functions
Edge functions involve executing user-defined code in response to specific events or triggers. They are often executed close to the data source or end-users, ensuring lower latency and improved performance. Fleek Network incorporates edge functions as a core component of its decentralized computing platform.
By enabling developers to build and deploy edge functions on the Fleek Network, creating more dynamic and responsive applications that can efficiently process and deliver data to users becomes possible.
#### Serverless Architecture
Fleek Network's serverless approach allows developers to focus on writing code without worrying about the underlying infrastructure. In a serverless environment, functions are executed on demand, and resources are allocated as needed. This results in cost savings, as users only pay for the actual compute resources consumed rather than pre-allocated resources.
The serverless approach simplifies the development and deployment process, as developers no longer need to manage servers, networking, and other operational aspects. Fleek Network aims to offer a seamless serverless experience, enabling developers to deploy their edge functions easily and quickly.
#### Advantages of Edge Functions and Serverless Approach
- Improved efficiency: By moving computation closer to the data source and end-users, edge functions reduce latency and deliver better performance.
- Cost-effective: Serverless architecture allows users to pay only for the resources they consume, resulting in lower costs.
- Scalability: Serverless platforms automatically allocate resources as needed, enabling applications to scale effortlessly.
- Simplified development process: The serverless approach removes the need for developers to manage the underlying infrastructure, allowing them to focus on writing code.
### Trustless computing triad: privacy, verifiability, and performance
Fleek Network seeks to establish a decentralized computing platform that excels in privacy, verifiability, and performance. These three elements, collectively known as the trustless computing triad, are crucial for fostering a secure, reliable, and efficient environment for web3 applications.
#### Privacy
Privacy is critical to trustless computing as it ensures that sensitive information remains confidential and secure. Fleek Network is designed with privacy in mind, leveraging cryptographic techniques and protocols to protect user data and maintain anonymity when needed.
By incorporating privacy features at the core of its architecture, Fleek Network aims to offer a secure environment for users and developers to build and use applications without compromising their sensitive information.
#### Verifiability
Verifiability is another essential component of trustless computing, enabling users to validate the correctness of computations and data. In a decentralized environment, verifiability becomes even more critical, as it helps establish trust between participants without relying on centralized authorities.
Fleek Network employs cryptographic methods, such as digital signatures and zero-knowledge proofs, to ensure that computations and data can be verified independently. This ensures the integrity and correctness of the system, promoting trust among users and developers.
#### Performance
Performance is the final element of the trustless computing triad, and it is vital for ensuring that decentralized applications can efficiently handle user demands. Fleek Network is designed to optimize performance by leveraging edge computing and serverless architecture, which brings computation closer to the data source and end-users.
Fleek Network aims to provide a fast and responsive environment for web3 applications by focusing on modularity, ensuring users enjoy a seamless experience.
## Fleek Network's User Roles
### Developers: defining serverless functions
Developers define and deploy serverless functions that can be executed at the edge. These functions can perform various tasks, from processing user input and generating dynamic content to interfacing with external APIs and performing complex data transformations.
Developers use Fleek Network's interface to deploy their serverless functions, specifying the input and output parameters, the computing resources required, and the execution environment. Fleek Network's platform supports various programming languages, including JavaScript, TypeScript, and WASM, and developers can easily integrate third-party libraries and frameworks to build more complex applications.
```mermaid
sequenceDiagram
participant Developer
participant Fleek Network
Developer->>Fleek Network: Define serverless function
Fleek Network->>Developer: Acknowledge receipt
Developer->>Fleek Network: Specify input/output parameters
Fleek Network->>Developer: Provide computing resource options
Developer->>Fleek Network: Choose execution environment
Fleek Network->>Developer: Return function ID
```
### Compute nodes: contributing resources
Compute nodes contribute spare computing resources to Fleek Network by providing storage, processing power, and bandwidth for executing serverless functions at the edge. Owners can earn FLK by executing serverless functions defined by developers. Fleek Network's platform efficiently manages resource allocation across the Network, making it more accessible and inclusive while reducing computing costs.
```mermaid
sequenceDiagram
participant Developer
participant FleekNetwork
participant EdgeNode
Developer->>FleekNetwork: Define serverless function
FleekNetwork->>FleekNetwork: Store serverless function as IPLD
Developer->>FleekNetwork: Submit function to marketplace
FleekNetwork->>FleekNetwork: Verify function code
FleekNetwork->>EdgeNode: Broadcast function request
EdgeNode->>FleekNetwork: Respond to function request with price
FleekNetwork->>FleekNetwork: Select EdgeNode based on price and reputation
FleekNetwork->>EdgeNode: Execute serverless function
EdgeNode->>FleekNetwork: Return result of serverless function
FleekNetwork->>FleekNetwork: Verify result of serverless function
FleekNetwork->>Developer: Pay EdgeNode with FLK
Developer->>FleekNetwork: Access serverless function result
```
### Developers: building on the Fleek Network
Blockchain developers use Fleek Network's decentralized storage and computing capabilities to build decentralized applications and smart contracts. The platform provides open-source libraries and tools that support various blockchain networks and flexible storage options. By building on Fleek Network, developers can use its unique features, such as edge computing and serverless functions, to create more efficient and scalable applications while collaborating and innovating with the community.
## Fleek Network vs. Traditional CDNs

### Differences in structure and approach
Fleek Network has a different approach to content delivery and edge computing than traditional Content Delivery Networks (CDNs). Unlike CDNs that rely on centralized data centers, Fleek Network uses a decentralized network of compute nodes to execute serverless functions at the edge. This results in reduced latency, improved scalability, and increased reliability.
Fleek Network is more accessible and cost-effective than traditional CDNs since users can contribute spare computing resources to the Network, reducing compute and storage costs. Fleek Network focuses on trustless computing, leveraging blockchain technology and cryptographic protocols to ensure high privacy, verifiability, and performance, making users' data and computation secure and reliable.
### Current Arch
```mermaid
graph TB
A[User] --> B[Gateway Node]
B --> C[Cache Node]
B --> D[Origin Server]
C --> F[Filecoin]
C --> G[IPFS]
C --> H[Other Storage Protocols]
D --> E[Client Data]
E --> F
E --> G
E --> H
I[FLK Token] -.-> B
I -.-> C
I -.-> D
J[Blockchain] -.-> I
```
### The advantages of decentralization
Fleek Network's decentralized approach to content delivery and edge computing offers several advantages over traditional Content Delivery Networks (CDNs).
1. Firstly, decentralization reduces reliance on centralized data centers, which can be prone to outages and single points of failure. Fleek Network's decentralized Network of compute nodes ensures greater resilience and reliability.
2. Fleek Network's decentralized architecture provides reduced latency and improved scalability. With serverless functions executed at the edge, content can be delivered more quickly, improving the user experience.
3. Fleek Network's platform is designed to be more cost-effective and accessible than traditional CDNs. By leveraging spare computing resources, computing and storage costs are significantly reduced, making it more affordable for developers and businesses of all sizes.
4. Fleek Network's focus on trustless computing provides high privacy, verifiability, and performance, ensuring that users' data and computation are secure and reliable.
Fleek Network's decentralized approach provides a more resilient, efficient, cost-effective solution for content delivery and edge computing.
## The Technology Behind Fleek Network
### Modular verifiable computation
```mermaid
graph TD;
A(Modular Computation)-->B[Partitioning];
B-->C[Computation Fragments];
B-->D[Verifier];
C-->E[Execute];
E-->F[Computation Fragment 1];
E-->G[Computation Fragment 2];
E-->H[Computation Fragment 3];
D-->I[Verify Fragment 1];
D-->J[Verify Fragment 2];
D-->K[Verify Fragment 3];
I-->L[Proof Fragment 1];
J-->M[Proof Fragment 2];
K-->N[Proof Fragment 3];
```
### Cryptographic verifiability, secrecy, and optimistic verifiability
### Determinism and support for nondeterministic code execution
```mermaid
sequenceDiagram
participant Developer
participant FleekNetwork
Developer->>+FleekNetwork: Define serverless function
FleekNetwork->>+FleekNetwork: Modular Verifiable Computation
alt Deterministic
FleekNetwork->>EdgeNode: Execute serverless function
EdgeNode->>FleekNetwork: Return output
FleekNetwork->>-Developer: Return output
else Non-Deterministic
FleekNetwork->>EdgeNode1: Execute serverless function
EdgeNode1->>FleekNetwork: Return output
FleekNetwork->>EdgeNode2: Execute serverless function
EdgeNode2->>FleekNetwork: Return output
FleekNetwork->>-Developer: Return output
end
```
### Integration with existing protocols (IPFS, Filecoin, Arweave, etc.)
## Practical Use Cases for Fleek Network
### Data-intensive applications and research workloads
Fleek Network also provides a distributed computing infrastructure using edge computing nodes, which can be leveraged for research workloads, machine learning, and artificial intelligence applications. This enables faster processing and analysis of large datasets and more efficient training and deployment of machine learning models without expensive traditional infrastructure.
### Decentralized content delivery
Decentralized content delivery is a practical use case for Fleek Network. Fleek Network leverages decentralized storage and computing capabilities, unlike traditional content delivery networks (CDNs) that rely on centralized servers. This approach enables more efficient and cost-effective content delivery with greater redundancy and scalability.
Fleek Network utilizes decentralized storage providers and edge compute nodes for distributed computing. Fleek Network provides a resilient and efficient content delivery solution using users' spare computing resources globally. The platform's programmable infrastructure and modular framework allow developers to build and deploy decentralized applications for content delivery, including peer-to-peer file sharing and streaming services. Decentralized content delivery has the potential to improve content delivery on the internet, making it more secure, efficient, and cost-effective.
### Secure, verifiable computation for blockchain projects
Fleek Network provides a practical solution for blockchain projects that require secure and verifiable computation. It is a decentralized compute node and programmable infrastructure enabling blockchain application development and deployment with improved security and transparency.
By leveraging Fleek Network's edge compute nodes, blockchain projects can execute their code in a decentralized manner, reducing the risk of security breaches and increasing transparency through verifiable computation. This can benefit a range of use cases, including decentralized finance, identity management, and supply chain tracking.
## Fleek Network Dyson Sphere
### Upcoming mprovements and new features
Fleek Network has the potential for continued growth and development, with several potential improvements and new features on the horizon. Some of the most promising areas for development include:
- **Improved scalability:** Fleek Network's decentralized infrastructure is already designed for scalability, but there is always room for improvement. Continued development and optimization could enable even greater scalability, making Fleek Network a more robust platform for decentralized applications and data processing.
- **Expanded storage options:** While Fleek Network currently utilizes IPFS and Filecoin for decentralized storage, there may be opportunities to incorporate other storage options. This could provide even more flexibility and redundancy for data storage and distribution.
- **Enhanced security features:** As with any decentralized system, security is always a top priority. Fleek Network could benefit from the continued development of enhanced security features, such as advanced encryption and authentication protocols, to ensure the integrity and privacy of user data.
- **Integration with other blockchain platforms:** Fleek Network is designed to be modular and interoperable, making integrating with other blockchain platforms and networks possible. This could enable even greater functionality and new use cases for the platform.
### Supporting the growth of the decentralized web (Web3)
Fleek Network aims to support the development of the decentralized web (Web3) by enabling developers to build and deploy decentralized applications more efficiently. This includes improving developer tools and adding new features that make it simpler to create and deploy Web3 applications. To suppor this vision we are taking the following steps:
1. **Modular Architecture**: The architecture of Project27 should be designed modularly to incorporate new services as commodities easily. Each module can represent a different service, such as computing, serverless functions, storage, AI, GPU, and more. This modular approach allows for the easy addition and removal of services based on demand and technological advancements.
2. **Dynamic Pricing**: Each service can have its pricing structure, which can be determined by various factors such as demand, supply, and computational requirements. The pricing model should be dynamic and adaptable to market changes. It could also incorporate auction-based or tiered pricing models to optimize resource allocation and cost.
3. **Abstract Interface**: An abstract interface can be designed to represent these commodities in a user-friendly way. This interface should provide users with clear information about each service, pricing, and capabilities. It should also allow users to select and combine services based on their specific needs easily.
4. Standardized API: A standardized API can be developed to allow users and applications to interact with these services consistently and predictably. This API should support all the services offered by Project27 and be designed to be extensible to accommodate future services. It should provide methods for querying available services, retrieving pricing information, requesting assistance, and managing ongoing usage.
5. **Service-Level Agreements (SLAs)**: Each service should have a clear SLA outlining the expected performance and reliability of the service. This will give users confidence in the quality of the services they are purchasing and provide a benchmark for service providers to meet.
6. **Interoperability**: The services should be designed to be interoperable, allowing users to combine different services seamlessly. For example, a user might want to use the storage service with the AI service to store and analyze data. The system should support this kind of integration without the user managing the interaction between services manually.
7. **Security and Privacy**: As with any system that handles user data, security, and privacy should be a top priority. Each service should incorporate the latest security protocols to protect user data and ensure privacy. This could include data encryption at rest and in transit, secure access controls, and privacy-preserving computation techniques for services like AI.
8. **Decentralization**: In line with the goal of Project 27, commodity-based services should be decentralized wherever possible. This could involve decentralized networks for storage and computation and blockchain technology for secure, transparent transaction processing.
9. **Sustainability**: Given the energy-intensive nature of many cloud services, sustainability should be a key consideration. This could involve optimizing services for energy efficiency, using renewable energy sources, and incentivizing users to choose more sustainable options.
```mermaid
graph TB
A[User] --> B[Web Interface/APIs]
B --> C[Fleek Network]
C --> D[API Gateway & Encrypted Relay]
D --> E[Commodity/Services]
E -->|Request & Response| F[Compute Service]
E -->|Request & Response| G[Serverless Functions Service]
E -->|Request & Response| H[Storage Service]
E -->|Request & Response| I[AI Service]
E -->|Request & Response| J[GPU Service]
E -->|Request & Response| K[CDN Service]
F --> L[Edge Compute Nodes]
G --> M[Edge Compute Nodes]
H --> N[Decentralized Storage]
I --> O[AI Nodes]
J --> P[GPU Nodes]
K --> Q[Universal Fair Delivery Protocol]
N --> R[IPFS]
N --> S[Filecoin]
N --> T[Arweave]
Q --> U[Gateway Nodes]
Q --> V[Edge Nodes]
Q --> W[Origin Nodes]
Q --> X[Content Providers]
subgraph "Fleek Network"
E; D; C;
end
subgraph "Edge Compute Nodes"
L; M;
end
subgraph "Decentralized Storage"
N; R; S; T;
end
subgraph "User Interface"
B; A;
end
subgraph "Decentralized CDN"
U; V; W; X;
end
subgraph "API Gateway and Encrypted Relay"
D;
end
subgraph "AI & GPU Services"
O; P;
end
subgraph "Commodity/Services"
F; G; H; I; J; K;
end
```
## Challenges and Limitations
### Scalability and performance
Scalability and performance are among the biggest challenges facing Fleek Network. As more users and applications utilize the Network, there is a risk of increased congestion and reduced performance. Additionally, the decentralized nature of the Network can make it more challenging to scale up and maintain performance compared to centralized systems.
To address these challenges, Fleek Network will need to continue to invest in its infrastructure and explore new approaches for scaling and optimizing performance. This may include leveraging new technologies, such as sharding or off-chain scaling solutions, or developing more efficient algorithms and data storage and processing protocols. It will also require close collaboration with developers and users to understand their needs and improve the Network's user experience.
### Ensuring security and privacy in a decentralized environment
Ensuring security and privacy in a decentralized environment is a significant challenge for Fleek Network. The peer-to-peer nature of the Network can make it vulnerable to attacks, and ensuring the security of user data and transactions is crucial. Additionally, privacy is a concern, as data stored on the Network is distributed across several nodes, making it difficult to ensure complete privacy.
To address these challenges, Fleek Network must implement robust security and privacy measures, such as encryption and authentication protocols. Additionally, the Network must be designed with privacy to ensure that user data is not vulnerable to attacks or breaches.
### Adopting cloudless computing in traditional industries
Adopting cloudless computing in traditional industries poses a significant challenge and limitation for Fleek Network. Many industries rely on traditional cloud computing infrastructure for data processing and storage. These industries may hesitate to adopt decentralized computing due to security, reliability, and compliance concerns.
Furthermore, transitioning to a cloudless computing environment may require significant changes to existing infrastructure and workflows, which can be costly and time-consuming. Fleek Network must address these concerns and provide clear benefits and incentives for traditional industries to adopt decentralized computing solutions.
However, the potential benefits of cloudless computing, such as increased security and privacy, lower costs, and greater flexibility, make it an attractive option for many industries. As the technology behind Fleek Network and other decentralized computing solutions mature, we may see greater adoption in traditional sectors.
## Conclusion
### Recap of the key points
Fleek Network is a decentralized cloud and edge computing platform that leverages global spare computing power to provide a more cost-effective and scalable computing infrastructure. Its use of IPFS and Filecoin for decentralized storage and edge compute nodes for distributed computing offers a strong foundation for building decentralized applications and content delivery networks.
While Fleek Network has the potential to improve how we compute and store data, it also faces scalability, security, and adoption challenges in traditional industries. Addressing these challenges will require ongoing innovation and collaboration within the technology community.
### The potential impact of Fleek Network on the future of computing
Fleek Network represents a promising shift towards cloudless computing and the growth of the decentralized web. By joining the movement, developers, and users can help shape the future of computing and build a more open, transparent, and decentralized internet.
## Appendix
```mermaid
graph TD
subgraph User Browser
UA[User Action]
end
subgraph Fleek Network
subgraph Gateway Service
G1[HTTP Request] --> MR[Main Runtime]
MR --> UR[User Runtime]
UR --> G2[HTTP Response]
end
subgraph Cron Service
C1[Cron Job Definition] --> C2[Cron Job Scheduler] --> C3[Task Executor]
C3 --> G1
end
subgraph Storage Service
IPFS
Filecoin
end
end
subgraph External Services
ES1
ES2
end
UA --> G1
G2 --> UA
G1 --> ES1
G1 --> ES2
```
To extend this implementation to support server-side rendering (SSR), you would need to integrate an HTTP server and handle incoming requests by executing the JavaScript code that generates the HTML content on the server side.
```mermaid
graph TD
subgraph User
A[Client] -->|HTTP Request| B(Request Router)
end
subgraph Fleek Network
B(Request Router) -->|HTTP Request| C{Reverse Proxy}
C -->|SSR Request| D(SSR Function)
D -->|HTML Response| C
C -->|JSON Request| E(Edge Function)
E -->|JSON Response| C
C -->|Cache Hit| F{Cache Layer}
F -->|HTML Response| C
F -->|Cache Miss| D
end
subgraph Server
C -->|HTTP Response| A
end
```
Gateway proxy:
```mermaid
graph TB
User("User")
CLI("CLI")
HTTP_Proxy("HTTP Proxy")
SSR_Handler("SSR Handler")
Cron_Job_Manager("Cron Job Manager")
API_Handler("API Handler")
JsRuntime("JsRuntime")
User_Function("User Function")
User --> CLI
CLI -->|Input command| HTTP_Proxy
CLI -->|Schedule cron job| Cron_Job_Manager
HTTP_Proxy -->|Initialize runtime| JsRuntime
JsRuntime -->|Load user function| User_Function
User -->|Send HTTP request| HTTP_Proxy
HTTP_Proxy -->|Forward request| API_Handler
API_Handler -->|Call API function| User_Function
User_Function -->|Return API response| API_Handler
API_Handler -->|Forward API response| HTTP_Proxy
HTTP_Proxy -->|Send API response| User
User -->|Request SSR page| SSR_Handler
SSR_Handler -->|Call SSR function| User_Function
User_Function -->|Return rendered HTML| SSR_Handler
SSR_Handler -->|Send rendered HTML| User
CLI -->|Schedule cron job| Cron_Job_Manager
Cron_Job_Manager -->|Execute cron job function| User_Function
User_Function -->|Return cron job result| Cron_Job_Manager
Cron_Job_Manager -->|Report cron job result| CLI
```
```mermaid
sequenceDiagram
participant User
participant CLI
participant HTTP Proxy
participant SSR Handler
participant Cron Job Manager
participant API Handler
participant JsRuntime
participant User Function
User->>CLI: Input command (e.g. start, deploy, cron)
CLI->>HTTP Proxy: Forward command (e.g. start)
HTTP Proxy->>JsRuntime: Initialize runtime
JsRuntime->>User Function: Load user function
User->>HTTP Proxy: Send HTTP request
HTTP Proxy->>API Handler: Forward request
API Handler->>User Function: Call API function
User Function->>API Handler: Return API response
API Handler->>HTTP Proxy: Forward API response
HTTP Proxy->>User: Send API response
User->>SSR Handler: Request SSR page
SSR Handler->>User Function: Call SSR function
User Function->>SSR Handler: Return rendered HTML
SSR Handler->>User: Send rendered HTML
CLI->>Cron Job Manager: Schedule cron job
Cron Job Manager->>User Function: Execute cron job function at specified interval
User Function->>Cron Job Manager: Return cron job result
Cron Job Manager->>CLI: Report cron job result
```
```mermaid
```
## Refernces
## Github
[Ursa Runtime](https://github.com/fleek-network/project27)