Showing posts with label Lambda. Show all posts
Showing posts with label Lambda. Show all posts

Wednesday, 12 December 2018

Creating Wardley Maps using Lambda Functions

One of the biggest limitations that I had when trying to use/create Wardley Maps was my inability to programatically create the maps (ideally via and DSL or something like DOT language).

What I really wanted was to be able to create Maps from an serverless environment, namely from an Lambda Function.

After some research, I was able to find a nice way to do just that :slight_smile: (all the code is available on this GitHub repo https://github.com/pbx-gs/wardley-maps-generator 7)

After playing with a number of scenarios and techniques I zoomed in on the following tech stack:

  • AWS API Gateway exposes an url that calls an
  • Lambda function, which saves the data supplied (coffeescript) in a file that will be loaded by an HTML page
  • the html will load up visjs 1 which is what will render the graph (in the browser)
  • start a local python web server, that
  • uses pyppeteer to open up a headless version of chrome, and
  • opens the page exposed by the web server in the headless browser, and
  • takes screenshot of the page, and
  • returns png value (to the browser or lambda caller)
  • Hugo was also used locally during develpment