Code Monkey home page Code Monkey logo

redis_presentation's Introduction

Redis presentation

This is the accompanying repository for a presentation on Redis containing multiple demos on the features and concepts discussed.

Overview of created environment

How to run

  • Run docker compose
docker compose up -d --build

Hint: If you do not want to build the container every time you can use the following to start the environment:

docker compose up -d --remove-orphans
  • Connect to container
docker exec -it redis-demo fish

How to use

  • Use redis-cli
redis-cli -h redis

  • Use RedisInsight in browser

Visit http://localhost:5540 in your browser and add a new connection. Make sure to use redis as the hostname instead of 127.0.0.1 and keep the port on 6379.


  • Use demo application inside container (possible demo names: cache, fibonacci_cache, pubsub, geo, geo_radius)
cargo run --bin [DEMO_NAME]

The demo fibonacci_cache requires two arguments:

  • n the nth number of fibonacci numbers to calculate
  • cache wether to use the cache or not

Example:

cargo run --bin fibonacci_cache 20 true

The demos geo and geo_radius require you to run the following to import the sample data provided by OpenStreetMap:

python3 /redis_demo/sample_data/etl.py

The demo geo requires one argument:

  • city the name of the city to search for

Example:

cargo run --bin geo mannheim

The demo geo_radius requires three arguments:

  • latitude the latitude of the center of the radius
  • longitude the longitude of the center of the radius
  • radius the radius in kilometers

Example:

cargo run --bin geo_radius 49.47474553497348 8.534231778349126 3

Useful links


OpenStreetMap® is open data, licensed under the Open Data Commons Open Database License (ODbL) by the OpenStreetMap Foundation (OSMF). Redis and the cube logo are registered trademarks of Redis Ltd.

redis_presentation's People

Contributors

mfloto avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

redis_presentation'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.