Code Monkey home page Code Monkey logo

frolic's Introduction

Frolic Logo

Frolic is an open source backend service (written in Rust) to build customer facing dashboards 10x faster. You can directly connect your database to the project and use ready made APIs to query data. You no longer have to write custom APIs for different dashboard components and create/maintain SQL queries for them.

You can also use frolic-react for your UI along with frolic to create full stack dashboards much faster.

GitHub contributors GitHub issues GitHub stars GitHub closed issues GitHub pull requests GitHub commit activity GitHub license Twitter Follow

Web App Reference Architecture-2

Use single API to query data for all your dashboard components

You can use a single API endpoint provided by this project to query data for your dashboard.

Sample API Request:

curl --location 'http://localhost/api' \
--header 'Content-Type: application/json' \
--data '{
      "metrics": [
        {
          "field": "products.price", // <table_name>.<column_name>
          "aggregate_operator": "sum"
        }
      ],
      "dimensions": [
        {
          "field": "products.category" // <table_name>.<column_name>
        }
      ]
}
'

You can pass the metrics you require in the metrics field as an array. The field of the metric is written in <table_name>.<column_name> format. The aggregate_operator can be used to specifiy what operation you want to apply on the specified <table_name>.<column_name>.

The dimensions field allows you to categorize the metrics returned by the API. To specify the column by which you want to categorize the metrics, use the field operator and specify the column name in <table_name>.<column_name> format.

The data returned by the API will be a list of JSON which contains the dimensions and the attributes specified in the request.

The output of the above request will be as follows:

{
    "data": [
        {
            "products.price": "51",
            "products.category": "Gizmo"
        },
        {
            "products.category": "Doohickey",
            "products.price": "42"
        },
        {
            "products.category": "Gadget",
            "products.price": "53"
        },
        {
            "products.category": "Widget",
            "products.price": "54"
        }
    ]
}

Running Project

1. Clone the project

git clone https://github.com/frolicorg/frolic.git

2. Configure your database

Configure your database in config.toml.

3. Run the Project

Use docker to run the database

docker-compose up --build

You can start using the docker container path to query your data.

Features

  • ๐Ÿš€ Fast and Scalable APIs with Rust
  • Single API for all your dashboard requirements
  • Automatically generates and execute SQL queries on your database
  • Automatically handles complex table relationships
  • Caching of API Calls (using memcached)

Integrations

We currently support MySQL, Postgres & Clickhouse database. We will add integrations with other databases in the future.

Why Rust?

Rust is much faster and performant compared to other web frameworks. We have build this project using actix-web, which is one of the fastest web frameworks in the world. Checkout the comparison between ExpressJS and Actix-Web here.

Support and Community

Issues are inevitable. When you have one, our entire team and our active developer community is around to help.

๐Ÿ’ฌ Ask for help on Discord

โš ๏ธ Open an issue right here on GitHub

How to Contribute

We โค๏ธ our contributors. We're committed to fostering an open, welcoming, and safe environment in the community.

๐Ÿ“• We expect everyone participating in the community to abide by our Code of Conduct. Please read and follow it.

๐Ÿค If you'd like to contribute, start by reading our Contribution Guide.

Lets build great software together.

License

This project is available under the Apache License 2.0

frolic's People

Contributors

arihantparsoya avatar rgargrajatgarg avatar

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.