Today is the 19th day of work. I have been busy upgrading and expanding DFS recently. Now I have come to an end with a paragraph. Starting today, I will spare some time to write a locker server. The locker server will be as open-source as the DFS of the master, and will follow the "Public License V3" open-source protocol.
What is the locker server? In fact, we can see from the name that the locker Server is a server that provides locks. There are a lot of people who are sure to have questions, lock? Didn't I simply use the lock mechanism provided by class lib? Why do I need to write one separately? Otherwise, the locks provided by class lib can only lock the status of synchronization between different threads in the process, that is, the locks at the Thread level. If your site is very large, A business server can no longer meet your needs. At this time, you need to use a process-Level Lock. Then, the locker server will be used. To sum up, the locker server is actually a process-level Distributed Lock server.
Let's talk about the implementation. The implementation of the locker server has two parts, which follow the C/S style. Socket is used for communication and C is used for development on the server. Currently, only Linux systems are supported (in Windows). The client supports multiple development languages.Source codeTo facilitate client migration. Because of the particularity of the locker server, the Protocol Part cannot follow the fact standard of memcached, and only one set of protocols can be established.
In terms of the performance of the locker server, according to the general traffic of the website, we are currently preparing to support concurrent users up to 1 k per second. The memory consumption is temporarily closed and the default value is used, you can configure it in the config file later. You can configure the memory block size of an object based on your actual situation. (to improve performance, all objects have the same memory block size .).
The target audience of the locker Server is a group of medium and large site or distributed system developers or designers. If your site deployment is similar, I suggest you consider using the locker server or related services.
Figure: