Coder Social home page Coder Social logo

aws-vanguard-ca-etf-norm-countries's Introduction

Normalize Vanguard Country Breakdown Data

The lambda function to normalize Vanguard Canada ETF overview raw data and extract country breakdown

Overview

Technical Summary

This lambda function is the 2nd step of a state machine. After the first step Scrape Vanguard Canada ETF funds is completed, this lambda function will be triggered.

This lambda function normalize the fund overview data in vanguard_fund_overview collection and save them into fund_countries collection.

Project Structure

This project follows the clean architecture with minor variation

├── api
│   └── lambda
├── bin
│   ├── cmd
│   └── lambda
├── cmd
├── config
├── consts
├── entities
├── infrastructure
│   └── repositories
│       └── mongodb
│           ├── models
│           └── repo
└── usecase
    └── breakdown

Usage

To build the project for different environment set env variable LIBRARY_ENV. Default environment is dev. Check How To section to learn how to add new build env.

Build lambda function

Bellow command will build a lambda function to deploy to AWS. The output binary file is in `./bin/api/lambda/main

# Build lambda function
make build

Build cmd

Bellow command is to build a command line to run locally. The output binary file is in `./bin/cmd/main

# Build cmd
make build-cmd

Clean up

Bellow command is to clean up the build

# Clean
make clean

How To

Add new build environment

  • Make a copy of config_dev.go and change the suffix to new environment name. For example, adding staging the new file should be named config_staging.go.
  • Change the build tag (the first line) to new environment name. For example, changing // +build dev to // +build staging
  • Finally, update the variable values in new config file accordingly.
  • To build the project for the newly added environment don't forget to set env variable LIBRARY_ENV

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

This project is not an opensource project. Please contact the owner for permission.

aws-vanguard-ca-etf-norm-countries's People

Contributors

lenoobz avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.