Posts by "Yichun Zhang"

Photo by Yichun Zhang

Precompile Lua Modules into LuaJIT Bytecode to Speedup OpenResty Startup

This tutorial demonstrates how to pre-compile Lua modules into LuaJIT bytecode. This can help reduce the startup time of ... Read More »

Photo by Yichun Zhang

Timing Lua Code Correctly in OpenResty

This tutorial demonstrates both the right ways and wrong ways of benchmarking user Lua code in OpenResty. 123cd ~mkdir ti... Read More »

Photo by Yichun Zhang

Lookup OpenResty Documentation on Terminal with restydoc

This tutorial demonstrates how to use OpenResty’s restydoc command-line utility to quickly lookup OpenResty documentation... Read More »

Photo by Yichun Zhang

Share Data Across Requests Served by OpenResty

This tutorial will demonstrate how to share data across different HTTP requests served by an OpenResty application. 12345... Read More »

Photo by Yichun Zhang

Install OpenResty on CentOS 8 via dnf

This tutorial will demonstrate how to install OpenResty on CentOS 8 via dnf. We’ll use this fresh install of CentOS 8 in... Read More »

Photo by Yichun Zhang

The resty Command-Line Utility Demo

In this tutroial, we will demonstrate how to use the resty command-line utility shipped with OpenResty. 123cd ~export PAT... Read More »

Photo by Gerry Roarty

Write Your Own Lua Modules for OpenResty Applications

Today I’d demonstrate how to write your own Lua modules in your OpenResty applications, step by step. Let’s put our simp... Read More »

Photo by 2Photo Pots

Hello World HTTP Example in OpenResty

This tutorial demonstrates how to implement a “hello world” HTTP interface using OpenResty. First of all, we make sure w... Read More »

Photo by Guido Jansen

Introduction to Lua-Land CPU Flame Graphs

What is a Flame Graph Simple Lua samples Complicated Lua applications... Read More »

Photo by Elena Mozhvilo

Memory Fragmentation in OpenResty and Nginx's Shared Memory Zones

An empty zone Filling entries of similar sizes Deleting odd-numbered keys... Read More »