Skip to content

jh-plask/rust_trader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🦀 Rust Trader 💰

Rust Trader is a high-performance financial trading system implemented in Rust. It leverages Rust's memory safety guarantees and concurrency features, along with the Tokio runtime for efficient concurrent execution, to provide a reliable and efficient trading system.

Project Structure

The project is organized into several modules:

  • src/descriptor/domain_entity.rs: This file contains the definitions for the domain entities used in the trading system. These entities represent the core business objects in the system, such as orders and trades.

  • src/descriptor/domain_logic.rs: This file contains the business logic related to the domain entities. This includes the rules for order execution, trade matching, and other core trading operations.

  • src/descriptor/system_entity.rs: This file contains the definitions for the system entities used in the trading system. These entities represent the infrastructure components of the system, such as the order book and the market data connector.

  • src/descriptor/system_logic.rs: This file contains the logic related to the system entities. This includes the algorithms for order routing, market data processing, and other system-level operations.

  • src/main.rs: This is the entry point of the application. It sets up the trading system and starts the main event loop.

Key Features

  • Parallel Execution: Rust Trader uses the Tokio runtime for efficient concurrent execution. This allows it to handle multiple orders and trades simultaneously, improving overall system performance.

  • Graph-based Order Chain: The OrderExecutor struct in system_entity.rs is responsible for executing orders. It uses a directed acyclic graph (DAG) to represent the dependencies between orders, allowing for efficient execution of complex order strategies.

  • Market Data Connection: The MarketDataConnector struct in system_entity.rs is responsible for connecting to the market data feed. It uses WebSockets to receive real-time market data updates.

  • Notification Service: The NotificationService struct in system_entity.rs is responsible for sending notifications. It uses a Slack webhook to send messages to a specified Slack channel.

How to Run

To run the project, navigate to the rust_trader directory and use the cargo run command:

cd rust_trader
cargo run

How to Test

To run the tests for the project, use the cargo test command:

cargo test

Contributions

Contributions to Rust Trader are welcome! Please submit a pull request or create an issue to discuss any changes you'd like to make.

License

Rust Trader is licensed under the MIT License.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages