Coder Social home page Coder Social logo

presto-redis's Introduction

presto-redis

PrestoDB connector for Redis.

This is an experiment in using PrestoDb to run SQL queries on top of redis. It starts a PrestoDB server and attempts to connect to redis instance on localhost port 6379

The data model is treat maps as if they were tables and objects in maps as rows.

Requirements

The redis collections pakcage should be installed in the local maven repo [Redis Collection}(https://github.com/otaviojava/redis-collections)

Usage

  1. Start the server using gradle (2+). This will start the server on port 8383:
  • gradle runServer
  1. Download presto client and run it using:
  • ./presto --server localhost:8383 --catalog redis -schema maps
  1. Run some SQL queries
  • SHOW TABLES;
  • DESC employees;
  • SELECT * FROM employees WHERE sales < 2000;
  • SELECT active, SUM(sales) FROM employees GROUP BY active;

The server comes with some example data in table employees. More data can be inserted into redis directly

Config

Config is in src/main/resources

Status

Experimental proof of concept.

Warning The server will attempt to wipe all data on the connecting redis instance evey time it starts.

Credits

The overall design is based on the presto hazecast connector. Presto Hazelcast

presto-redis's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

790113107

presto-redis's Issues

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.