Skip to content

Commit

Permalink
next order id from server (#192)
Browse files Browse the repository at this point in the history
  • Loading branch information
wboayue authored Dec 10, 2024
1 parent fe67f9b commit e9e230d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "ibapi"
version = "1.0.4"
version = "1.0.5"
edition = "2021"
authors = ["Wil Boayue <[email protected]>"]
description = "A Rust implementation of the Interactive Brokers TWS API, providing a reliable and user friendly interface for TWS and IB Gateway. Designed with a focus on simplicity and performance."
Expand Down
2 changes: 1 addition & 1 deletion src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ impl Client {
message_bus,
client_id: connection_metadata.client_id,
next_request_id: AtomicI32::new(9000),
order_id: AtomicI32::new(1000),
order_id: AtomicI32::new(connection_metadata.next_order_id),
};

Ok(client)
Expand Down
2 changes: 1 addition & 1 deletion src/transport.rs
Original file line number Diff line number Diff line change
Expand Up @@ -780,7 +780,7 @@ impl SubscriptionBuilder {

#[derive(Default, Clone, Debug)]
pub(crate) struct ConnectionMetadata {
next_order_id: i32,
pub(crate) next_order_id: i32,
pub(crate) client_id: i32,
pub(crate) server_version: i32,
pub(crate) managed_accounts: String,
Expand Down

0 comments on commit e9e230d

Please sign in to comment.