Skip to content
This repository has been archived by the owner on Mar 20, 2024. It is now read-only.

omnia-network/omnia-rdf-proxy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

omnia-rdf-proxy

This simple proxy handles requests for the AWS Neptune RDF database. This database exposes an HTTP SPARQL endpoint, that can be found in the AWS console. According to the documentation, this endpoint is not public, so this proxy is needed to make it accessible to the outside world.

Idempotent requests

The proxy is able to handle idempotent requests for the /update endpoint. This is done by caching the results of the requests in NGINX. The cache key is the header Idempotent-Key. If this header is not present, the request is rejected with a 400 Bad Request error. The cache is invalidated every 24 hours.

Authorization

/update endpoint returns a 401 Unauthorized error if the Authorization header is not present or if the value is not equal to the one specified in the UPDATE_API_KEY env variable.

Usage

Create an EC2 instance (with Docker) connected to the same VPC as the Neptune database. Clone this repo follow these steps:

  • copy the .env.example file to .env and fill in the values
  • run docker compose up -d

Development

Create the .env file as above and, in order to spin up a local RDF database, run:

  • docker compose --profile dev up -d

About

Proxy connections to RDF database

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published