Skip to content

Commit efc4ca9

Browse files
committed
Top level docs for swimos_remote.
1 parent 1aeccf9 commit efc4ca9

File tree

2 files changed

+18
-1
lines changed

2 files changed

+18
-1
lines changed

runtime/swimos_remote/src/lib.rs

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,25 @@
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
1414

15+
//! # SwimOS Transport Layer
16+
//!
17+
//! This crate provides the transport layer for SwimOS (bidirectional web-socket connections over
18+
//! TCP sockets). It consists of:
19+
//!
20+
//! - An abstraction over DNS to allow for the resolution of remote hosts of Swim agents.
21+
//! - A networking abstraction with basic implementation for unencrypted traffic over TCP sockets.
22+
//! - An optional implementation of the networking abstraction using TLS encryption.
23+
//! - Bindings to use the [`ratchet`] web-socket library on top of the networking abstraction.
24+
//! - A Tokio task to manage a bidirectional web-socket and handle communication with the core SwimOS runtime.
25+
26+
/// DNS support for resolving remote hosts.
1527
pub mod dns;
1628
mod net;
29+
30+
/// Basic networking support, without TLS support.
1731
pub mod plain;
1832
mod task;
33+
/// Networking support with TLS provided by the [`rustls`] crate.
1934
#[cfg(feature = "tls")]
2035
pub mod tls;
2136
mod ws;
@@ -27,11 +42,13 @@ pub use net::{
2742
ListenerError, ListenerResult, Scheme, SchemeHostPort, ServerConnections,
2843
};
2944

45+
/// Bindings to use the [`ratchet`] web-sockets crate with the networking abstraction in this crate.
3046
pub mod websocket {
3147

3248
pub use super::ws::{
3349
RatchetClient, RatchetError, WebsocketClient, WebsocketServer, Websockets, WsOpenFuture,
3450
};
3551

52+
/// The name of the Warp protocol for negotiation web-socket connections.
3653
pub const WARP: &str = "warp0";
3754
}

server/swimos_server_app/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ authors = ["Swim Inc. developers info@swim.ai"]
55
edition = "2021"
66

77
[features]
8-
default = ["rocks_store"]
8+
default = []
99
rocks_store = ["swimos_rocks_store"]
1010
trust_dns = ["swimos_runtime/trust_dns"]
1111

0 commit comments

Comments
 (0)