Code Monkey home page Code Monkey logo

Comments (7)

youxiachai avatar youxiachai commented on August 17, 2024

他们的瀑布流。。。就是因为api里面就有宽高。。。话说这个项目(我不是作者。。)的作者不是推荐用另外一个控件吗?这个控件我看过,实现上不是很好。。

from android_waterfall.

youxiachai avatar youxiachai commented on August 17, 2024
  1. 一般而言,对于你这种需求,我的处理是用服务器做一个转发,在一个服务器(一般而言,应该有自己的服务器吧?也会一点后端吧?)里面接收请求,通过自己的服务器去请求api,然后处理后返回给客户端。

from android_waterfall.

qq280948982 avatar qq280948982 commented on August 17, 2024

先谢谢大神的回复,我知道他们是有自己的后台,但是后台怎么处理呢,去读取图片取得宽高,那样不是很慢吗,但是我在用“美丽说”的搜索功能时,响应的速度是很快的,1秒都不用就返回来了,我自己试过做个后台来读取图片,读取一个搜索结果(30条数据)大概需要用时2秒多...

from android_waterfall.

youxiachai avatar youxiachai commented on August 17, 2024

图片的宽高在获取的时候就已经写进数据库了(也就是说服务器只读一次图片!这种花费是不可能躲过去的,之所以很快因为这个第一次老早就处理了。。。),到客户端读数据的时候,只是下载图片而已。。

from android_waterfall.

qq280948982 avatar qq280948982 commented on August 17, 2024

但是搜索返回的结果那么多,他每一个都要先去查数据库,查到没有再读取图片,再写入数据库,那不是更慢吗?而且数据量很惊人啊

from android_waterfall.

youxiachai avatar youxiachai commented on August 17, 2024

redis 一秒可以处理 10w 数据,能做到这么大,解决方案有的是。。

from android_waterfall.

qq280948982 avatar qq280948982 commented on August 17, 2024

原来如此,谢谢大神了,敬礼!

from android_waterfall.

Related Issues (15)

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.