Skip to content

Conversation

@vjsingh1984
Copy link
Contributor

@vjsingh1984 vjsingh1984 commented Feb 8, 2026

Summary

Add support for 10-minute bars (Min10) to the BarSize enum in the historical data module.

Changes

  • Add Min10 variant to BarSize enum
  • Display format: 10 mins
  • FromStr parsing: MIN10 to BarSize Min10
  • Add test coverage for Min10

Reference

Follows existing pattern for Min5 and Min15 bars.

Resolves #393

Optionally disables Nagle's algorithm on TcpStream when the environment
variable IBAPI_TCP_NODELAY=1 is set. Default behavior is unchanged
(Nagle enabled, matching upstream).

When enabled, small writes (order submissions ~100-200 bytes) are sent
immediately instead of being buffered up to 40ms. For trading systems
this eliminates latency on order routing with zero practical downside.

Usage:
  IBAPI_TCP_NODELAY=1 ./my-trading-app

Affected paths:
- sync: TcpSocket::new() and TcpSocket::reconnect()
- async: AsyncConnection::connect_with_callback() and reconnect()
Adds 10-minute bar size to the BarSize enum for historical data fetching,
matching IBKR TWS/Gateway API support.

Changes:
- Add Min10 variant to BarSize enum (between Min5 and Min15)
- Display format: "10 mins"
- FromStr parsing: "MIN10" → BarSize::Min10
- Update tests to include Min10 coverage

This aligns with the official IBKR API specification which supports
10-minute bars for historical data requests.
@wboayue
Copy link
Owner

wboayue commented Feb 9, 2026

The TCP_NODELAY env var changes conflict with the ConnectionOptions API merged in #394. Squash-merging with only the Min10 bar size change.

@wboayue wboayue merged commit a630c12 into wboayue:main Feb 9, 2026
3 checks passed
@wboayue wboayue mentioned this pull request Feb 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Min10 bar size support

2 participants