Server pluginExposure and abusev1.1.09 options Live demo

Gap Position Locker

Locks or closes open positions automatically when a session reopens with a large price gap, using an O(1) position cache and confirmed actions.

Get a licenseDownload

What it does

9 capabilities
  • Detects bid or ask price gaps in percent after a configurable quote pause
  • O(1) quote-thread detection using an incremental position cache
  • Modes: lock_net (default), lock_each, close, and alert_only
  • Persists last quotes and locked tickets across weekend restarts
  • Tagged dealer actions with automatic retry when pre-open ticks refuse
  • Spread guard (max_spread_points) and multi-tick gap confirmation
  • Optional only_losing_side filter for directional gap protection
  • Excludes LP or house logins via exclude_logins plus group and symbol masks
  • Alerts and writes every action to the gap_locks report

How it works

Markets that close overnight or over the weekend can reopen far from the last price. Gap Position Locker watches incoming bid and ask quotes on an O(1) path without scanning server positions on the quote thread. When quotes resume after min_pause_seconds with a move of at least gap_percent, optional confirm_ticks consecutive confirmations, and spread within max_spread_points, the plugin protects eligible accounts using the chosen mode: lock_net locks each account's net exposure per symbol to prevent over-hedging, lock_each hedges every open position individually, close exits exposed positions, and alert_only reports without trading. Supports only_losing_side filtering, exclude_logins for LP or house accounts, persisted last quotes and locks across weekend restarts, and tagged dealer actions with automatic retry on pre-open market-closed refusals.

Parameters & options

Configured directly in MetaTrader 5 Administrator and testable live in the simulator.

12 of 12
ParameterTypeDefaultDescription
symbols
text*Symbols watched, comma separated; wildcards and ! exclusions allowed, for example US500*,XAUUSD,!XAUUSD.raw. * means all
gap_percent
number3.00Smallest price move between two quotes that counts as a gap, in percent (two decimals)
min_pause_seconds
int3600Seconds without quotes before the gap, at least. 0: any gap counts
groups
group mask*Client groups whose positions are locked (MT5 group mask). * means all
mode
textlock_netAction on gap: lock_net (hedge net exposure per account), lock_each (hedge every ticket), close (close open positions), or alert_only
exclude_logins
textemptyLogins never locked, closed, or alerted (for example LP or house accounts), separated by commas
max_spread_points
int0Maximum tick spread in points allowed to execute a gap action; wider spreads wait. 0: no limit
confirm_ticks
int1Consecutive ticks remaining at or beyond gap_percent before acting (1 to 100)
only_losing_side
bool01: act only on positions losing from the gap direction (sells on gap up, buys on gap down). 0: act on both sides
license_key
System
textemptyLicense key from FXOpsPro, for example FXO-XXXXX-XXXXX-XXXXX-XXXXX-XXXXX
license_server
System
texthttps://plugins.fxopspro.comLicense server address
dealer_login
System
int0Manager login with dealer rights that closes or opens positions for the plugin. 0: the plugin only logs

Release history

  1. v1.1.0Latest2026-11-24

    O(1) incremental position cache off the quote thread, persisted quotes across weekend restarts, tagged dealer open/close with retry, out-of-order and ask-gap handling, plus mode (lock_net/lock_each/close/alert_only), exclude_logins, max_spread_points, confirm_ticks, and only_losing_side.

Exposure and abuse

View all server plugins