Posts

Showing posts from April, 2019

Debugging Node.js in Visual Studio Code

Visual Studio Code is fast turning into my default IDE for most of my web based development. It is very fast and snappy and just seems to do the right thing. I am architecting a new product and I wanted to write a prototype for processing some JSON and I decided to this all in Node.js. I was able to setup a fast coding and debugging environment by turning on Node Debug in Settings and then just running node --inspect-brk foo.js  in Terminal. Make sure that you set a breakpoint before running.

Trade And Globalization (Our World in Data)

I am always on the lookout for good public data sets. I ran into this great one about Trade and Globalization . The data starts at 1800 and shows how trade has grown 4000% in the last century and most of the trade increase has been post 1950. This data is hosted on Our World in Data . They cover a lot of economic topics such as Energy, Military Spending, Poverty and so on.

API Gateway

We need to write our business logic independent of other concerns such as authentication, authorization, UI, logging etc. An API Gateway is a layer between all your client requests and a server that has the business logic. This is like a Java Servlet Filter. API Gateway by Chris Richardson at Microservices.io API Gateway 10 minute video  

Docker Cheat Sheet

Here is a good Docker Cheat Sheet I was looking at Google Cloud Data Analytics Video  and they mentioned that the Google Cloud Data Fusion is based on CDAP which Google bought. I downloaded and ran the image. docker pull docker pull caskdata/cdap-sandbox docker run -p 11011:11011 -d caskdata/cdap-sandbox

Markup Languages

I was looking into Swagger YAML and saw that it had a very simplified markup using just colons and indentation for describing hierarchical information. The evolution from XML -> JSON -> YAML shows that transition from more formal and explicit XML to more informal looking YAML. servers:   - url: http://api.example.com/v1     description: Optional server description, e.g. Main (production) server   - url: http://staging-api.example.com     description: Optional server description, e.g. Internal staging server for testing YAML vs XML vs JSON

Algorithmic Complexity and Big O Notation

I was listening to the Algorithmic Complexity on Coding Block and they were talking about the dangers of O(n 2 ) .  When I am doing a lot of metadata related coding I will quite often do O(n  2 ). But when I started going over any data collections I have to be a lot more careful of my loops and make sure that the performance is more linear. Big O notation is an approximation so O(n/2) gets simplified to O(n). See Big O Cheat Sheet that was mentioned in the blog.