Skip to content

Commit

Permalink
release: airup v0.10.7
Browse files Browse the repository at this point in the history
  • Loading branch information
sisungo committed Aug 25, 2024
1 parent c98ce58 commit f981e6b
Show file tree
Hide file tree
Showing 17 changed files with 38 additions and 21 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
Changes in v0.10.7:
* Feature: Support of notify-styled watchdogs.
* Few minor bug fixes.

Changes in v0.10.6:
* BREAKING: Extensions now uses the registering connection, rather than listen to a new UNIX socket and let the daemon connect.
* BREAKING: Service sideloading is now a part of the supervisor cache system.
Expand Down
4 changes: 2 additions & 2 deletions SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

## Supported Versions
The `HEAD` and the latest release are supported by the Airup developers. The maintained versions are:
- Mainline: `0.10.6`
- Stable: `0.10.6`
- Mainline: `0.10.7`
- Stable: `0.10.7`

## Reporting a Vulnerability
Please [contact @sisungo](mailto:[email protected]) to report a vulnerability.
2 changes: 1 addition & 1 deletion airup-sdk/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ authors = ["sisungo <[email protected]>"]
description = "SDK library of Airup"
documentation = "https://docs.rs/airup-sdk"
repository = "https://github.com/sisungo/airup"
version = "0.10.6"
version = "0.10.7"
edition = "2021"
license = "MIT"

Expand Down
2 changes: 1 addition & 1 deletion airup-sdk/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//! # The Airup SDK
//! The Airup SDK provides interface to deal with Airup elements, for example, interacting with the daemon, `airupd`.
//! The Airup SDK provides interface to access Airup facilities, for example, interacting with the daemon, `airupd`.

pub mod build;
pub mod debug;
Expand Down
2 changes: 1 addition & 1 deletion airup/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "airup"
authors = ["sisungo <[email protected]>"]
version = "0.10.6"
version = "0.10.7"
edition = "2021"
license = "MIT"
publish = false
Expand Down
2 changes: 1 addition & 1 deletion airup/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! # Airup CLI
//! Command-line utility for accessing Airup facilities.

mod daemon;
mod debug;
Expand Down
2 changes: 1 addition & 1 deletion airupd/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "airupd"
authors = ["sisungo <[email protected]>"]
version = "0.10.6"
version = "0.10.7"
edition = "2021"
license = "MIT"
publish = false
Expand Down
8 changes: 4 additions & 4 deletions airupd/src/app.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ pub struct Airupd {
/// The extension manager.
pub extensions: extension::Extensions,

/// The IPC context.
pub ipc: rpc::Context,
/// The RPC context.
pub rpc: rpc::Context,

/// The lifetime manager of the `airupd` process.
pub lifetime: lifetime::System,
Expand Down Expand Up @@ -76,7 +76,7 @@ impl Airupd {
});

_ = signal::signal(SIGHUP, |_| async {
self.ipc.reload();
self.rpc.reload();
});
}

Expand Down Expand Up @@ -107,7 +107,7 @@ pub async fn init() {
let object = Airupd {
storage: storage::Storage::new().await,
extensions: extension::Extensions::new(),
ipc: rpc::Context::new(),
rpc: rpc::Context::new(),
lifetime: lifetime::System::new(),
milestones: milestones::Manager::new(),
supervisors: supervisor::Manager::new(),
Expand Down
2 changes: 1 addition & 1 deletion airupd/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! # airupd
//! The Airup daemon.

mod ace;
mod app;
Expand Down
6 changes: 3 additions & 3 deletions airupd/src/rpc/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ impl Default for Context {
}
}

/// Represents to an IPC server.
/// Represents to an RPC server.
#[derive(Debug)]
pub struct Server {
path: PathBuf,
Expand Down Expand Up @@ -72,7 +72,7 @@ impl Server {

/// Runs the server in place.
async fn run(&mut self) {
let mut reload = airupd().ipc.reload.subscribe();
let mut reload = airupd().rpc.reload.subscribe();

loop {
tokio::select! {
Expand Down Expand Up @@ -120,7 +120,7 @@ impl Session {
.rpc_invoke(Request::new::<&str, ciborium::Value, _>(method, req.params))
.await
}
None => airupd().ipc.api.invoke(req).await,
None => airupd().rpc.api.invoke(req).await,
};
self.conn.send(&resp).await?;
}
Expand Down
2 changes: 1 addition & 1 deletion airupfx/airupfx-extensions/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//! # AirupFX Extension Framework
//! This crate provides a high-level framework for writing Airup extensions in Rust easily.
//! This crate provides a high-level framework for writing Airup extensions in async Rust easily.

use airup_sdk::{
info::ConnectionExt,
Expand Down
2 changes: 2 additions & 0 deletions airupfx/airupfx-io/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
//! IO toolkit.

pub mod line_piper;

pub use line_piper::LinePiper;
9 changes: 7 additions & 2 deletions airupfx/airupfx-io/src/line_piper.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
//! A cancel-safe solution for reading lines from a stream.

use std::{future::Future, pin::Pin};
use tokio::{
io::{AsyncRead, AsyncReadExt},
Expand Down Expand Up @@ -40,8 +42,11 @@ impl Drop for LinePiper {
}

/// Sets up a line piper and sets a callback for it. The line piper is automatically closed when stream `reader` reached EOF.
pub fn set_callback(reader: impl AsyncRead + Unpin + Send + 'static, callback: Box<dyn Callback>) {
LinePiperEntity::new(reader, callback).start();
pub fn set_callback(
reader: impl AsyncRead + Unpin + Send + 'static,
callback: Box<dyn Callback>,
) -> JoinHandle<()> {
LinePiperEntity::new(reader, callback).start()
}

struct LinePiperEntity<R> {
Expand Down
4 changes: 4 additions & 0 deletions airupfx/airupfx-isolator/src/fallback.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
//! A fallback isolator implementation that does no-op for all operations.
//!
//! This is useful for compatibility with operating systems that support no isolators.

#[derive(Debug)]
pub struct Realm;
impl Realm {
Expand Down
2 changes: 2 additions & 0 deletions airupfx/airupfx-isolator/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
//! Utilities for handling resource isolation.

cfg_if::cfg_if! {
if #[cfg(all(target_os = "linux", feature = "cgroups"))] {
#[path = "linux.rs"]
Expand Down
2 changes: 1 addition & 1 deletion airupfx/airupfx-process/src/unix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ impl ExitStatusExt for ExitStatus {
macro_rules! map_stdio {
($fx:expr, $std:expr) => {
match &$fx {
Stdio::Callback(c) => line_piper::set_callback($std, c.clone_boxed()),
Stdio::Callback(c) => _ = line_piper::set_callback($std, c.clone_boxed()),
_ => (),
}
};
Expand Down
4 changes: 2 additions & 2 deletions extensions/fallback-logger/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//! A simple logger for fallback use.
//!
//! This has some limitations and has poor performance. Being designed as an "fallback choice", the implementation aims to be
//! small.
//! This has some limitations and has poor performance. Being designed as a "fallback choice", the implementation aims to be
//! small and simple.

use airup_sdk::{blocking::fs::DirChain, system::LogRecord, Error};
use airupfx::extensions::*;
Expand Down

0 comments on commit f981e6b

Please sign in to comment.