Giter Club home page Giter Club logo

Comments (4)

MichaCo avatar MichaCo commented on May 26, 2024

I'm not sure why get calls should always go to the slave. Usually slaves are used for replication and fail over. You can even setup the master to not store the data on disk and only the slave handles persistence. Not even sure if that would work with clusters at all?

Anyways, I don't really see a big need for that, but it could be implemented as a configuration option to override the defaults (which is master).

from cachemanager.

TMiNus avatar TMiNus commented on May 26, 2024

If the master is under heavy load, it would be nice to be reading also from the slaves nodes so we can free up some resources on master. I guess it depends on the size of the operation you are running but I can see the scenario

Actually vertical scaling depends on this

from cachemanager.

MichaCo avatar MichaCo commented on May 26, 2024

Just tested a few things. First of all, master to slave replication is non blocking async. So it could happen at any point that the items are not even on the slave although they just have been added.

Then, when retrieving an item, I also have to update e.g. sliding expiration. That can only happen on the master if the slave is readonly => doesn't work in one go (one lua script).

During update, I have to get the cache item to get the "old" value and then update to a new value. Those checks are pretty critical and shouldn't go on different servers.

=> will not be changed

from cachemanager.

TMiNus avatar TMiNus commented on May 26, 2024

All valid points, I didn´t think in the sliding expiration, but yes that should all happen in master. Although I think at least for items wtih absolute expiration or no expiration at all it could be implemented.

from cachemanager.

Related Issues (20)

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.