支付宝 大规模Soa系统治理中的架构支持

182
程立 支付宝(中国)网络技术有限公司 北京,200948规模SOA系统治理中的架构支持 1

Transcript of 支付宝 大规模Soa系统治理中的架构支持

Page 1: 支付宝 大规模Soa系统治理中的架构支持

题 作

程立支付宝(中国)网络技术有限公司

北京,2009年4月8日

规模SOA系统治理中的架构支持大 小

1

Page 2: 支付宝 大规模Soa系统治理中的架构支持

2

Through 2010, a lack of working SOA governance arrangements will be the most common reason for SOA failure.

“Applica*on and SOA Governance, The Who, What and Why” ‐ Ma> Hotle, Gartner, June 2008

Page 3: 支付宝 大规模Soa系统治理中的架构支持

提纲

历史

问题

展望

SOA治理

架构透明

控制

对齐

3

Page 4: 支付宝 大规模Soa系统治理中的架构支持

历史

历史

问题

展望

SOA治理

架构透明

控制

对齐

4

Page 5: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第一天

5

Page 6: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第一天

上帝说: 要有光,就有了光

5

Page 7: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第一天

上帝说: 要有光,就有了光

认识SOA,学习SOA达成走SOA路线的共识

5

Page 8: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第二天

6

Page 9: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第二天

上帝说: 诸水之间要有空气将水分为上下

6

Page 10: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第二天

上帝说: 诸水之间要有空气将水分为上下

识别主要挑战(平衡快与稳)找到SOA的切入点(核心分离)

6

Page 11: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第三天

7

Page 12: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第三天

上帝说: 水要聚在一处,使旱地露出来地要发生青草,和结种子的果蔬,

并结果子的树木

7

Page 13: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第三天

上帝说: 水要聚在一处,使旱地露出来地要发生青草,和结种子的果蔬,

并结果子的树木

第一组服务落地(交易服务)并结出果实

7

Page 14: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第四天

8

Page 15: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第四天

上帝…造两个大光,大的管昼,小的管夜。

又造众星。

8

Page 16: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第四天

上帝…造两个大光,大的管昼,小的管夜。

又造众星。

建立两大支柱服务群及卫星系统(账务会计、客户信息)

8

Page 17: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第五天

9

Page 18: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第五天

上帝说: 水要多多滋生有生命的物要有雀鸟飞在地面以上,天空之中

9

Page 19: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第五天

上帝说: 水要多多滋生有生命的物要有雀鸟飞在地面以上,天空之中

服务数量爆发式增长

9

Page 20: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第六天

10

Page 21: 支付宝 大规模Soa系统治理中的架构支持

历史 《创世纪》第六天

可以休息了吗?

10

Page 22: 支付宝 大规模Soa系统治理中的架构支持

问题

历史

问题

展望

SOA治理

架构透明

控制

对齐

11

Page 23: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA改变应用的构建方式

SOA separates func?ons into dis?nct units, or services, which developers make accessible over a network in order that users can combine and reuse them in the produc?on of applica?ons.

─ Wikipedia

12

Page 24: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA改变应用的构建方式

SOA separates func?ons into dis?nct units, or services, which developers make accessible over a network in order that users can combine and reuse them in the produc?on of applica?ons.

─ Wikipedia

12

Page 25: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA改变应用的构建方式

SOA separates func?ons into dis?nct units, or services, which developers make accessible over a network in order that users can combine and reuse them in the produc?on of applica?ons.

─ Wikipedia

12

Page 26: 支付宝 大规模Soa系统治理中的架构支持

问题 服务建设的递归

13

Page 27: 支付宝 大规模Soa系统治理中的架构支持

问题 服务建设的递归

第1代服务

第1代服务

服务复合

13

Page 28: 支付宝 大规模Soa系统治理中的架构支持

问题 服务建设的递归

第1代服务

第1代服务

服务复合

第2代服务

服务复合

13

Page 29: 支付宝 大规模Soa系统治理中的架构支持

问题 服务建设的递归

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

13

Page 30: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

14

Page 31: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

14

Page 32: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

看得见的复杂,看不清的机理

14

Page 33: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

15

Page 34: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

15

Page 35: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

? ? ?

? ?

15

Page 36: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

?? ? ?

? ?

?????

15

Page 37: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

?? ? ?

? ?

?????

看得见的变更,看不清的影响

15

Page 38: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

16

Page 39: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

16

Page 40: 支付宝 大规模Soa系统治理中的架构支持

第1代服务

第1代服务

服务复合

第2代服务

服务复合

第N代服务

服务复合

问题 SOA 副作用

看得见的局部,看不清的全局

16

Page 41: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 盲区

17

Page 42: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 盲区

战略

100分

17

Page 43: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 盲区

战略

100分商业模式

* 90%

17

Page 44: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 盲区

战略

100分商业模式

* 90%

产品设计

* 90%

17

Page 45: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 盲区

战略

100分商业模式

* 90%

产品设计

* 90%

应用架构

* 90%

17

Page 46: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 盲区

战略

100分商业模式

* 90%

产品设计

* 90%

应用架构

* 90%

技术架构

* 90%

17

Page 47: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 盲区

战略

100分商业模式

* 90%

产品设计

* 90%

应用架构

* 90%

技术架构

* 90% 实现* 90%

17

Page 48: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 盲区

战略

100分商业模式

* 90%

产品设计

* 90%

应用架构

* 90%

技术架构

* 90% 实现* 90%

59分

17

Page 49: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 盲区

战略

100分商业模式

* 90%

产品设计

* 90%

应用架构

* 90%

技术架构

* 90% 实现* 90%

靠谱的战略,不靠谱的实现

59分

17

Page 50: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 雷区

遗留系统服务

合作伙伴服务

领域服务

业务服务

流程服务

技术服务

数据服务

门户服务

开放服务

18

Page 51: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 雷区

遗留系统服务

合作伙伴服务

领域服务

业务服务

流程服务

技术服务

数据服务

门户服务

开放服务

You only need one service to destroy your business.

─ Gartner

18

Page 52: 支付宝 大规模Soa系统治理中的架构支持

问题 SOA 雷区

遗留系统服务

合作伙伴服务

领域服务

业务服务

流程服务

技术服务

数据服务

门户服务

开放服务

You only need one service to destroy your business.

─ Gartner

18

Page 53: 支付宝 大规模Soa系统治理中的架构支持

问题 《创世纪》第六天

19

Page 54: 支付宝 大规模Soa系统治理中的架构支持

问题 《创世纪》第六天

上帝…照着自己的形像造人,对他们说要生养众多,遍满地面,治理这地

19

Page 55: 支付宝 大规模Soa系统治理中的架构支持

问题 《创世纪》第六天

上帝…照着自己的形像造人,对他们说要生养众多,遍满地面,治理这地

19

Page 56: 支付宝 大规模Soa系统治理中的架构支持

治理

历史

问题

展望

SOA治理

架构透明

控制

对齐

20

Page 57: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 58: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 59: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 60: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 61: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 62: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 63: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 64: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 65: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 66: 支付宝 大规模Soa系统治理中的架构支持

治理 什么是SOA治理SOA governance is doing the right SOA things the right way of the SOA stakeholders.

Eric A. Marks: “SOA Governance of the Services Driven Enterprise”

SOA Governance is a concept used for ac?vi?es related to exercising control over services in an SOA. The specific focus of SOA governance is on the development of services that add value to the business, effec?ve SOA governance must cover the people, processes, and technologies involved in the en?re SOA life cycle.

─ Wikipedia21

Page 67: 支付宝 大规模Soa系统治理中的架构支持

治理 理解SOA治理

22

Page 68: 支付宝 大规模Soa系统治理中的架构支持

概念-GTU服务契约

治理 理解SOA治理

22

Page 69: 支付宝 大规模Soa系统治理中的架构支持

发布

查找

使用 运行-GTW

概念-GTU服务契约

治理 理解SOA治理

22

Page 70: 支付宝 大规模Soa系统治理中的架构支持

发布

查找

使用 运行-GTW需求

设计

运行 开发-GTD

概念-GTU服务契约

治理 理解SOA治理

22

Page 71: 支付宝 大规模Soa系统治理中的架构支持

发布

查找

使用 运行-GTW需求

设计

运行 开发-GTD

治理-GTR

定义

实施

度量

概念-GTU服务契约

治理 理解SOA治理

22

Page 72: 支付宝 大规模Soa系统治理中的架构支持

  理解SOA Governance

SOA Governance由策略、框架和控制日常SOA活动的流程(这些流程由IT创建)组成…

我们早就有了

更多是管理流程,类似CMMI?

分好几个level, 譬如你定义一个数据类型也要申请

治理 实现治理: 可以有流程

天王盖地虎

面壁修炼

天王盖地虎

面壁修炼

发表于 2008-10-26

23

Page 73: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 可以以人为本

24

Page 74: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 可以以人为本

开发人员

24

Page 75: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 可以以人为本

开发人员

应用架构师 业务架构师

技术架构师

24

Page 76: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 可以以人为本

开发人员

应用架构师 业务架构师

技术架构师

产品经理

24

Page 77: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 可以以人为本

开发人员

应用架构师 业务架构师

技术架构师

产品经理 项目经理

24

Page 78: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 可以以人为本

开发人员

应用架构师 业务架构师

技术架构师

产品经理 项目经理SQA

24

Page 79: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 可以不差钱

25

Page 80: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 可以不差钱

25

Page 81: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 可以不差钱

25

Page 82: 支付宝 大规模Soa系统治理中的架构支持

治理 Software AG

26

Page 83: 支付宝 大规模Soa系统治理中的架构支持

治理 Software AG

26

Page 84: 支付宝 大规模Soa系统治理中的架构支持

治理 Software AG

26

Page 85: 支付宝 大规模Soa系统治理中的架构支持

治理 Software AG

26

Page 86: 支付宝 大规模Soa系统治理中的架构支持

治理 Software AG

26

Page 87: 支付宝 大规模Soa系统治理中的架构支持

治理 Software AG

26

Page 88: 支付宝 大规模Soa系统治理中的架构支持

治理 MuleSource

27

Page 89: 支付宝 大规模Soa系统治理中的架构支持

治理 MuleSource

27

Page 90: 支付宝 大规模Soa系统治理中的架构支持

治理 MuleSource

27

Page 91: 支付宝 大规模Soa系统治理中的架构支持

治理 MuleSource

27

Page 92: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 听听专家观点Through 2010, a lack of working SOA governance arrangements will be the most common reason for SOA failure.

“Applica*on and SOA Governance, The Who, What and Why” ‐ Ma> Hotle, Gartner, June 2008

28

Page 93: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 听听专家观点Through 2010, a lack of working SOA governance arrangements will be the most common reason for SOA failure.

“Applica*on and SOA Governance, The Who, What and Why” ‐ Ma> Hotle, Gartner, June 2008

28

Page 94: 支付宝 大规模Soa系统治理中的架构支持

治理 实现治理: 听听专家观点Through 2010, a lack of working SOA governance arrangements will be the most common reason for SOA failure.

“Applica*on and SOA Governance, The Who, What and Why” ‐ Ma> Hotle, Gartner, June 2008

28

Page 95: 支付宝 大规模Soa系统治理中的架构支持

治理 作为架构师的你

29

Page 96: 支付宝 大规模Soa系统治理中的架构支持

治理 作为架构师的你

该出手了!29

Page 97: 支付宝 大规模Soa系统治理中的架构支持

架构

历史

问题

展望

SOA治理

架构

透明 控制 对齐

30

Page 98: 支付宝 大规模Soa系统治理中的架构支持

提升服务架构的可视性

你能看清你的系统的骨架吗?

架构透明

31

Page 99: 支付宝 大规模Soa系统治理中的架构支持

一致架构、模式与命名

展现层

MVC/CV

Template Form

ControllerTileLayout

应用层

TS AppFacade

Process Rule

领域层

DD

D

DomainObject DomainService

持久层

ORM

DataObjectDAO

ORMServiceAgent

集成层

SA

通用服务

DI/AO

P

FactoryRepository

DTO DTOAssembler

架构透明

32

Page 100: 支付宝 大规模Soa系统治理中的架构支持

一致架构、模式与命名

展现层

MVC/CV

Template Form

ControllerTileLayout

应用层

TS AppFacade

Process Rule

领域层

DD

D

DomainObject DomainService

持久层

ORM

DataObjectDAO

ORMServiceAgent

集成层

SA

通用服务

DI/AO

P

FactoryRepository

DTO DTOAssembler

架构透明

32

XYZControllerXYZFacadeXYZServiceXYZXYZRepositoryXYZFactoryXYZDAOXYZDO…

Page 101: 支付宝 大规模Soa系统治理中的架构支持

自动化 工具小

PayRuleDO.java

SQLParserMiddlegen

Velocity

小工具 DALGen

PayRuleDAO.java

DB

Iba*sPayRuleDAOImpl.javaPayRule‐sqlmap‐Mapping.xml

sqlmap.xml

Glue

Model

beans‐dao.xml

架构透明

33

Page 102: 支付宝 大规模Soa系统治理中的架构支持

自动化 工具小

PayRuleDO.java

SQLParserMiddlegen

Velocity

小工具 DALGen

PayRuleDAO.java

DB

Iba*sPayRuleDAOImpl.javaPayRule‐sqlmap‐Mapping.xml

sqlmap.xml

Glue

Model

beans‐dao.xml

对抗集体性拖拉的GTD法则

别做大项目,从小项目开始,而且永远不要期望它变大。如果这么想,就会做过度设计,把它想象得过于重要。更坏的情况是,你可能会被自己想象中的艰难工作所吓 …… 我致力于Linux达13年之久,我想后面还得花上好些时间。如果一早就妄想做个大东西,可能现在还没动手呢。

—— Linus Torvalds

摘自《梦断代码 – Dreaming In Code》,韩磊译

架构透明

33

Page 103: 支付宝 大规模Soa系统治理中的架构支持

关注它,标记它

打上@AccountTransAction标记,你可以 说明这是账务处理操作 统计共有多少账务处理操作 跟踪账务处理操作接口的变更 自动控制访问权限 自动控制事务边界 自动填写参数(txId) 自动监测执行性能 自动记录审计日志

架构透明

34

Page 104: 支付宝 大规模Soa系统治理中的架构支持

领域驱动

代码摘自http://dddsample.sourceforge.net/

架构透明

35

Page 105: 支付宝 大规模Soa系统治理中的架构支持

领域驱动

代码摘自http://dddsample.sourceforge.net/

架构透明

35

Page 106: 支付宝 大规模Soa系统治理中的架构支持

领域驱动

代码摘自http://dddsample.sourceforge.net/

@DomainRoot(“Cargo”)

架构透明

35

Page 107: 支付宝 大规模Soa系统治理中的架构支持

领域驱动

代码摘自http://dddsample.sourceforge.net/

@DomainRoot(“Cargo”)

文档可以少写

但领域建模、实现规范、JavaDoc必须有

有它们,你可以产生更一致、更灵活、更时新的文档

架构透明

35

Page 108: 支付宝 大规模Soa系统治理中的架构支持

“财务”报表源代码 发布包

Spring QDox

小工具 SG

docbook

Velocity

jfreechart

XMLParser

graphviz

Glue

Model

服务提供表 服务引用表 系统依赖图 服务变动表关键指标图 依赖变动表

架构透明

36

Page 109: 支付宝 大规模Soa系统治理中的架构支持

“财务”报表源代码 发布包

Spring QDox

小工具 SG

docbook

Velocity

jfreechart

XMLParser

graphviz

Glue

Model

服务提供表 服务引用表 系统依赖图 服务变动表关键指标图 依赖变动表

资产负债表

有什么,缺什么

架构透明

36

Page 110: 支付宝 大规模Soa系统治理中的架构支持

“财务”报表源代码 发布包

Spring QDox

小工具 SG

docbook

Velocity

jfreechart

XMLParser

graphviz

Glue

Model

服务提供表 服务引用表 系统依赖图 服务变动表关键指标图 依赖变动表

资产负债表

有什么,缺什么

损益表

变化了什么

架构透明

36

Page 111: 支付宝 大规模Soa系统治理中的架构支持

Registry与Repository架构透明

37

Page 112: 支付宝 大规模Soa系统治理中的架构支持

Registry与Repository

SOA生命周期过程识别 分析 设计 实现 部署 运行 变更

架构透明

37

Page 113: 支付宝 大规模Soa系统治理中的架构支持

Registry与Repository

SOA生命周期过程识别 分析 设计 实现 部署 运行 变更

SOA技术基础设施运行时 通信 安全 监控 工具SLA

架构透明

37

Page 114: 支付宝 大规模Soa系统治理中的架构支持

Registry与Repository

SOA生命周期过程识别 分析 设计 实现 部署 运行 变更

服务与元数据模型

SOA技术基础设施运行时 通信 安全 监控 工具SLA

架构透明

37

Page 115: 支付宝 大规模Soa系统治理中的架构支持

Registry与Repository

SOA生命周期过程识别 分析 设计 实现 部署 运行 变更

服务与元数据模型

SOA技术基础设施运行时 通信 安全 监控 工具SLA

政策模型

架构透明

37

Page 116: 支付宝 大规模Soa系统治理中的架构支持

Registry与Repository

SOA生命周期过程识别 分析 设计 实现 部署 运行 变更

服务与元数据模型

SOA技术基础设施运行时 通信 安全 监控 工具SLA

政策模型

Repository 服务资产管理

架构透明

37

Page 117: 支付宝 大规模Soa系统治理中的架构支持

Registry与Repository

SOA生命周期过程识别 分析 设计 实现 部署 运行 变更

服务与元数据模型

SOA技术基础设施运行时 通信 安全 监控 工具SLA

政策模型

Repository 服务资产管理

Registry服务运行管理

架构透明

37

Page 118: 支付宝 大规模Soa系统治理中的架构支持

Registry与Repository

SOA生命周期过程识别 分析 设计 实现 部署 运行 变更

服务与元数据模型

SOA技术基础设施运行时 通信 安全 监控 工具SLA

政策模型

Repository 服务资产管理

Registry服务运行管理

架构透明

37

Page 119: 支付宝 大规模Soa系统治理中的架构支持

提升服务架构的可控性

大处着眼,小处着手

架构控制

38

Page 120: 支付宝 大规模Soa系统治理中的架构支持

目标-原则-政策架构控制

39

Page 121: 支付宝 大规模Soa系统治理中的架构支持

目标-原则-政策

目标关键业务必须正确处理

架构控制

39

Page 122: 支付宝 大规模Soa系统治理中的架构支持

目标-原则-政策

目标关键业务必须正确处理

原则 原则关键业务变更严格控制 关键业务操作执行必须可审计

架构控制

39

Page 123: 支付宝 大规模Soa系统治理中的架构支持

目标-原则-政策

目标关键业务必须正确处理

原则 原则关键业务变更严格控制 关键业务操作执行必须可审计

政策 政策 政策标注关键业务检测关键业务变更,评审通过方可上线

业务操作有合规的日志

架构控制

39

Page 124: 支付宝 大规模Soa系统治理中的架构支持

政策运行期控制

政策业务操作有合规的日志

服务消费者 服务提供者

服务代理ServiceAgent

服务接口Service

Interface业务逻辑业务逻辑

架构控制

40

Page 125: 支付宝 大规模Soa系统治理中的架构支持

政策运行期控制

政策业务操作有合规的日志

服务消费者 服务提供者

服务代理ServiceAgent

服务接口Service

Interface业务逻辑业务逻辑

@CriticalService

架构控制

40

Page 126: 支付宝 大规模Soa系统治理中的架构支持

政策运行期控制

政策业务操作有合规的日志

服务消费者 服务提供者

服务代理ServiceAgent

服务接口Service

Interface业务逻辑业务逻辑

服务政策Service Policy

@CriticalService

架构控制

40

Page 127: 支付宝 大规模Soa系统治理中的架构支持

政策运行期控制

政策业务操作有合规的日志

服务消费者 服务提供者

服务代理ServiceAgent

服务接口Service

Interface业务逻辑业务逻辑

服务政策Service Policy

服务通信设施

@CriticalService

架构控制

40

Page 128: 支付宝 大规模Soa系统治理中的架构支持

政策运行期控制

政策业务操作有合规的日志

服务消费者 服务提供者

服务代理ServiceAgent

服务接口Service

Interface业务逻辑业务逻辑

服务政策Service Policy

服务通信设施

审计日志记录器

@CriticalService

架构控制

40

Page 129: 支付宝 大规模Soa系统治理中的架构支持

政策集成期控制

政策

服务政策Service Policy

检测关键业务变更,评审通过方可上线

持续集成系统

评审组名单与责任定义

架构控制

41

Page 130: 支付宝 大规模Soa系统治理中的架构支持

政策集成期控制

政策

服务政策Service Policy

检测关键业务变更,评审通过方可上线

持续集成系统

评审组名单与责任定义

服务变更报表小工具SG

架构控制

41

Page 131: 支付宝 大规模Soa系统治理中的架构支持

政策集成期控制

政策

服务政策Service Policy

检测关键业务变更,评审通过方可上线

持续集成系统

评审组名单与责任定义

服务变更报表小工具SG

小工具SC关键业务变更监控

研发管理流程平台

架构控制

41

Page 132: 支付宝 大规模Soa系统治理中的架构支持

政策集成期控制

政策

服务政策Service Policy

检测关键业务变更,评审通过方可上线

持续集成系统

评审组名单与责任定义

服务变更报表小工具SG

小工具SC关键业务变更监控

研发管理流程平台

架构控制

41

Page 133: 支付宝 大规模Soa系统治理中的架构支持

其它

软件过程

企业架构

集成的政策执行模型

政策 设计/实现 质保/测试 运行/管理

•业务设计•服务建模•服务构建

•功能测试•性能测试•发布评审

•性能容量•服务水平•安全保障

过程保障

组织保障

业务

系统保障

运行时 Registry Repository 监控

产品

研发 质量

高级决策层

运维 其它

其它

人工执行自动辅助

自动执行

政策定义人工执行例外管理

架构控制

42

Page 134: 支付宝 大规模Soa系统治理中的架构支持

架构的终极意义

取得高速前进中的默契

架构对齐

43

Page 135: 支付宝 大规模Soa系统治理中的架构支持

双边模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务架构

业务发展

业务运营

IT

IT架构

IT研发

IT运管

IT治理

企业

使命、愿景、战略企业治理

44

Page 136: 支付宝 大规模Soa系统治理中的架构支持

双边模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务架构

业务发展

业务运营

IT

IT架构

IT研发

IT运管

IT治理

企业

使命、愿景、战略企业治理

44

拥抱变化

Page 137: 支付宝 大规模Soa系统治理中的架构支持

双边模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务架构

业务发展

业务运营

IT

IT架构

IT研发

IT运管

拥抱变化

IT治理

企业

使命、愿景、战略企业治理

44

拥抱变化

Page 138: 支付宝 大规模Soa系统治理中的架构支持

双边模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务架构

业务发展

业务运营

IT

IT架构

IT研发

IT运管

拥抱变化

IT治理

企业

使命、愿景、战略企业治理

拥抱变化

44

拥抱变化

Page 139: 支付宝 大规模Soa系统治理中的架构支持

双边模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务架构

业务发展

业务运营

IT

IT架构

IT研发

IT运管

拥抱变化

IT治理

企业

使命、愿景、战略企业治理

拥抱变化拥抱变化

44

拥抱变化

Page 140: 支付宝 大规模Soa系统治理中的架构支持

双边模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务架构

业务发展

业务运营

IT

IT架构

IT研发

IT运管

拥抱变化

IT治理

企业

使命、愿景、战略企业治理

拥抱变化拥抱变化

渐行渐远

44

拥抱变化

Page 141: 支付宝 大规模Soa系统治理中的架构支持

什么是对齐(Alignment)?  I did not live un?l this ?me,  Crown'd my felicity,  When I could say without a crime,

  I am not thine, but thee.——  Katherine Philips(17世纪英国女诗人)

  我直到现在才算真正活着,  我的快乐得到了加冕,  我可以无愧地说,

  我不是你的,我就是你。 —— 某网友译

架构对齐

45

Page 142: 支付宝 大规模Soa系统治理中的架构支持

统一模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务发展

业务运营

IT

IT研发

IT运管

企业

使命、愿景、战略

治理

统一架构

46

治理 治理

Page 143: 支付宝 大规模Soa系统治理中的架构支持

统一模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务发展

业务运营

IT

IT研发

IT运管

企业

使命、愿景、战略

治理

统一架构

46

治理 治理

拥抱变化

Page 144: 支付宝 大规模Soa系统治理中的架构支持

统一模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务发展

业务运营

IT

IT研发

IT运管

企业

使命、愿景、战略

治理

统一架构

拥抱变化

46

治理 治理

拥抱变化

Page 145: 支付宝 大规模Soa系统治理中的架构支持

统一模型架构对齐环境

客户

市场

产业

机会

竞争

监管

投资

业务

业务发展

业务运营

IT

IT研发

IT运管

企业

使命、愿景、战略

治理

统一架构

拥抱变化

统一演进

46

治理 治理

拥抱变化

Page 146: 支付宝 大规模Soa系统治理中的架构支持

应用 技术

第0层企业->业务线

第1层业务线->产品

第2层产品->服务

第3层服务->功能

业务

企业架构架构对齐

47

Page 147: 支付宝 大规模Soa系统治理中的架构支持

描述企业架构的语言架构对齐

Archimate

… is an open and independent modeling language for enterprise architecture… is one of the open standards hosted by the Open Group and based on the IEEE 1471 standard… dis?nguishes itself from other languages such as UML and BPMN by its well defined metamodel, and wider enterprise modelling scope.

─ Wikipedia

48

Page 148: 支付宝 大规模Soa系统治理中的架构支持

描述企业架构的语言架构对齐

Archimate

… is an open and independent modeling language for enterprise architecture… is one of the open standards hosted by the Open Group and based on the IEEE 1471 standard… dis?nguishes itself from other languages such as UML and BPMN by its well defined metamodel, and wider enterprise modelling scope.

─ Wikipedia

48

Page 149: 支付宝 大规模Soa系统治理中的架构支持

描述企业架构的语言架构对齐

Archimate

… is an open and independent modeling language for enterprise architecture… is one of the open standards hosted by the Open Group and based on the IEEE 1471 standard… dis?nguishes itself from other languages such as UML and BPMN by its well defined metamodel, and wider enterprise modelling scope.

─ Wikipedia

48

Page 150: 支付宝 大规模Soa系统治理中的架构支持

描述企业架构的语言架构对齐

Archimate

… is an open and independent modeling language for enterprise architecture… is one of the open standards hosted by the Open Group and based on the IEEE 1471 standard… dis?nguishes itself from other languages such as UML and BPMN by its well defined metamodel, and wider enterprise modelling scope.

─ Wikipedia

48

Page 151: 支付宝 大规模Soa系统治理中的架构支持

描述企业架构的语言架构对齐

Archimate

… is an open and independent modeling language for enterprise architecture… is one of the open standards hosted by the Open Group and based on the IEEE 1471 standard… dis?nguishes itself from other languages such as UML and BPMN by its well defined metamodel, and wider enterprise modelling scope.

─ Wikipedia

48

Page 152: 支付宝 大规模Soa系统治理中的架构支持

描述企业架构的语言架构对齐

Archimate

… is an open and independent modeling language for enterprise architecture… is one of the open standards hosted by the Open Group and based on the IEEE 1471 standard… dis?nguishes itself from other languages such as UML and BPMN by its well defined metamodel, and wider enterprise modelling scope.

─ Wikipedia

48

Page 153: 支付宝 大规模Soa系统治理中的架构支持

统一的架构概念元素架构对齐

49

Page 154: 支付宝 大规模Soa系统治理中的架构支持

统一的架构概念元素架构对齐

行为 结构

49

Page 155: 支付宝 大规模Soa系统治理中的架构支持

统一的架构概念元素架构对齐

行为 结构

外部

内部

49

Page 156: 支付宝 大规模Soa系统治理中的架构支持

统一的架构概念元素架构对齐

行为 结构

外部

内部个体

集体

49

Page 157: 支付宝 大规模Soa系统治理中的架构支持

统一的架构概念元素架构对齐

行为 结构

外部

内部个体

集体

49

Page 158: 支付宝 大规模Soa系统治理中的架构支持

业务架构元素架构对齐

50

Page 159: 支付宝 大规模Soa系统治理中的架构支持

应用架构元素架构对齐

51

Page 160: 支付宝 大规模Soa系统治理中的架构支持

对齐业务与应用架构对齐

52

Page 161: 支付宝 大规模Soa系统治理中的架构支持

对齐业务与应用架构对齐

用我

52

Page 162: 支付宝 大规模Soa系统治理中的架构支持

对齐业务与应用架构对齐

用我

我帮你做

52

Page 163: 支付宝 大规模Soa系统治理中的架构支持

对齐业务与应用架构对齐

用我

我帮你做

放我这

52

Page 164: 支付宝 大规模Soa系统治理中的架构支持

对齐业务与应用架构对齐

用我

我帮你做

放我这

卖我也愿意

52

Page 165: 支付宝 大规模Soa系统治理中的架构支持

对应业务与应用架构对齐

53

Page 166: 支付宝 大规模Soa系统治理中的架构支持

对应业务与应用架构对齐

53

Page 167: 支付宝 大规模Soa系统治理中的架构支持

在演进中对齐架构对齐

当前业务

当前应用

对齐

企业架构

基线企业架构

54

Page 168: 支付宝 大规模Soa系统治理中的架构支持

在演进中对齐架构对齐

当前业务

当前应用

对齐

企业架构

基线企业架构

目标业务

目标应用

对齐

54

Page 169: 支付宝 大规模Soa系统治理中的架构支持

在演进中对齐架构对齐

当前业务

当前应用

对齐

企业架构

基线企业架构

目标业务

目标应用

对齐

目标企业架构

54

Page 170: 支付宝 大规模Soa系统治理中的架构支持

在演进中对齐架构对齐

当前业务

当前应用

对齐

企业架构

基线企业架构

目标业务

目标应用

对齐

目标企业架构

路线图

项目 项目项目

54

Page 171: 支付宝 大规模Soa系统治理中的架构支持

在演进中对齐架构对齐

当前业务

当前应用

对齐

企业架构

基线企业架构

目标业务

目标应用

对齐

目标企业架构

路线图

项目 项目项目

54

Page 172: 支付宝 大规模Soa系统治理中的架构支持

企业架构是动态的架构对齐

应用 技术

第0层企业->业务线

第1层业务线->产品

第2层产品->服务

第3层服务->功能

业务基线

55

Page 173: 支付宝 大规模Soa系统治理中的架构支持

企业架构是动态的架构对齐应用 技术

第0层企业->产品线

第1层产品线->产品

第2层产品->服务

第3层服务->操作

业务目标

应用 技术

第0层企业->业务线

第1层业务线->产品

第2层产品->服务

第3层服务->功能

业务基线

55

Page 174: 支付宝 大规模Soa系统治理中的架构支持

企业架构是动态的架构对齐应用 技术

第0层企业->产品线

第1层产品线->产品

第2层产品->服务

第3层服务->操作

业务目标

应用 技术

第0层企业->业务线

第1层业务线->产品

第2层产品->服务

第3层服务->功能

业务基线

原则/路线

55

Page 175: 支付宝 大规模Soa系统治理中的架构支持

敏捷!架构对齐

每日 任务 任务 任务

迭代每日工作

每日工作

每日工作

版本 迭代 迭代 迭代

项目 版本 版本 版本

敏捷项目过程

56

Page 176: 支付宝 大规模Soa系统治理中的架构支持

敏捷!架构对齐

每日 任务 任务 任务

迭代每日工作

每日工作

每日工作

版本 迭代 迭代 迭代

项目 版本 版本 版本

敏捷项目过程

架构 项目 项目 项目

企业架构过程

56

Page 177: 支付宝 大规模Soa系统治理中的架构支持

敏捷!架构对齐

每日 任务 任务 任务

迭代每日工作

每日工作

每日工作

版本 迭代 迭代 迭代

项目 版本 版本 版本

敏捷项目过程

业务敏捷

架构 项目 项目 项目

企业架构过程

56

Page 178: 支付宝 大规模Soa系统治理中的架构支持

展望

历史

问题

展望

SOA治理

架构透明 控

制 对齐

57

Page 179: 支付宝 大规模Soa系统治理中的架构支持

展望 与研发与IT治理集成

SOA生命周期过程

服务模型

SOA技术基础设施

政策模型

Repository服务资产管理

Registry服务运行管理

软件研发平台需求管理 软件配置管理 集成开发环境 单元测试

缺陷管理 构建与集成 测试平台 发布管理

代码分析

…….

系统管理 配置管理 事件管理 问题管理

58

Page 180: 支付宝 大规模Soa系统治理中的架构支持

展望 在治理中树人

59

Page 181: 支付宝 大规模Soa系统治理中的架构支持

展望 第7天,休息,去和领导下棋

应用 技术

第0层企业->业务线

第1层业务线->产品

第2层产品->服务

第3层服务->功能

业务目标

企业战略

60

Page 182: 支付宝 大规模Soa系统治理中的架构支持

致谢

支付宝架构组同事 创业路上一路同行的同事

技术社区的朋友 InfoQ, etc…

61