Improving the Display of Data Lists: Designing a Real-Time Event Subscription Architecture

Many data systems use polling refresh to display lists, which can cause a delay in updating content status and cannot immediately provide feedback to users on the page. Shortening the refresh time interval on the client side can lead to an excessive load on the server, which should be avoided. To solve this problem, this article proposes an event subscription mechanism. This mechanism provides real-time updates to the client, eliminating the need for polling refresh and improving the user experience. ...

2023-04-15 · 6 min · ming yang

Implementing Version Management of File Trees in PostgreSQL

Overview In the previous post, we discussed how to implement a file tree in PostgreSQL using ltree. Now, let’s talk about how to integrate version control management for the file tree. Version control is a process for managing changes made to a file tree over time. This allows for the tracking of its history and the ability to revert to previous versions, making it an essential tool for file management. With version control, users have access to the most up-to-date version of a file, and changes are tracked and documented in a systematic manner. This ensures that there is a clear record of what has been done, making it much easier to manage files and their versions. ...

2023-03-19 · 5 min · ming yang

Implement the file tree in PostgreSQL using ltree

Background A file tree is a hierarchical structure used to organize files and directories on a computer. It allows users to easily navigate and access their files and folders, and is commonly used in operating systems and file management software. But implementing file trees in traditional RDBMS like MySQL can be a challenge due to the lack of support for hierarchical data structures. However, there are workarounds such as using nested sets or materialized path approaches. Alternatively, you could consider using NoSQL databases like MongoDB or document-oriented databases like Couchbase, which have built-in support for hierarchical data structures. ...

2023-03-19 · 3 min · ming yang