Giter VIP home page Giter VIP logo

climate-cooperative / home-energy-assessment-database Goto Github PK

View Code? Open in Web Editor NEW
3.0 1.0 4.0 1.59 MB

Documentation, conversions, and data supporting Climate Cooperative's home energy audit and calculation tools.

License: Apache License 2.0

JavaScript 71.28% Shell 28.72%
energy energy-consumption energy-efficiency energy-data sustainability sustainable-development-goals sustainability-assessment climate-data climate-solutions climate

home-energy-assessment-database's People

Contributors

cooper-roper avatar jaretkeniston avatar rgraue avatar shilojones avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

home-energy-assessment-database's Issues

Implement TypeScript

Description

TypeScript introduces a layer of type safety to the repo. It also comes with additional features which can help with payloads/models, to improve code quality.

While the repo is still relatively small, this won't be a huge refactor.

Technical Notes

  • import typescript library as devDep
  • refactor to typescript
  • convert models to interface's
  • ensure building still works

Risks

[Add Risks]

Related Issues Or Discussions

[...Issues]

Build Express App Lambda

Right now the lambda builds a sample js image. Need to:

  • Build image of express app. (src/lambda.js)
  • update Dockerfile.lambda
  • update .env to reflect any new env vars
  • create scripts to locally run express app as lambda

Right Size Lambda

Lambdas performance is is dictated by its memory allocation. This is a setting defined in the tf module with memory_size attribute. Default is 128MB.

By Right Sizing this memory, can find a balance of performance and price. faster lambdas mean less cold/hot/warm response times. Lambda pricing is partially number of reqs, but also by execution time. Increasing mem decreases execution time.

Technical Notes:

https://s3.amazonaws.com/lambda-tools/pricing-calculator.html

Capture metrics regarding to plug into calculator and change mem to see what fits best (cheapest)

Parameterize Pipeline

The pipeline now uses a lot of hard coded variables. Moving these to parameters/variables allows for more re-usable code and configurable builds.

Add Variables for:

  • ACM cert name
  • domain name
  • application name
  • environment (PROD, DEVTEST..)

Bundle Lamba Code

To get the best performance from lambda, its best to keep the amount of code put into the lambda as small as possible. IE bundling EVERYTHING to a single entrypoint

Technical notes:

  • Explore esbuild (primary option)
  • Explore webpack (meh it'll work)

Integration Tests

Best practices (to include in checks during build_deploy) is to test the api works as intended with a set of integration tests.

Using Jest Create:

  • A Test suite that can be run in the pipeline
  • A test suite that can be run locally (maybe the same as above)

Create Agnostic DB Service

Description

Right now the API is tooled to integrate with dynamodb. It will be useful to abstract this layer out, so that any db/orm client can be used for implementation purposes.

Technical Notes

Risks

Related Issues Or Discussions

[...Issues]

Zipcode Via State Endpoint

A new route to get State data via the zipcode

/state/:zipcode

Technical notes:

Either use query parameters or POST method to allow for this access

Hydrate DynamoDB

Switching to DynamoDB we need 1of the following:

  • A set of scripts, or client to load data into dynamo. Data comes from LOCAL
  • A client to migrate data from mongo to Dynamo. Data comes from MONGO
  • A new repo to act as client to add data.
    • This would allow for easy access and updating of data

Open Questions:

  • Where does the data come from? The origin of truth?
  • How often does the data need to be updated
  • automate it???? i think yes

Cleanup Dead Code

Quite a bit of dead code in the repo from older times. Get ride of it...

Local Development Suite - DynamoDB

Swapping to Dynamo opens up a lot of opportunities in the cloud, but closes some doors locally. A nice to have is a local dynamo instance to hit locally.

Needs to:

  • standup local (mock) dynamo instance using docker-compose
  • be able to simulate full E2E usage

Technical Notes:

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.