GithubHelp home page GithubHelp logo

like-article's Introduction

  • 👋 Hi, I’m Tiantian He.
  • 👀 In the past few years, I was interested in JAVA, I show great interesting in optimization now, however, not good at it.

like-article's People

Contributors

tiantianupup avatar

Stargazers

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

Watchers

 avatar  avatar

like-article's Issues

请问一下点赞业务,synchronize(或者分布式锁),同步是为了锁什么

如题
1。 在进行点赞或取消点赞操作的时候,看见你用了同步操作,不知道这个是为了锁什么呢,为了保证整个操作的原子性吗,如果不锁会发生什么呢
2. 如果是分布式场景,需要对什么加锁呢,如果按照你这个synchronize的理解,同一时间只能有一个人点赞或取消赞,这么不太对吧

更多功能的讨论

为你这篇文章点赞

对于点赞功能设计,我还有个疑问

假设存在一个推荐系统,推荐系统根据文章的点赞数量进行排序,选出前10名作为 first page 推荐给用户。由于用户不停的点赞,所以这个排序结果也在不断的变化。
为了减轻服务器中排序所造成的计算压力和数据库读取压力。我的设想是 设计一层缓存,对文章进行堆排序。

你觉得这个想法怎么样?
请问 如果使用 redis 做这个排序,有什么业内都用的方案吗?

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.