Although there are different explanations, this tradition seems to come from commemorating the Bodhi Day, the enlightenment day of the Buddha, which falls onto December 8th. After Buddhism spread to China, Buddhist monks would cook congee/porridge using various grains and beans to commemorate the suffering of Buddha on December 8th, and give the congee/porridge to devotees. Over the years, this custom slowly became more widespread and popular among common folk. And today it has become customary for Chinese people to eat congee/porridge on December 8th on the lunar calendar.