Skip to content

Commit

Permalink
refactor: rename the runtimes-manager crate to project (#150)
Browse files Browse the repository at this point in the history
* refactor: rename the runtimes-manager crate to project

* fix: update crates/project/README.md

Co-authored-by: Rafael Fernández López <[email protected]>

---------

Co-authored-by: Rafael Fernández López <[email protected]>
  • Loading branch information
Angelmmiguel and ereslibre authored Jun 1, 2023
1 parent b63e769 commit e2faca4
Show file tree
Hide file tree
Showing 13 changed files with 34 additions and 31 deletions.
36 changes: 18 additions & 18 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ prettytable-rs = "0.10.0"
wws-config = { workspace = true }
wws-router = { workspace = true }
wws-server = { workspace = true }
wws-runtimes-manager = { workspace = true }
wws-project = { workspace = true }

[dev-dependencies]
reqwest = { version = "0.11", features = ["blocking"] }
Expand All @@ -46,9 +46,9 @@ openssl = { version = "=0.10.48", features = ["vendored"] }
members = [
"crates/config",
"crates/data-kv",
"crates/project",
"crates/router",
"crates/runtimes",
"crates/runtimes-manager",
"crates/server",
"crates/store",
"crates/worker",
Expand All @@ -73,12 +73,12 @@ serde_json = "1.0.85"
toml = "0.7.0"
wws-config = { path = "./crates/config" }
wws-runtimes = { path = "./crates/runtimes" }
wws-runtimes-manager = { path = "./crates/runtimes-manager" }
wws-data-kv = { path = "./crates/data-kv" }
wws-router = { path = "./crates/router" }
wws-server = { path = "./crates/server" }
wws-store = { path = "./crates/store" }
wws-worker = { path = "./crates/worker" }
wws-project = { path = "./crates/project" }
wasmtime = "6.0.2"
wasmtime-wasi = "6.0.2"
wasi-common = "6.0.2"
2 changes: 1 addition & 1 deletion crates/config/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ anyhow = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
toml = { workspace = true }
wws-runtimes-manager = { workspace = true }
wws-project = { workspace = true }
2 changes: 1 addition & 1 deletion crates/config/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ use std::{
fs,
path::{Path, PathBuf},
};
use wws_runtimes_manager::{check_runtime, metadata::Runtime};
use wws_project::{check_runtime, metadata::Runtime};

/// Default repository name
pub const DEFAULT_REPO_NAME: &str = "wasmlabs";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[package]
name = "wws-runtimes-manager"
name = "wws-project"
version = { workspace = true }
edition = { workspace = true }
authors = { workspace = true }
Expand All @@ -14,4 +14,4 @@ toml = { workspace = true }
wws-store = { workspace = true }
url = "2.3.1"
sha256 = "1.1.1"
reqwest = "0.11"
reqwest = "0.11"
5 changes: 5 additions & 0 deletions crates/project/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Wasm Workers Server / Project crate

The purpose of this create is to prepare the worker project before we proceed identifying the routes and preparing the individual workers. It's in charge of locating the project locally, pulling it from a supported remote and storing it in a place that it's accessible for `wws`.

It also downloads the required runtimes to run the given project.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion crates/router/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ doctest = false
[dependencies]
wws-config = { workspace = true }
wws-store = { workspace = true }
wws-runtimes-manager = { workspace = true }
wws-project = { workspace = true }
wws-worker = { workspace = true }
lazy_static = "1.4.0"
regex = "1"
Expand Down
2 changes: 1 addition & 1 deletion crates/runtimes/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ serde_json = { workspace = true }
wasmtime-wasi = { workspace = true }
wws-config = { workspace = true }
wws-store = { workspace = true }
wws-runtimes-manager = { workspace = true }
wws-project = { workspace = true }
2 changes: 1 addition & 1 deletion crates/runtimes/src/modules/external.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use std::{
path::{Path, PathBuf},
};
use wasmtime_wasi::{ambient_authority, Dir, WasiCtxBuilder};
use wws_runtimes_manager::metadata::Runtime as RuntimeMetadata;
use wws_project::metadata::Runtime as RuntimeMetadata;
use wws_store::Store;

/// Run language runtimes that were downloaded externally. This
Expand Down
4 changes: 1 addition & 3 deletions src/commands/runtimes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,7 @@ use clap::{Args, Parser, Subcommand};
use prettytable::{format, Cell, Row, Table};
use std::env;
use wws_config::Config;
use wws_runtimes_manager::{
check_runtime, install_runtime, metadata::Repository, uninstall_runtime,
};
use wws_project::{check_runtime, install_runtime, metadata::Repository, uninstall_runtime};

/// Default repository name
pub const DEFAULT_REPO_NAME: &str = "wasmlabs";
Expand Down

0 comments on commit e2faca4

Please sign in to comment.