iT邦幫忙

0

分散式系統: 現代軟體架構與設計考量

分散式系統: 現代軟體架構與設計考量

[1] The Definition of Distribution: A distributed system is a collection of autonomous computing elements that appears to its users as a single coherent system.

  • Collection of autonomous computing elements
    達到搜集算力是分散式系統的必要條件,一般來說是透過P2P (Peer to Peer) 連線方式做到。而在這種網路連線下,主要有3個 Issues 。1. How do verify member node? 2. Node connection state check Issue. 3. Can nonmember elements access member elements ?
  • Single coherent system
    使用者在存取系統的時候,並不會感受到是存取不同的裝置,會認為他是同一個系統。而要達到這樣子統合各裝置的能力,則需要 Middleware 的幫忙。
  • Middleware and distribution systems
    Middleware 用於統合各個 Node 的資源,讓使用者無法感知到存取的服務,可能是處於不同的機器。根據上述定義,分散式系統應如下圖的架構,各個算力資源(element) 透過網路來介接,並串聯成一個整體的生態系,即使是外部資源存取,也不會察覺該服務的節點差異。
    GitBook draft

Distribution System Design Goals

  • Resource Sharing

    Resource 不僅是指硬體資源也包含周邊資源,ex: 印表機等等

  • Making distribution transparent

Transparent Description
Access 不同的機器之前互相可以存取,即使是不同的作業系統或硬體規格。
Location 使用者在不同位置存取時,不會感受到區別。ex: 透過 URL 進行存取。
Relocation 當使用者轉移位置時,不會感知到也不影響使用。
Migration 使用者隨著移動,不影響資料的一致性。
Replication 當系統進行備份的時候,不影響使用者。
Concurrency 系統可以讓多個使用者同時存取。
Failure Tolerance 當系統失敗重啟的時後,不影響使用者。

為了做到 Transparent 應考量 Separating policy from mechanism 因為採用 Monolithic 難以有足夠的彈性做到Transparent的目地。拆分成多個Service 更能夠做到 migration、replication、Failure Tolerance等目地。

  • Being scalable
    在分散式系統中,Masking Failures Issue 是非常困難且重要的。因此,系統的 Scalability 就是相當重要的,使得 Service 故障排除的過程,不影響使用者。 然而在 Scalability 本身就會牽涉到另一個議題,要如何不讓使用者察覺,因此 Degree of distribution transparency 就是值得被考慮的議題。

Degree of distribution transparency

在分散式系統中會因為地區的不同,存取時間會受到影響。若要完全 distribution transparency ,使用者體驗則會影響到,因此需要對使用者分級,通常是以地區作為區分。

If such reliability cannot be guaranteed, it's then best to always perform only local execution, leading to the copy-before-use principle.

  • Being Open

    提供一個公開的介面,給其他裝置存取。如URL、DNS、IDL (Interface Definition Language)

  • Caching

    在 Replica 的架構下衍伸出來的問題是,Cache 的狀態的一致性

Type of Distributed systems

在分散式系統中,主要有三種大的服務型態的High Performance Distributed Computing, Distribution Information, Pervasive Computing,等三種服務的型態。

High Performance Distributed Computing
屬於高性能的計算能力,主要有兩種。一種是屬於叢集式的實體服務,組合一個大型的聯合系統。

  • Cluster Computing
    透過建置實體機器,串連起算力以提供服務。

  • Cloud Computing
    由服務商建制叢集式的服務,由服務商將算力切分出來,主要分為三種型態IaaS (Infrastructure-as-a-Service)、PaaS(Platform-as-a-Service)、SaaS (Software-as-a-Service)等三種型態。

Distributed Information Systems
這種服務型態主要就是現在主流服務的型態 (Query/Response) 的服務型態,有 Transaction Process (TP) 進行搜集全部的 Requests,進行 serving。

Pervasive Systems
Sensors 本身自形成一個網路,與雲端上的的服務進行溝通。

參考文件

[1] van Steen, Maarten, and Andrew S. Tanenbaum. "A brief introduction to distributed systems." Computing 98.10 (2016): 967-1009.


圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

尚未有邦友留言

立即登入留言