10 releases (stable)

1.4.2 Dec 27, 2023
1.4.0 Aug 20, 2023
1.0.0 Jun 25, 2022
0.1.3 Jun 24, 2022

#253 in Web programming

Download history 12/week @ 2023-10-25 17/week @ 2023-11-01 7/week @ 2023-11-08 17/week @ 2023-11-15 20/week @ 2023-11-22 23/week @ 2023-11-29 18/week @ 2023-12-06 17/week @ 2023-12-13 14/week @ 2023-12-20 56/week @ 2023-12-27 18/week @ 2024-01-03 7/week @ 2024-01-10 14/week @ 2024-01-17 20/week @ 2024-01-24 18/week @ 2024-01-31 8/week @ 2024-02-07

61 downloads per month
Used in summer-boot-macro

Apache-2.0

165KB
4K SLoC

Summer Boot

Bors enabled FOSSA Status

The next generation decentralized web framework allows users to manage and share their own data. It will be a wide area and cross regional web framework.

summer_boot::log Logger started
summer_boot::log 
    _____                                       ____              _   
   / ____|                                     |  _ \            | |  
  | (___  _   _ _ __ ___  _ __ ___   ___ _ __  | |_) | ___   ___ | |_ 
   \___ \| | | | '_ ` _ \| '_ ` _ \ / _ \ '__| |  _ < / _ \ / _ \| __|
   ____) | |_| | | | | | | | | | | |  __/ |    | |_) | (_) | (_) | |_ 
  |_____/ \__,_|_| |_| |_|_| |_| |_|\___|_|    |____/ \___/ \___/ \__|
                                                                      
  :: Summer Boot Version::             (1.4.2)                                                                    
 
summer_boot::web2::server::server Server listening on http://0.0.0.0:8080

Quick Start

Cargo.toml:

summer-boot = "1.4.2"

Add resuorce configuration file to src directory

src/resources/application.yml

profiles:
  active: test

src/resources/application-test.yml

server:
  port: 8080

src/main.rs

use serde::Deserialize;
use summer_boot::{Request, Result};
use summer_boot::log;

#[derive(Debug, Deserialize)]
struct User {
    name: String,
    age: u16,
}

#[summer_boot::auto_scan]
#[summer_boot::main]
async fn main() {
    summer_boot::run();
}

#[summer_boot::post("/test/api")]
async fn test_api(mut req: Request<()>) -> Result {
    let User { name, age } = req.body_json().await?;
    Ok(format!("Hello, {}!  {} years old", name, age).into())
}

License

Licensed under either of

FOSSA Status

Dependencies

~12–27MB
~403K SLoC