{"id":13560731,"url":"https://github.com/plantuml-stdlib/EIP-PlantUML","last_synced_at":"2025-04-03T16:31:03.315Z","repository":{"id":41852318,"uuid":"148833730","full_name":"plantuml-stdlib/EIP-PlantUML","owner":"plantuml-stdlib","description":"EIP-PlantUML adds Enterprise Integrations Patterns elements to PlantUML to provide easy support of designing EIP architectures for both, up-front design as well as development-time automated documentation generation.","archived":false,"fork":false,"pushed_at":"2022-08-21T18:36:17.000Z","size":397,"stargazers_count":101,"open_issues_count":12,"forks_count":19,"subscribers_count":12,"default_branch":"main","last_synced_at":"2025-03-29T07:33:43.308Z","etag":null,"topics":["architecture","diagrams","eip","integration","plantuml"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/plantuml-stdlib.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-09-14T19:35:39.000Z","updated_at":"2025-03-07T16:59:15.000Z","dependencies_parsed_at":"2022-08-11T19:30:40.537Z","dependency_job_id":null,"html_url":"https://github.com/plantuml-stdlib/EIP-PlantUML","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/plantuml-stdlib%2FEIP-PlantUML","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/plantuml-stdlib%2FEIP-PlantUML/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/plantuml-stdlib%2FEIP-PlantUML/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/plantuml-stdlib%2FEIP-PlantUML/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/plantuml-stdlib","download_url":"https://codeload.github.com/plantuml-stdlib/EIP-PlantUML/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247036940,"owners_count":20873054,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["architecture","diagrams","eip","integration","plantuml"],"created_at":"2024-08-01T13:00:49.046Z","updated_at":"2025-04-03T16:31:02.775Z","avatar_url":"https://github.com/plantuml-stdlib.png","language":"C#","funding_links":[],"categories":["C#"],"sub_categories":[],"readme":"# EIP-PlantUML\n\nEIP-PlantUML provides [Enterprise Integrations Patterns](https://www.enterpriseintegrationpatterns.com/) elements to [PlantUML](http://plantuml.com/) to provide easy support of designing EIP architectures for both, up-front design as well as development-time automated documentation generation.  \n\n## Important Information \n\nPlease bear in mind this repository is currently *Work in Progress* - therefore new features might be added regularly and breaking changes might be introduced more often than not. \n\n\n## Getting Started\n\nYou will need to download the `EIP-PlantUML.puml` file from the dist folder.  \nThis files includes everything you need to use the EIP patterns in your PlantUML diagramms.\n\nAt the top of your PlantUML model you need to include the `EIP-PlantUML.puml` file.\n\n```c#\n!include ../EIP-PlantUML/EIP-PlantUML.puml\n```\n\nIf you want to include the most recent version of the `EIP-PlantUML.puml` file, you can alternatively use \n\n```c#\n!includeurl https://raw.githubusercontent.com/plantuml-stdlib/EIP-PlantUML/main/dist/EIP-PlantUML.puml\n```\n\nto link to the latest version available in the master repository.\n\nAfter including the `EIP-PlantUML.puml` file you can start using the EIP patterns as shown below. \n\n```c#\nMsgChannel(channel1, \"Channel 1\")\nMsgChannel(channel2, \"Channel 2\")\nMessage(msg, \"Message\")\n\nSend(channel1, msg)\nSend(msg, channel2)\n```\n![Message Example](images/message_example.png)\n\n## Supported Pattern \nThe following pattern are currently supported:\n\n### \n\n| Category | Pattern | Macro | Image | Image URL |\n| -------- | ------- | ----- | ----- | --------- |\n| Message Construction | Message | `Message(alias [,label])` | ![](/sprites/message.png) | | \n| Message Construction | Command Message | `CommandMessage(alias [,label])` | | | \n| Message Construction | Document Message | `DocumentMessage(alias [,label])`| | | \n| Message Construction | Event Message | `EventMessage(alias [,label])` | | | \n| Message Construction | Request-Reply | `RequestReply(alias [,label])` | | | \n| Message Construction | Return Address | `ReturnAddress(alias [,label])` | | | \n| Message Construction | Correlation Identifer | `CorrelationIdentifier(alias [,label])`| | | \n| Message Construction | Message Sequence | `MessageSequence(alias [,label])`| | | \n| Message Construction | Message Expiration | `MessageExpiration(alias [,label])`| | | \n| Message Construction | Format Indicator | NA | | | \n| Message Routing | Pipes and Filters | `Pipe(from, to)` ||||\n| Message Routing | Pipes and Filters | `Filter(alias [,label])` | | | |\n| Message Routing | Message Router | `MessageRouter(alias [,label])` | | | |\n| Message Routing | Message Filter | `MessageFilter(alias [,label])` | | | |\n| Message Routing | Dynamic Router | `DynamicRouter(alias [,label], dynamicrulebase)` | | | |\n| Message Routing | Recipient List | `RecipientList(alias [,label])` | | | |\n| Message Routing | Splitter | `Splitter(alias [,label])` | | | |\n| Message Routing | Aggregator | `Aggregator(alias [,label])` | | | |\n| Message Routing | Resequencer | `Resequencer(alias [,label])` | | | |\n| Message Routing | Composed Message Processor | `ComposedMessageProcessor(alias [,label])` | | | |\n| Message Routing | Scatter-Gather | TBD | | | |\n| Message Routing | Routing Slip | `RoutingSlip(alias [,label])` | | | |\n| Message Routing | Process Manager | `ProcessManager(alias [,label])` | | | |\n| Message Routing | Message Broker | `MessageBroker(alias [,label])` | | | |\n\n### Message Transformation\n\n* Message Translator\n    * `MessageTranslator(alias [,label])`\n* Envelope Wrapper\n    * `Wrapper(alias [,label])`    \n    * `Unwrapper(alias [,label])`\n* Data Enricher (also Content Enricher)\n    * `DataEnricher(alias [,label], datasource)`\n* Content Filter\n    * `ContentFilter(alias [,label])`\n* Claim Check\n    * `Item(alias) \u003c\u003c$claim_check\u003e\u003e`\n    * `Item(alias, \"\u003c$claim_check\u003e\")`\n    * `Item(alias, \"label \u003c$claim_check\u003e\")`\n* Normalizer\n    * `Normalizer(alias [,label])`\n* Canonical Data Model\n    * TBD\n\n### Messaging Endpoints\n\n* Message Endpoint\n    * `MessageEndpoint(alias [,label])`\n* Messaging Gateway\n    * `MessagingGateway(alias [,label])`\n* Messaging Mapper\n    * `MessagingMapper(alias [,label])`\n* Transactional Client\n    * `TransactionalProducer(alias [,label])`\n    * `TransactionalConsumer(alias [,label])`\n* Polling Consumer\n    * `PollingConsumer(alias [,label])`\n* Event-Driven Consumer\n    * `EventDrivenConsumer(alias [,label])`\n* Competing Consumers\n    * TBD\n* Message Dispatcher\n    * `MessageDispatcher(alias [,label])`\n* Selective Consumer (Message Selector)\n    * `SelectiveConsumer(alias [,label])`\n* Durable Subscription\n    * `DurableSubscriber(alias [,label])`\n    * `NonDurableSubscriber(alias [,label])`\n* Idempotent Receiver \n    * TBD\n* Service Activator\n    * `ServiceActivator(alias [,label])`\n\n### Messaging Channels\n\n * Messaging Channel\n    * `MsgChannel(alias [,label])`\n* Point-to-Point Channel\n    * `P2PChannel(alias [,label] )`\n* Publish-Subscribe Channel\n    * `PubSubChannel(alias [,label])`\n * Datatype Channel\n    * `DatatypeChannel(alias [,label])`\n* Invalid Message Channel\n    * `InvalidMsgChannel(alias [,label])`\n* Dead Letter Channel\n    * `DeadLetterChannel(alias [,label])`\n* Quaranteed Deliver\n    * TBD\n* Channel Adapter\n    * `ChannelAdapterLeft(alias [,label])`\n    * `ChannelAdapterRight(alias [,label])`\n* Messaging Bridge \n    * `MsgBridge(alias [,label])`\n* Message Bus \n    * `MsgBus(alias [,label])`\n\n### System Managmenet\n\n* Control Bus\n    * `ControlBus(alias)` \n* Detour\n    * `Detour(alias [,label])`\n* Wire Tap\n    * `WireTap(alias [,label])`\n* Message History\n    * TBD\n* Message Store\n    * `MessageStore(alias [,label])`\n* Smart Proxy\n    * `SmartProxy(alias [,label])`\n* Test Message\n    * `TestMessage(alias [,label])`\n* Channel Purger\n    * `ChannelPurger(alias [,label])` \n\n## Examples \n\n### Dynamic Message Router \nThe dynamic message router is one of the more complex patterns. To apply this stencil, you must defne the dynamic rule base to be used for this router. \n\nThe following exmaple\n\n```csharp\nrectangle \"Dynamic Rulebase\" as rulebase\nDynamicRouter(dynamicrouter, \"My Dynamic Router\", rulebase)\n\nMessage(msg, \"My Message\")\nSend(msg, dynamicrouter)\n\nMsgChannel(queue1, \"My Destination 1\")\nSend(dynamicrouter, queue1)\n\nMsgChannel(queue2, \"My Destination 2\")\nSend(dynamicrouter, queue2)\n```\nresults in the graphic below:\n\n![Dynamic Message Router Example](images/dynamicrouter_example.png)\n\n### Claim Check \n\nThe Claim Check pattern can be applied to other patterns. There are several ways, this can done using the EIP-PlantUML as shown by the following example. It can be either used as alternative sterotype, as iconic label or as a label combined with a label text.\n\n```csharp\nContentFilter(filter1) \u003c\u003c$claim_check\u003e\u003e\n\nContentFilter(filter2, \"\u003c$claim_check\u003e\")\n\nContentFilter(filter3, \"secure filter \u003c$claim_check\u003e\")\n```\n\n![Claim Check Example](images/claim_check.png)\n\n### Messaging Mapper \n\nThe Messaging Mapper transforms domain objects into messages required by the messaging mapper and vice versa. \n\nTherefore, EAI-PlantUML introduces the following metapher for the Messaging Mapper.\n\n![Messaging Mapper Metapher](images/messaging_mapper.png)\n\nThe original example introduced by G. Hoppe then can be written like\n```csharp\nrectangle \"Business Object\" as obj\ncomponent [Messaging\\nInfrastructure] as infra\nMessagingMapper(mapper, \"Messaging Mapper\") \nobj -- mapper\nSend(mapper, infra)\n```\n\n![Messaging Mapper Example](images/messaging_mapper_example.png)\n\n### Control Bus \n\nA Control Bus is used to manage an enterprise integration system. It uses the same messaging mechanism used by the application data, but uses separate channels to transmit data that is relevant to the management of components involved in the message flow.\n\nThe following example shows how to create the ![original Control Bus example](https://www.enterpriseintegrationpatterns.com/patterns/messaging/ControlBus.html)  easily with PlantUML while connecting each system using the `\u003c--\u003e` command.\n\n```csharp\nrectangle System1\nrectangle System2\nrectangle System3 \n\nMessage(source) \nMessage(target) \n\nControlBus(\"cb\") \n\nSend(source, System1) \nSend(System1, System2) \nSend(System2, System3) \nSend(System3, target) \n\nSystem1 \u003c--\u003e cb \nSystem2 \u003c--\u003e cb \nSystem3 \u003c--\u003e cb \n```\n\n![Contol Bus Example](images/control_bus_example.png)\n\n## Additional Features \n\n## Stereotypes\nWhile stereotypes are great for new users and small examples, documentation frequently used often does not need this additional metadata. Therefore, stereotypes can be swithed off for the overall diagramm using `HIDE_STEREOTYPES()`.\n\nThe following example shows an example with hidden sterotypes. \n\n```csharp \nHIDE_STEREOTYPES()\n\nMessage(src, \"source\")\nMsgChannel(queue, \"queue\")\nMessage(dest, \"destination\")\nSend(src, queue)\nSend(queue, dest)\n````\n![Diagram without stereotypes ](images/hide_stereotypes.png)\n\n## Horizontal Layout \nIn some cases it is required to use a horizontal layout.\nYou can force this layout by calling \n\n```csharp\nLAYOUT_LEFT_RIGHT()\n```\n\n## Tests\n\nTests and scripts are located in the `test`folder of this project.\n\n### Test Script: testlabel.sh \n\nIn issue #29 there was an issue reported where `_labels` have been not rendered. This ussue was reported on Windows 10 using PLantUML v1.2019.8. To avoid this, in the definition string, the label declaration has to be precendet by a space. This test script verifies this requirement. The script return `0`if the test is passend, `1`otherwise. \n\n```bash\n FAILED: Issues detected\n420:!define ChannelAdapterLeft(_alias, _label) rectangle \"\u003c$channel_adapter_left\u003e\\r_label\" as _alias \u003c\u003cchannel adapter left\u003e\u003e \n422:!define ChannelAdapterRight(_alias, _label) rectangle \"\u003c$channel_adapter_right\u003e\\r_label\" as _alias \u003c\u003cchannel adapter right\u003e\u003e \nAndreassMacBook:test andreas$ ./testlabel.sh \n PASSED: No issues detected.\n ```\n\n## Background\nEnterprise Intergartion Patterns are a set of 65 patterns, mainly based on messaging concepts introduced Gregor Hohpe and Bobby Woolf. The Website [Enterprise Integration Patterns](https://www.enterpriseintegrationpatterns.com/) provides an extensive overview of these patterns. \n\nThese patterns come in handy when dealing with large scale enterprise architectures especially based on messaging systems. \n\nWhile documenting large systems with manual tools like Microsoft Visio takes an enourmous amount of time, [PlantUML](http://plantuml.com/) provides an elegant way of coding such architecures top-down or creating documentation based on your source codes. \n\nThere fore the EIP patterns is designed to support this bottom up documentation. The EIP patterns also play well with the [C4-PlantUML](https://github.com/RicardoNiepel/C4-PlantUML) extension by Ricardo Niepel when it comes to Level 4 of the C4 model. \n\nThe [C4 Model](http://c4model.com/) is a elegant way introduced by Simon Brow for describing and communicating software architectures up-front. \n\n## Feedback\n\n[@aheil](https://twitter.com/aheil)\\\n[#eipplantuml](https://twitter.com/hashtag/eipplantuml?src=hash)\n\n## Contribution\n\nIf interested in contributing to this project, please make sure to read the [Contribution Guidelines](https://github.com/aheil/EIP-PlantUML/blob/master/CONTRIBUTING.md) first. \n\n## Further References\n* [AWS-PlantUML](https://github.com/milo-minderbinder/AWS-PlantUML)\n* [Office Icons for PlantUML](https://github.com/Roemer/plantuml-office)\n* [Azure-PlantUML](https://github.com/RicardoNiepel/Azure-PlantUML)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fplantuml-stdlib%2FEIP-PlantUML","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fplantuml-stdlib%2FEIP-PlantUML","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fplantuml-stdlib%2FEIP-PlantUML/lists"}