Giter Site home page Giter Site logo

http-debug-proxy's Introduction

Builder.io Proxy Debug Tool

This tool is used by Builder.io to help diagnose problems which our customers may encounter and which may be hard for Builder.io to reproduce.

This tool is an HTTP proxy which records all of the communications between your application and our API. It is meant to be used only why diagnosing problems and than it should be removed.

What does this do

This project contains a set up to create a local HTTP proxy for the https://cdn.builder.io/ endpoint.

How do I set this up Proxy

  1. Download the repository to your machine
    git clone https://github.com/BuilderIO/http-debug-proxy.git
    
  2. Install all dependencies
    npm install
    
  3. Start the proxy.
    npm start
    

Your proxy is now running on http://localhost:8100 and is proxying data from https://cdn.builder.io/. The result of the communication will be stored in the ./test folder.

At this point you need to re-configure your application to point to http://localhost:8100 instead of https://cdn.builder.io/. By changing your configuration the proxy will record the communication between your computer and Builder.io services. The recordings are useful tool for Builder.io engineers to help you diagnose the problems.

Next step is to configure your application to talk to the proxy rather than to the usual endpoint.

Gatsby

  1. Locate gatsby-config.js file in your application and add
    baseURL: "http://localhost:8100",
    
    to the options object. The resulting code should look something like this:
    options: {
       publicAPIKey: config.builderAPIKey,
       baseURL: "http://localhost:8100/api/v1/graphql",
       ...
     }
    
  2. Recrate the problem
  3. Send logs to Builder.io

Harvesting Logs

The logs are stored in this project directory under ./test folder. Please zip-up the folder and send it to the builder.io engineers for analysis.

http-debug-proxy's People

Contributors

mhevery avatar teleaziz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

isabella232

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.