業務架構設計迭代演進思路

{"type":"doc","content":[{"type":"blockquote","content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"業務架構大家都在做,到底什麼是業務架構,業務架構有什麼用,如果要做業務架構需要注意些什麼?"}]}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","marks":[{"type":"strong"}],"text":"在 2021 年 4 月 22-24 日舉辦的"},{"type":"link","attrs":{"href":"https:\/\/qcon.infoq.cn\/2021\/beijing\/?utm_source=web&utm_campaign=9&utm_medium=infoq&utm_content=shenjian","title":"xxx","type":null},"content":[{"type":"text","text":" QCon 全球軟件開發大會"}]},{"type":"text","marks":[{"type":"strong"}],"text":"(北京站)“"},{"type":"link","attrs":{"href":"https:\/\/qcon.infoq.cn\/2021\/beijing\/track\/1005?utm_source=web&utm_campaign=9&utm_medium=infoq&utm_content=shenjian","title":"xxx","type":null},"content":[{"type":"text","text":"業務架構演進"}]},{"type":"text","marks":[{"type":"strong"}],"text":"”專題上,到家集團技術委員會主席、快狗打車 CTO "},{"type":"link","attrs":{"href":"https:\/\/qcon.infoq.cn\/2021\/beijing\/presentation\/3260?utm_source=web&utm_campaign=9&utm_medium=infoq&utm_content=shenjian","title":"xxx","type":null},"content":[{"type":"text","text":"沈劍老師將分享《百萬司機在線打車平臺架構演進》"}]},{"type":"text","text":",在會前 InfoQ 帶着一系列的問題對沈老師進行了採訪。希望幫大家理清楚“到底什麼是業務架構?業務架構有什麼用?如果要做業務架構需要注意些什麼?”等問題。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"以下內容根據採訪內容整理。"}]},{"type":"heading","attrs":{"align":null,"level":3},"content":[{"type":"text","text":"爲什麼需要做業務架構"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"在講業務架構之前,我們先看下什麼是“架構”,理解架構之後,業務架構就更好理解了。“架構”一詞的英文單詞是“architecture”,而這個單詞來源於建築詞彙,可以理解是房屋的整體結構、框架。再看下“基礎架構”,它其實就是偏底層通用基礎建設相關的架構,如 "},{"type":"link","attrs":{"href":"https:\/\/s.geekbang.org\/search\/c=0\/k=K8s\/t=?utm_source=web&utm_campaign=9&utm_medium=infoq&utm_content=shenjian","title":"xxx","type":null},"content":[{"type":"text","text":"K8s"}]},{"type":"text","text":" 集羣建設、"},{"type":"link","attrs":{"href":"https:\/\/s.geekbang.org\/search\/c=0\/k=Service%20Mesh\/t=?utm_source=web&utm_campaign=9&utm_medium=infoq&utm_content=shenjian","title":"xxx","type":null},"content":[{"type":"text","text":"Service Mesh"}]},{"type":"text","text":" 等。現在再回過頭來看“業務架構”是不是已經又一個比較直觀的答案了呢?基於業務場景去設計架構,就是業務架構了。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https:\/\/static001.geekbang.org\/wechat\/images\/fd\/fd50ab4ffcf3bdead87bdaab7e687435.png","alt":null,"title":null,"style":null,"href":null,"fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"爲什麼要做業務架構?這個問題沈劍老師是這麼說的,“"},{"type":"text","marks":[{"type":"strong"}],"text":"系統本身是服務於業務的,脫離業務談系統,沒有意義"},{"type":"text","text":";系統架構本身也是解決業務問題的,脫離業務問題和業務階段談系統架構也同樣沒有意義。在做系統設計,"},{"type":"text","marks":[{"type":"strong"}],"text":"在做系統架構的過程中,一定要先了解業務的特點,針對業務做系統"},{"type":"text","text":";也一定要了解業務的痛點,通過系統架構設計去解決業務的痛點。”"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"因爲我們置身於業務場景中,"},{"type":"text","marks":[{"type":"strong"}],"text":"脫離業務去設計架構其實是有問題的"},{"type":"text","text":"。那麼,在業務發展的不同階段,架構的設計會不會是一樣呢?我們以快狗在線打車平臺來看。"}]},{"type":"heading","attrs":{"align":null,"level":3},"content":[{"type":"text","text":"不同階段,如何做業務架構"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"快狗打車,是中國頭部同城即時貨運平臺,其業務核心流程是:從用戶下單,系統推送,到司機搶單,中單,完單。當同時在線司機數,從萬,到十萬,到百萬的過程中,在量級不同的階段應該使用什麼樣的系統架構來應對,不同的階段的架構設計是不是一樣呢?"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"沈老師說,“其實在快狗打車業務發展之初,業務形態並不穩定,業務對系統的要求是快速實現、快速響應、快速迭代。但隨着業務形態逐步穩定,用戶、司機、訂單越來越多,業務對系統的要求是穩定,要具備一定的擴展性。”"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"然後沈老師舉了三個具體的場景案例來說,“相同的場景下,在早期和現在對系統架構的要求截然不同。”"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"blockquote","content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"第一個場景,訂單系統。早期快狗打車多個業務(2C、2B、直營城市、下沉城市等),每個業務更適合有自己獨立的訂單庫,方便快速試錯。而現在則需要統一訂單中心,提升穩定性、保證擴展性,並維持較低水平的維護成本。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"第二個場景,經緯度檢索。司機的經緯度上報與檢索,是快狗打車的業務核心之一。早期我們直接使用數據庫來存儲與檢索經緯度,快速實現、快速迭代。如果現在還用數據庫,肯定性能扛不住,所以現在則抽離了單獨的服務來實現。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"第三個場景,消息中心。早期 GPS 上報,快速實現了一套消息通道;訂單推送,快速實現了一套;用戶與司機聊天,快速實現了一套。現在,我們則把共性的需求抽象除了消息中心,以滿足不同場景,在擴充業務場景的適合,能夠複用系統。"}]}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"通過沈老師對快狗不同的業務場景的系統要求分析,我們可以知道,在量級不同的階段因爲對系統的需求不同,所以對應的系統架構也不會相同。在快狗發展的這幾個階段中,他們在業務架構設計方面還是走了一些彎路的;我們來看下,他們是怎麼解決的。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":3},"content":[{"type":"text","text":"業務架構設計迭代踩過的坑及解決思路"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"沈老師說,“因爲業務的不同階段對架構的要求不同,在架構迭代或者重構的過程會比較痛苦,一方面要完成架構升級與轉型,另一方面又不能影響業務需求的開發與迭代。”"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"在架構迭代和重構過程中,既要保證架構升級迭代,又不能影響現有業務正常進行;其實是有一定難度的。沈老師通過一個“訂單庫從分開,到訂單中心合併”的例子來說,他們當時遇到快速支持業務迭代的同時並行架構改造時是如何做的?"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"還是舉訂單庫從分開,到訂單中心合併的例子,整個過程實際是比較痛苦的:"}]},{"type":"blockquote","content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"(1) 第一個業務(優配業務),閉環了自己的訂單庫;"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"(2) 第二個業務(貨旳業務),爲了快速迭代,也閉環了自己的訂單庫;"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"(3) 第三、第四個業務(車隊業務、合夥人業務),發現情況不對,嘗試統一訂單庫,嘗試建立訂單中心,但並不徹底;"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"(4) 當有訂單統一展現的需求時,要訪問多個訂單庫,開始抓狂了,抱怨早期爲何不統一,下決定要統一;"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"(5) 然後開始數據收口,服務寫收口,服務讀收口,最終花了 1 年的時間,才完成訂單中心的統一;"}]}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https:\/\/static001.geekbang.org\/wechat\/images\/31\/3168a87c84e6369886d346ae220ce9ee.png","alt":null,"title":null,"style":null,"href":null,"fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"隨着業務的發展,對架構的需求不一樣,架構升級過渡期會比較痛苦,但又必須協同各個業務研發團隊,往正確的方向走,做到架構的階段性合理。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":3},"content":[{"type":"text","text":"中臺是下一步嘗試"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"當我問到,快狗在下一步的計劃時,沈老師說,其實他們目前在業務中臺方面做嘗試。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"“首先業務中臺是結合業務的,其次業務中臺是多業務通用的。例如,快狗打車的用戶、交易、訂單、結算、營銷等,不管是 2B、2C,自營業務還是下沉業務,都是通用的,就適合抽象成業務中臺,統一來建設。”"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","marks":[{"type":"strong"}],"text":"來自快狗打車的又一金句“任何脫離業務的中臺都是蹭熱度”。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":3},"content":[{"type":"text","text":"總結"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"我們熟悉了業務架構的概念,從快狗的業務場景出發,看到了不同階段對業務架構設計的目標其實是不一樣的,如果你正好也要做業務設計,沈老師是建議:"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"blockquote","content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"(1) 貼近自己的業務場景,深入的瞭解業務邏輯,針對該業務階段設計適合自身的框架;"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"(2) 系統架構設計中必須要考慮的可用性、高性能、擴展性、一致性等常見要素;"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"(3) 還需要考慮業務特性、業務痛點、業務需求,密切貼合業務做系統架構。"}]}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"針對不同的業務場景,不同的業務架構設計總是給我們帶來驚喜。比如 2020 特殊情況下,在線教育的崛起,學而思等在線教育又是怎麼針對自己的業務特性去做架構設計呢?除了在線教育的業務架構,在線票務、短視頻在業務架構演進的過程中,又會有怎樣的故事呢?"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","marks":[{"type":"strong"}],"text":"嘉賓介紹"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"老熟人了,哇咔咔。大家好,我是"},{"type":"link","attrs":{"href":"https:\/\/qcon.infoq.cn\/2021\/beijing\/presentation\/3260?utm_source=web&utm_campaign=9&utm_medium=infoq&utm_content=shenjian","title":"xxx","type":null},"content":[{"type":"text","text":"沈劍"}]},{"type":"text","text":",現在是快狗打車的 CTO,負責產品研發,同時是架構師之路公衆號的作者,偶爾深夜寫寫文章。比較喜歡分享自己的一些技術,產品,管理的一些經驗,"},{"type":"text","marks":[{"type":"strong"}],"text":"不管在公號上,還是在 "},{"type":"link","attrs":{"href":"https:\/\/qcon.infoq.cn\/2021\/beijing\/presentation\/3260?utm_source=web&utm_campaign=9&utm_medium=infoq&utm_content=shenjian","title":"xxx","type":null},"content":[{"type":"text","text":"QCon 大會"}]},{"type":"text","marks":[{"type":"strong"}],"text":"上,期待和大家的溝通交流,期待面基。"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}}]}
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章