深入Redis內部-Redis 源碼講解

來源:互聯網
上載者:User

標籤:

Redis作為 NoSQL 資料庫的傑出代表,一直廣受關注,其輕量級的敏捷架構,向來有儲存中的瑞士軍刀之稱。下面推薦的一篇文章,從源碼的角度講解了Redis 的整個工作流程,是瞭解 Redis 流程的絕佳文章。英文的,想搞懂還是要花些時間的

原文連結:Redis: under the hood

目錄:

  • Startup
    • Beginning global server state initialization
    • Setting up command table
    • Loading config file
    • initServer()
      • Shared objects
        • Shared integers
      • Event loop
      • Databases
      • TCP socket
      • Server cron
      • Registering connection handler with event loop
      • Opening the AOF
    • Back up to main()
      • Restoring data
      • Event loop setup
      • Entering the event loop
  • Processing a request & returning a response
    • Handling a new connection
    • Reading a command from a client
    • Executing the command and responding
  • Summary
  • Next time — tracing a SET and GET

Redis 啟動流程圖:

Redis 命令處理流程圖:

深入Redis內部-Redis 源碼講解(轉)

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.