Saturday, 4 April 2020

NOTAMS Service Update

In these strange and worrying times, flying is rightly on the back-burner. But one upside of the down-time is the opportunity to get some odd jobs done. So, I'm pleased to say that I've managed to tick off one important item from that "To Do" list -- namely, I've migrated the NOTAMS service from AIDAP to SWIM Cloud Distribution Service (SCDS) as mandated by the FAA (details here) since AIDAP is in the process of being deprecated this year. Users of my iNavCalc and JustNOTAMS apps may therefore have noticed a slight change in the format of the NOTAMS, reflecting this migration (which went live last weekend).

For those interested in the technical aspects, here's a summary of the various bits and pieces:

  1. The solution starts with receiving a continuous stream of NOTAMS from SCDS, published via a JMS (Java Messaging Service). I implemented this piece in Java (a language I'd written in only very occasionally in the past -- many thanks to the FAA team for their jump-start sample code, showing how it's done). To get back into my comfort zone (i.e., out of Java into something else), I implemented (in the Java code) a simple mechanism to channel the JMS messages into an  AWS SQS (Amazon Web Services Simple Queuing Service) queue. The simple Java app is running continuously on the main FlyLogical app server (no additional server resources required).
  2. I then wrote an AWS Lambda function (in C# dotnet core 2.1) to process each message from the SQS queue into an existing FlyLogical SQL database (hosted on the Microsoft Azure cloud). I made use of the built-in triggering mechanism which enables an AWS SQS queue to automatically call the Lambda function whenever a new message arrives.
  3. Finally, I augmented the existing RESTful API services (used across the current FlyLogical apps) to retrieve on-demand the NOTAMS from the SQL database and serve them up to the apps in similar (XML) format as AIDAP. 
This approach allowed for maximal code re-use and minimal code new build.
 


No comments:

Post a Comment