Skip to content

Commit

Permalink
docs: cleanup readme
Browse files Browse the repository at this point in the history
  • Loading branch information
krisselden committed Oct 17, 2019
1 parent da86aae commit eda3561
Showing 1 changed file with 86 additions and 56 deletions.
142 changes: 86 additions & 56 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,64 +2,94 @@

Serves recorded response sets for benchmarking.

The goal is to serve recorded responses with low variance in memory and CPU cost.

## Building

Follow the instructions at https://rustup.rs.

As of this writing, tracerbench-serve requires the latest Rust beta.

```sh
rustup toolchain install beta
```

```sh
cargo build --release
```

## recorded response set

Serde deserialize format:

Recorded response sets
Seq (len 6)
Body table
Header name table
Header value table
Headers table
Response table
Recorded response set table

Body table:
Seq of
Bytes

Header name table:
Seq of
String

Header value table:
Seq of
String

Headers table
Seq of
Seq of
(
usize, // name table index
usize, // value table index
)

Response table
Seq of
(
u16, // status
usize, // headers table index
Option<usize>, // body table index
)

Response set table
Seq of
Map
socksPort: u16,
name: String,
entryKey: String,
requestKeyProgram: Request key,
requestKeyMap:
Map String: usize // key to response_index

Request key
Seq
literals
Bytes

literals
Map
type: String,
content: Value
### Recorded response sets:

- Seq length 6
- Body table
- Header name table
- Header value table
- Headers table
- Response table
- Recorded response set table

### Body table:

- Seq of
- Bytes

### Header name table:

- Seq of
- String

### Header value table:

- Seq of
- String

### Headers table

- Seq of
- Seq of
- Seq length 2
- usize ( name table index )
- usize ( value table index )

### Response table

- Seq of
- Seq length 3
- u16 ( status )
- usize ( headers table index )
- Option<usize> ( body table index )

### Response set table

- Seq of
- Map
- socksPort:
- u16
- name:
- String
- entryKey:
- String
- requestKeyProgram:
- Request key
- requestKeyMap:
- Map
- String: ( request key )
- usize ( response_index )

### Request key

- Seq length 2
program literals
Bytes (program bytecode)

#### program literals

- Map
- type:
- String
- content:
- Value

0 comments on commit eda3561

Please sign in to comment.