In the context of distributed system, transaction basically means a series of RPC operations executed by client. The idea here is similar to the transaction in RDBMS.
more >>青溟山
In the context of distributed system, transaction basically means a series of RPC operations executed by client. The idea here is similar to the transaction in RDBMS.
more >>RPC is a important abstraction for processes to call functions in other processes. In the context of distributed system, it is heavily used and are crucial.
more >>For mutual Exclusion in Distributed System, we need to guarantee 3 propterties:
Common solution such as semaphore is not plausible in DS since there is not shared resources in DS.
So, we have different solution for this problem:
more >>The Leader Election Problem is classical and has been useful in many variants of systems, including cloud computing systems.
leader, in the context of solving distributed system problem, refers to a server who is responsible for receiving all reads and writes. It is useful for coordination among distributed systems.
In a group of processes, elect a leader and let everyone know in the group about this leader.
When a leader fails, by using failure detector, some process will detect this. The focus of election algorithm is to ensure:
1. Elect one leader only among the non-failed processes.
2. All non-failed processes in the group agree on the (new) leader.
more >>Binary Search is one of the most common techniques being used in scenarios of searching. It has many types of variants and I would like to discuss some of it and why the edge cases are designed like this.
This is probably the most common way to use binary search. It involves finding mid point within a range and thus divides the range (smaller the search range) based on the midpoint. Common implementation is:
1 | int binarySearch(int[] nums, int target) { |
Some important value includes: value of initial right, different value assignment in three different cases (less than, larger than, or equal to), and the criterion of while loop (< or <= ?).
value of right: By assigning “nums.length - 1”, we means that we are searching in range [left, right] (right boundary inclusive).If “nums.length”, then we are saying [left, right) (right boundary inclusive)
while loop criterion (< or <=) : By assigning <, we should jump out of the loop when left == right, which means that [left, right] will results in a omitted value, and [left, right) will not omit. Therefore when we pick the criterion, we should adjust the initial value of right accordingly to avoid unexpected behavior.
When process runs, page containing data that currently accessing (working set) will be mapped to physical ram.
more >>
缺失模块。
1、请确保node版本大于6.2
2、在博客根目录(注意不是yilia-plus根目录)执行以下命令:
npm i hexo-generator-json-content --save
3、在根目录_config.yml里添加配置:
jsonContent: meta: false pages: false posts: title: true date: true path: true text: false raw: false content: false slug: false updated: false comments: false link: false permalink: false excerpt: false categories: false tags: true