Quick Start
This guide will walk you through downloading, compiling, and running a flow trading server. Basic familiarity with a command-line, bash-like shell is assumed.
This guide assumes that the reader has both CMake and Rust >= 1.8.5 installed on their computer.
- CMake can be downloaded directly or installed via your system’s packaging utility, e.g.
brew install cmake
orapt-get install cmake
. - Rust can be installed via Rustup.
If both which cmake
and which cargo
return a path, your system is ready for the next step.
Downloading and Installing
Section titled “Downloading and Installing”The demonstration server is available directly from crates.io, or can be built from source cloning our repository.
Option 1: Install Directly
Section titled “Option 1: Install Directly”The following command will download and compile the latest release of the flow trading demonstration server:
cargo install ftdemo
Option 2: Build from Repository
Section titled “Option 2: Build from Repository”# Clone the repository if necessarygit clone https://github.com/forward-market-design/flow-trading-service.gitcd flow-trading-service
# Compile and run the demonstration servercargo build --release --bin ftdemo
Running the Server
Section titled “Running the Server”Either option above will download the project dependencies and build the software. To launch a server, run
ftdemo --api-secret SECRET --trade-rate 1h --schedule-every 30s
This will run the server on the default port 8080 and schedule an auction for every 30 seconds. The OpenAPI schema can be explored at http://localhost:8080/rapidoc if the server is successfully running. A Dockerfile is also available to build and run the binary.
The available configuration options are available via ftdemo --help
and are discussed in the project README.
Next Steps
Section titled “Next Steps”It is recommended to walkthrough a simple trading session to gain basic familiarity with the server architecture and a high-level understanding of the bid language.