官术网_书友最值得收藏!

Caching

The last major subsystem that I will include here is the caching layer. Drupal 8 has gone to great lengths to improve the performance of building pages and rendering data. To this end, the caching system has become an important part to consider whenever we either do complex or heavy calculations or render content.

From a module developer's perspective, there are two main pillars of the caching system. The first one provides developers a cache backend to store the result of complex data calculations. This data can be read in the next requests to avoid the need for redoing those calculations. This goes hand in hand with cache invalidation when something in the system changes that would require the calculations to be redone. The second pillar is the render cache, which allows developers to wrap their data output with metadata that describe in what context and when that data output needs to be invalidated or changed. The entire markup of that bit gets cached and invalidated based on the rules of the metadata.

We will see these in action in a later chapter dedicated to caching.

主站蜘蛛池模板: 新巴尔虎左旗| 宁安市| 松潘县| 宝清县| 新兴县| 淮滨县| 来安县| 五寨县| 忻州市| 博乐市| 茶陵县| 江津市| 奈曼旗| 收藏| 上饶县| 内丘县| 怀集县| 任丘市| 英山县| 宽城| 正蓝旗| 内乡县| 赞皇县| 浮梁县| 阿克| 唐山市| 轮台县| 家居| 万荣县| 湘阴县| 通山县| 沁阳市| 武胜县| 株洲市| 伊川县| 当阳市| 安庆市| 彰武县| 石林| 达拉特旗| 鹿泉市|