当前位置:网站首页>[answer] what does UML use to represent hexagonal architecture

[answer] what does UML use to represent hexagonal architecture

2022-06-12 00:39:00 User 6288414

Ryan 2022-1-10 14:45

I'm looking at the slides of your official account speech , There is a page for questions

Do you think it is recommended to use components to express , Is there a more suitable way ?

UMLChina Pan Jiayu

What I mean in my speech is just : If you want to use UML cater to DDD Of “ New words ”, perhaps DDD Of “ New words ” Want to put on a layer UML Skin , You can do this .

Actually , Use the structure diagram ( Class diagram 、 Component drawings, etc ) Express " framework " Inappropriate , Or say , Not enough .

Some of the things we usually see “ framework ”, It is just some routines of cooperation between domains . for example , The representations we usually see may be similar to this :

Since it is collaboration , You should use a behavior diagram ( Sequence diagram 、 Communication diagram, etc ) It means more suitable .

The picture you posted is from 《 Implement domain-driven design 》, There should be no sequence diagram in the book . By the way , The sequence diagrams in this book draw classes rather than instances on the lifeline , No colon , This is not true .

The most common “ Transfer accounts ” problem , There are probably two on the life line “ Account ” Class .

Similar problems , Others take the form of “ Domain-driven design ” There are also books named , Readers who are interested can turn to the books around you .

Hexagon structure , Refer to the sequence drawing of the adapter pattern , for example :

原网站

版权声明
本文为[User 6288414]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/03/202203011445163800.html