Skip to main content

Auto refresh cache of redis with MySQL binlog

Project description

Fettler

image image pypi ci

Introduction

Fettler is a service that help you refresh redis cache automatically. By listening on MySQL binlog, you can refresh redis cache in a timely manner and devoid of sensation or consciousness.

architecture

Install

Just install from pypi:

> pip install fettler

Usage

Config file

The example can be found in config.yml.

Run services

First you should run the services, which include producer, consumer.

Use docker-compose(recommended)

docker-compose up -d --build

Then the services is running.

Run manual

Run producer

The producer listens on MySQL binlog and send data changes to redis message queue.

> fettler produce
Run consumer

The consumer consume message queue and delete invalid caches by data changes and refresh policy registered from server.

> fettler consume

Register cache refresh policy

See examples to see how to add cache refresh policy in you application.

License

This project is licensed under the Apache-2.0 License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fettler-0.1.0.tar.gz (8.8 kB view details)

Uploaded Source

Built Distribution

fettler-0.1.0-py3-none-any.whl (14.9 kB view details)

Uploaded Python 3

File details

Details for the file fettler-0.1.0.tar.gz.

File metadata

  • Download URL: fettler-0.1.0.tar.gz
  • Upload date:
  • Size: 8.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.8

File hashes

Hashes for fettler-0.1.0.tar.gz
Algorithm Hash digest
SHA256 d3a4448ffdc0b48fd2a2754d42346408e0305b3e408bb1709a7119a85189925b
MD5 855fa68afa83288fa184e1e34efc8f17
BLAKE2b-256 e01d9131c17c914868cf5053eebb15613afcc8b7edf9949e164fe0867c6307d5

See more details on using hashes here.

File details

Details for the file fettler-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: fettler-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 14.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.8.8

File hashes

Hashes for fettler-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3c919d3765e72d2767ee7a7c020c23a1acd4553132a96a14e805e55f8834792e
MD5 957de9c75f50ef456ff7e2753e11af54
BLAKE2b-256 c9cac8d43739b83cb1a8c9f4cecc18ee0f75a511d741c70028e5db4512524ae2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page