1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
//! <img src="https://raw.githubusercontent.com/sevki/jetstream/main/logo/JetStream.png" style="width: 200px">
//!
//! # JetStream
//! [](https://crates.io/crates/jetstream) [](https://docs.rs/jetstream) <!--gh actions-->   [](https://crates.io/crates/jetstream)
//!
//!
//! JetStream is an RPC framework built on top of [s2n-quic](https://crates.io/crates/s2n-quic) and [p9](https://crates.io/crates/p9). It's designed to be a high performance, low latency, secure, and reliable RPC framework.
//!
//! Features:
//!
//! - Bidirectional streaming
//! - 0-RTT
//! - [mTLS](https://github.com/aws/s2n-quic/tree/main/examples/s2n-mtls)
//! - binary encoding
//!
//! ## Motivation
//!
//! Building remote filesystems over internet, is the main motivation behind JetStream.
//!
//! ## Ready?
//!
//! JetStream is not ready for production use. It's still in the early stages of development.
//!
//! ## Alternatives
//!
//! - [grpc](https://grpc.io/)
//! - [capnproto](https://capnproto.org/)
//! - [thrift](https://thrift.apache.org/)
//! - [jsonrpc](https://www.jsonrpc.org/)
//! - [tarpc](https://crates.io/crates/tarpc)
//!
//! ## [License](../LICENSE)
//!
//! BSD-3-Clause
extern crate jetstream_wire_format_derive;
pub use JetStreamWireFormat;
pub use ;
/// This macro generates a JetStream protocol implementation from a module
/// such as the following
///
/// ```rust
/// use jetstream::JetStreamWireFormat;
/// use async_trait::async_trait;
/// use jetstream::protocol;
//
/// #[protocol]
/// mod radar {
/// #[derive(JetStreamWireFormat)]
/// pub struct Version {
/// pub msize: u32,
/// pub version: String,
/// }
/// #[async_trait::async_trait]
/// pub trait Radar {
/// async fn version(&mut self, req: Version) -> Version;
/// fn ping(&mut self) -> u8;
/// }
/// }
/// ```
///
/// This will generate an async `Radar` trait with a `version` and `ping` methods.
///
///
pub use protocol;
pub use ;
pub use Message;