ElexonPCLIfrom SopherApps

Details

  • Name ElexonPCLI
  • Summary A commandline app getting realtime data from Elexon, processing it and availing it to other apps in realtime via websockets
  • Price (Monthly) 5,000,000 UGX
  • Free Trial 7 days
  • Category ETL
  • Tags queue elexon bmrs extract
  • Download

Description

ElexonPCLI is a commandline application that makes available in realtime market and system data from the UK Electricity Balancing and Settlement Code (BSC) Systems (Elexon).

It exposes a websocket interface for other applications to get that data in JSON format in realtime.

It also saves the data in a PostgreSQL database in case one is interested in looking at historical data.

Features

  • CLIA fully-fledged CLI app with a help section
  • PostgreSQL persistentElexonPCLI saves the realtime data to a PostgreSQL database as soon as it is received.
  • Durable ConnectionEven when ElexonPCLI is stopped for less than 2 days, on restart, it processes all messages missed.
  • Pub/Sub AbilityElexonPCLI Disperses processed data to an unlimited number of other subscriber apps via Websockets and a simple Websocket URL. These can go on and do extra processing.
  • Automatic UpdatesAt start up, it checks for new updated versions automatically and advises the user to download if there are new versions. It continues to do these checks even when running and alerts the user when new versions are released.
  • Pub/Sub persistenceEven when a subscribing app goes off for a time lower than the 'ttl' flag setting (default 1.5 days), on reconnection, all data it missed would be passed to it.
  • ConfigurableAlmost everything about ElexonPCLI can be reconfigured. However, it comes with sensible defaults to get you running quickly.
  • Available for Major OSBinaries for Linux, Windows and MacOS (Darwin) have been provided.

Quick Start

  • Ensure you have already registered with Elexon's BMRS service so as to have an Elexon Scripting key. Learn more
  • Install PostgreSQL if you don't have it already. If you have a Cloud PostgreSQL instance like Amazon RDS, skip.
  • Install Google Chrome if you don't have it installed. (Any browser can be used but for uniformity of these instructions, we have stuck with Chrome)
  • Install the websocket Chrome extension
  • Download the latest version of the app for your operating system and computer architecture. Note: the commonest architecture is AMD64. That's the one you most probably have
Operating System Architecture Download
Windows AMD64 Download
Windows ARM Download
MacOS AMD64 Download
MacOS ARM64 Download
Linux AMD64 Download
Linux ARM64 Download

If you are interested in older versions, go to the download section

  • Open your terminal (command line). (For Ubuntu hit ctrl-alt-T)
  • Enter the directory where downloaded the app.
  • Run the application.

For Linux/MacOS ( Replace the things that have <> with your own values ):

./elexonpcli run \
    --key <Elexon scripting key> \
    --dbhost <PostgresSQL database host> \
    --dbport <PostgresSQL database port> \
    --dbname <PostgresSQL database name> \
    --dbuser <PostgresSQL database user> \
    --serverport <The computer port to expose the app to subscriber apps> 
    --serverinterval <The Interval for messages to be sent to subscriber apps e.g. 100ms>

For Windows ( Replace the things that have <> with your own values ):

elexonpcli.exe run \
    --key <Elexon scripting key> \
    --dbhost <PostgresSQL database host> \
    --dbport <PostgresSQL database port> \
    --dbname <PostgresSQL database name> \
    --dbuser <PostgresSQL database user> \
    --serverport <The computer port to expose the app to subscriber apps> 
    --serverinterval <The Interval for messages to be sent to subscriber apps e.g. 100ms>

Each of those flags have short forms. You can see these short forms from the help menu e.g. instead of --key, one could use -k

  • Open websocket chrome extension in Google Chrome.
  • Add the URL ws://<IP address>:<computer port ElexonPCLI is running on>?subscriberId=<a subscriber id of your choice> e.g. ws://localhost:8080?subscriberId=testSubscriber to the Server URL input of the websocket chrome extension.

server url input of the websocket chrome extenstion

  • Click the Connect button of the websocket chrome extension

connect button of the websocket chrome extenstion

  • Watch as the messages are displayed in the messages output section of the websocket chrome extension

messages output of the websocket chrome extenstion

  • Inorder to limit the message types received, you can modify the websocket URL used to ws://<IP address>:<computer port ElexonPCLI is running on>?subscriberId=<a subscriber id of your choice>&messages=<comma separated list of message types> e.g. ws://localhost:8080?subscriberId=testSubscriber&messages=BOD,MELS,MILS,PN
  • To stop the application, hit Ctrl-C in the terminal (commandline) ElexonPCLI is running from
  • To view the help menu instead of running the app, you can run the help command

For Linux/MacOS:

./elexonpcli run --help

For Windows:

elexonpcli.exe run --help
  • When your trial period ends, your application will be unable to run but instead will ask you to pay for a license. Please follow the prompts and apy for that license. Your payment is vital to allow SopherApps team to continue improving the ElexonPCLI app.
Gotchas
  • Do note that this CLI can't be safely run in say systemd because it requires terminal interruction
  • Run it in a screen
 screen -S elexonpcli
elexonpcli run # etc...
  • Then detach them with Ctrl-A-D

Downloads