I know LLMs and RAG are the hottest things these days but old school Streaming SQL for Online/Offline features are still valid solutions. See my colleague Gang Tao's articles on this:
www.timeplus.com/post/real-ti... and www.timeplus.com/post/real-ti...