doupu3635 2013-08-12 12:54
浏览 27


I'm having a comment system which uses gravatar to show user images. I think of caching these images by encoding the resulted image into base64 and storing into memcache.

I'm doing this mainly to avoid querying gravatar often and to avoid load time. So i want to know side effects of using this method both seo and browser wise...

  • 写回答

1条回答 默认 最新

  • dqdes60666 2013-08-12 13:34

    Ok, so a few points to make here:

    Regarding performance:

    You're likely to see a performance loss here for the following reasons:

    • Browsers will cache the images from or so anything you do will only affect first load
    • itself is cached downstream by ISPs so there's a chance you won't even need to pull all the way from the Gravatar servers
    • Gravatar itself has good performance - many large sites use it without performance issues
    • Loading the images from another domain (in this case will be done in parallel to calls on your local domain by most modern browsers, so you might actually slow things down by adding more calls to your server which are done serially after a certain number of connection slots are taken (8+ depending on your browser).

    It's pretty hard to imagine seeing a performance gain from this. Maybe if you tiled a big collection of gravatar images into one larger png and used CSS to manipulate which ones showed, you'd have fewer server calls and might see a small performance gain, but man that sounds like a huge complexity hit for marginal gains at best.

    Regarding SEO:

    There shouldn't be an SEO issue with this, since search engines won't know that the image you serve locally is actually a Gravatar image. Though I suppose some search engines might consider using Gravatar a bit of a bonus as it could "legitimize" you in some way, though this is entirely speculative and should not be a factor in your decision making.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?



  • ¥45 工程软件单片机设计课题要求
  • ¥15 在centos7安装conda
  • ¥15 c#调用yolo3 dll文件获取的数据对不上
  • ¥20 WPF 如何实现多语言,label 和cs(live Charts)中是否都能翻译
  • ¥15 STM32F103上电短路问题
  • ¥15 关于#单片机#的问题:以ATMEGA128或相近型号单片机为控制器设计直流电机调速的闭环控制系统(相关搜索:设计报告|软件设计|流程图)
  • ¥15 打开软件提示错误:failed to get wglChoosePixelFormatARB
  • ¥15 (标签-python|关键词-char)
  • ¥15 python+selenium,在新增时弹出了一个输入框
  • ¥15 苹果验机结果的api接口哪里有??单次调用1毛钱及以下。