roq-journal#

Purpose#

  • Database proxy.

  • Used to persist (cache) state from gateways.

  • The multicast/UDP communication protocol supports distributed deployment such that any number of proxies can each persist (and de-duplicate) updates thereby favouring speed.

  • Messages are persisted to local filesystem to support redundancy and recovery.

Specifically designed to support low-latency persistence of client order-id mappings (routing_id) as required by some FIX use-cases.

Conda#

$ mamba install \
  --channel https://roq-trading.com/conda/stable \
  roq-journal
$ roq-journal \
      --name "journal-1"

Flags#

$ roq-journal --help

--name

Service name.

    • --multicast_port

    • Multicast port.

    • --multicast_address

    • Multicast address (IPv4).

    • --local_interface

    • Local interface (IPv4).

--database_uri

Database URI.

--database_username

Database username.

--database_password

Database password.

--database_name

Database name.

--database_create

Create database?

--database_request_timeout

Database request timeout, e.g. 5s

--database_ping_freq

Database ping frequency, e.g. 30s

--database_ping_path

Database ping path

--database_retain_for

For how long (since most recent update time) should cache files be retained for?

    • --cache_dir

    • Cache directory.

    • --cache_datasync

    • Issue a filesystem datasync for certain messages?

    • --cache_datasync_before_respond

    • Issue the filesystem datasync before responding?

    • --cache_retain_for

    • For how long (since creation -time) should cache files be retained for?

--loop_timer

Timer frequency, e.g. 2000ns.

--loop_sleep

Sleep time, e.g. 500ns.