Skip to content

getsentry/sentrymap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

The World - According to Sentry

Sentry Map Screenshot

This is a project for Sentry Hackweek 2023 and reads data from the Sentry GitHub organization and visualizes it as a map.

The presentation video for Sentry Hackweek can be found here: https://sentry.rewatch.com/video/r4p0m90fea52sd84-the-world-according-to-sentry (this is only visible for Sentry employees.)

Backend

The FastAPI backend reads data from the GitHub organization and caches it in a redis server. One API endpoint is provided to give all the data to the frontend.

For running the backend do the following:

cd backend
./run.sh

This will:

  • create a virtual environment,
  • install all the depencencies,
  • start redis-server
  • Run the backend on http://localhost:8000/

Prerequisites

You need to have redis-server and Python >= 3.10 installed on your system.

You also need to set a GitHub access token in an environment variable called GITHUB_ACCESS_TOKEN.

Refreshing the cache

When the backend starts it will read all data from GitHub and will cache it in redis.

To clear the cache call this URL: http;//localhost:8000/clear-cache. (This then needs a restart of the backend to load new data.)

To refresh the cach call this URL: http;//localhost:8000/reload-data. This will clear the cache and read all the data again from GitHub. Depending on the size of your organization this will take quite some time and the backend will eventually run into a timeout.

Frontend

The Frontend is a simple HTML file, connecting to the backend to retrieve all the data and then rendering a map on a HTML canvas.

For running the frontend do the following:

cd frontend
./run.sh

This will:

Prerequisites

As this starts a Python http server, you need to have Python installed to run the frontends run script.

About

Hackweek project. Create a map of the Kingdom of Sentry.

Topics

Resources

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published