An open API service indexing awesome lists of open source software.

https://github.com/aasaam/palantir

:crystal_ball: HTTP REST API reverse proxy
https://github.com/aasaam/palantir

cache-service ddos-protection reverse-proxy

Last synced: 3 months ago
JSON representation

:crystal_ball: HTTP REST API reverse proxy

Awesome Lists containing this project

README

          

[![Build Status](https://travis-ci.org/AASAAM/palantir.svg?branch=master)]()
[![AppVeyor Build status](https://ci.appveyor.com/api/projects/status/d1cmo37ht3mbha38/branch/master?svg=true)](https://ci.appveyor.com/project/MaaniBeigy/palantir-isq74/branch/master)
[![License: MIT/Apache-2.0]()](#license)
![GitHub last commit](https://img.shields.io/github/last-commit/AASAAM/palantir.svg?color=brightgreen)
![GitHub code size in bytes](https://img.shields.io/github/languages/code-size/AASAAM/palantir.svg?color=brightgreen)
[![]()]()
[![Project Status: Active – The project has reached a stable, usable state and is being actively developed.](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active)
[![contributions welcome]()]()
[![Gitter](https://badges.gitter.im/AASAAM/palantir.svg)](https://gitter.im/AASAAM/palantir?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
=======

# palantir

**palantir is a HTTP REST API reverse proxy**. It will perform load balance, caching, and health check. Also, it will prevent DDOS and will report metrics concerning health status of backend servers.

**Important: palantir is still under development and is not ready**.

## Getting started

If you are using Linux or macOS, you need to install **Rust** using [rustup]():

```shell
curl https://sh.rustup.rs -sSf | sh
```

For installation on Windows, read the instructions in [rust-lang book]().

Then, clone `palantir` repository:

```shell
git clone git@github.com:AASAAM/palantir.git
```

After modifying [config.toml](./config.toml) based on your upstream server:

```shell
cd palantir
cargo run --release --features fast
```

### Performance

palantir is built in Rust, so it can be compiled to native code for your architecture. Rust, unlike some languages such as Golang, does not have a garbage collector (GC) which constantly looks for no longer used memory while the program runs. Therefore, GC is usually a bad thing for high-throughput / high-load production systems. "In Rust, memory is handled through a system of ownership with a set of rules that the compiler checks at compile time. None of the ownership features slow down your program as it is running" [(reference)]().

In early [benchmarks](./benches/README.md), we observed that palantir competes with the nginx reverse proxy.

### License

Licensed under either of

- Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE) or )
- MIT license ([LICENSE-MIT](LICENSE-MIT) or )

palantir is inspired by [actix-reverse-proxy](), [bloom](), [rustnish](), and [weldr]().

### Contribution

To contribute to palantir, please see [CONTRIBUTING](./CONTRIBUTING.md) and [CODE_OF_CONDUCT](./CODE_OF_CONDUCT.md).

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

### Name Origin

**"But alone it could do nothing but see small images of things far off and days remote."
*the Lord of the Rings*, *The Two Towers* by John R. R. Tolkien**

The proxy's name *palantír* is derived from *the Lord of the Rings*, which is an artefact "used for both communication and as a means of seeing events in other parts of the world or in the distant past or in the future" [(reference)]().

This name has been chosen because:

1. Reverse proxies are communication tools similar to seeing-stones. They could do nothing alone, but can be used to converse.

1. They may show something from the past (*i.e.,* cached data).

1. They where designed to guard and unite humans' world, by obtaining information. This reverse proxy tries also to collect metrics and prevent DDOS in collaboration with other microservices.

1. *Palantíri* (plural of *palantír*), may mislead you since the health status of the message is not guaranteed *per se*. Much work is required for revealing the real health status of the upstream servers, which is going to be developed in **health module**.