Skip to content

Commit fd46c4c

Browse files
authored
Merge pull request #44 from travisnielsen/release/2-2
Release/2 2
2 parents 4e8a024 + 744675c commit fd46c4c

8 files changed

+73
-41
lines changed

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MIT License
22

3-
Copyright (c) 2018 Ricardo Niepel
3+
Copyright (c) 2018-2019 Ricardo Niepel, 2021-2022 Ricardo Niepel and contributors
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 14 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
# Azure-PlantUML
22

3-
![Basic usage - Stream processing with Azure Stream Analytics](http://www.plantuml.com/plantuml/proxy?idx=0&src=https%3A%2F%2Fraw.githubusercontent.com%2Fplantuml-stdlib%2FAzure-PlantUML%2Fmaster%2Fsamples%2FBasic%2520usage%2520-%2520Stream%2520processing%2520with%2520Azure%2520Stream%2520Analytics.puml)
4-
53
[PlantUML](http://en.plantuml.com/) sprites, macros and stereotypes for creating PlantUML diagrams with [Azure](https://azure.microsoft.com/en-us/) components.
64

75
Azure-PlantUML includes symbols and useful macros for all Azure services.
@@ -61,7 +59,7 @@ To be independent of any internet connectivity, you can also download `AzureComm
6159
If you want to use the always up-to-date version in this repo, use the following:
6260

6361
```c#
64-
!includeurl https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-1/dist/AzureCommon.puml
62+
!includeurl https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-2/dist/AzureCommon.puml
6563
```
6664

6765
The next step is to include specific `.puml` files from Azure-PlantUML.
@@ -78,7 +76,7 @@ It is also possible to include Azure services category `.puml` files, which cont
7876
Or the always up-to-date version in this repo:
7977

8078
```c#
81-
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-1/dist
79+
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-2/dist
8280
!includeurl AzurePuml/AzureCommon.puml
8381
!includeurl AzurePuml/Databases/all.puml
8482
!includeurl AzurePuml/Compute/AzureFunction.puml
@@ -92,7 +90,7 @@ All Azure services names, categories, colored and monochrom symbols, and their `
9290

9391
```csharp
9492
@startuml Hello World
95-
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-1/dist
93+
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-2/dist
9694
!includeurl AzurePuml/AzureCommon.puml
9795
!includeurl AzurePuml/Databases/all.puml
9896
!includeurl AzurePuml/Compute/AzureFunction.puml
@@ -124,10 +122,10 @@ Just import the necessary `.puml` files and you can use the macros in all your P
124122
```csharp
125123
@startuml Basic usage - Stream processing with Azure Stream Analytics
126124

127-
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-1/dist
125+
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-2/dist
128126
!includeurl AzurePuml/AzureCommon.puml
129127
!includeurl AzurePuml/Analytics/AzureEventHub.puml
130-
!includeurl AzurePuml/Analytics/AzureStreamAnalytics.puml
128+
!includeurl AzurePuml/Analytics/AzureStreamAnalyticsJob.puml
131129
!includeurl AzurePuml/Databases/AzureCosmosDb.puml
132130

133131
left to right direction
@@ -136,7 +134,7 @@ agent "Device Simulator" as devices #fff
136134

137135
AzureEventHub(fareDataEventHub, "Fare Data", "PK: Medallion HackLicense VendorId; 3 TUs")
138136
AzureEventHub(tripDataEventHub, "Trip Data", "PK: Medallion HackLicense VendorId; 3 TUs")
139-
AzureStreamAnalytics(streamAnalytics, "Stream Processing", "6 SUs")
137+
AzureStreamAnalyticsJob(streamAnalytics, "Stream Processing", "6 SUs")
140138
AzureCosmosDb(outputCosmosDb, "Output Database", "1,000 RUs")
141139

142140
devices --> fareDataEventHub
@@ -158,7 +156,7 @@ If you just want to use the PlantUML sprites inside your existing diagrams, this
158156
@startuml Raw usage - Sprites
159157
!pragma revision 1
160158

161-
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-1/dist
159+
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-2/dist
162160
!includeurl AzurePuml/AzureRaw.puml
163161
!includeurl AzurePuml/Databases/AzureCosmosDb.puml
164162
!includeurl AzurePuml/Compute/AzureFunction.puml
@@ -191,9 +189,8 @@ To enable the simplified mode `AzureSimplified.puml` needs to be included or can
191189

192190
```csharp
193191
@startuml Two Mode Sample
194-
!pragma revision 1
195192

196-
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-1/dist
193+
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-2/dist
197194
!includeurl AzurePuml/AzureCommon.puml
198195

199196
' !includeurl AzurePuml/AzureSimplified.puml
@@ -202,7 +199,7 @@ To enable the simplified mode `AzureSimplified.puml` needs to be included or can
202199
!includeurl AzurePuml/Compute/AzureFunction.puml
203200
!includeurl AzurePuml/Databases/AzureCosmosDb.puml
204201
!includeurl AzurePuml/Storage/AzureDataLakeStorage.puml
205-
!includeurl AzurePuml/Analytics/AzureStreamAnalytics.puml
202+
!includeurl AzurePuml/Analytics/AzureStreamAnalyticsJob.puml
206203
!includeurl AzurePuml/InternetOfThings/AzureTimeSeriesInsights.puml
207204
!includeurl AzurePuml/Identity/AzureActiveDirectoryB2C.puml
208205
!includeurl AzurePuml/DevOps/AzureApplicationInsights.puml
@@ -212,7 +209,7 @@ LAYOUT_LEFT_RIGHT
212209

213210
AzureEventHub(rawEventsHubAlias, "Raw Event Hub", "PK: Medallion HackLicense VendorId; 3 TUs")
214211
AzureDataLakeStorage(datalakeAlias, "Data Lake", "GRS")
215-
AzureStreamAnalytics(streamAnalyticsAlias, "Aggregate Events", "6 SUs")
212+
AzureStreamAnalyticsJob(streamAnalyticsAlias, "Aggregate Events", "6 SUs")
216213
AzureFunction(stateFunctionAlias, "State Processor", "C#, Consumption Plan")
217214
AzureEventHub(aggregatedEventsHubAlias, "Aggregated Hub", "6 TUs")
218215
AzureCosmosDb(stateDBAlias, "State Database", "SQL API, 1000 RUs")
@@ -253,7 +250,7 @@ For using **Azure-PlantUML** and [C4-PlantUML](https://github.com/plantuml-stdli
253250

254251
!includeurl https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Container.puml
255252
256-
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-1/dist
253+
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/release/2-2/dist
257254
!includeurl AzurePuml/AzureCommon.puml
258255

259256
!includeurl AzurePuml/AzureC4Integration.puml
@@ -298,13 +295,14 @@ All details can be found in the [Generating the Azure-PlantUML distro documentat
298295

299296
## Built With
300297

301-
* [dotnet script](https://github.com/filipw/dotnet-script) - C# script runtime
298+
* [.NET 6.0 / C#](https://dotnet.microsoft.com/en-us/download) - The latest LTS version of .NET
302299
* [YamlDotNet](https://github.com/aaubry/YamlDotNet) - .NET library for YAML config parsing
303300
* [Json.NET](https://github.com/JamesNK/Newtonsoft.Json) - .NET library for JSON
301+
* [Playwright](https://github.com/microsoft/playwright) - .NET library for the Playwright web testing and automation framework
304302

305303
## Contributing
306304

307-
If you have any ideas, just [open an issue](https://github.com/plantuml-stdlib/Azure-PlantUML/issues/new) and tell me what you think.
305+
If you have any ideas, just [open an issue](https://github.com/plantuml-stdlib/Azure-PlantUML/issues/new) and tell us what you think.
308306

309307
If you'd like to contribute, please fork the repository and use a feature branch.
310308
Pull requests are warmly welcome.
@@ -318,4 +316,3 @@ This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md
318316
* [AWS-PlantUML](https://github.com/milo-minderbinder/AWS-PlantUML) - for the base structure
319317
* [plantuml-office](https://github.com/Roemer/plantuml-office) - for the scripts idea
320318
* [C4 Model](https://c4model.com/) - for the hope that it's possible to improve architecture documentations
321-

samples/Basic usage - Stream processing with Azure Stream Analytics.puml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
@startuml Basic usage - Stream processing with Azure Stream Analytics
2-
!pragma revision 2
32

43
!define AzurePuml https://raw.githubusercontent.com/plantuml-stdlib/Azure-PlantUML/master/dist
54
!includeurl AzurePuml/AzureCommon.puml
65
!includeurl AzurePuml/Analytics/AzureEventHub.puml
7-
!includeurl AzurePuml/Analytics/AzureStreamAnalytics.puml
6+
!includeurl AzurePuml/Analytics/AzureStreamAnalyticsJob.puml
87
!includeurl AzurePuml/Databases/AzureCosmosDb.puml
98

109
left to right direction
@@ -13,7 +12,7 @@ agent "Device Simulator" as devices #fff
1312

1413
AzureEventHub(fareDataEventHub, "Fare Data", "PK: Medallion HackLicense VendorId; 3 TUs")
1514
AzureEventHub(tripDataEventHub, "Trip Data", "PK: Medallion HackLicense VendorId; 3 TUs")
16-
AzureStreamAnalytics(streamAnalytics, "Stream Processing", "6 SUs")
15+
AzureStreamAnalyticsJob(streamAnalytics, "Stream Processing", "6 SUs")
1716
AzureCosmosDb(outputCosmosDb, "Output Database", "1,000 RUs")
1817

1918
devices --> fareDataEventHub

samples/C4 usage - IoT Reference Architecture - Stateful stream processing.puml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
!includeurl AzurePuml/AzureCommon.puml
88
!includeurl AzurePuml/AzureC4Integration.puml
99
!includeurl AzurePuml/Compute/AzureFunction.puml
10-
!includeurl AzurePuml/Analytics/AzureStreamAnalytics.puml
10+
!includeurl AzurePuml/Analytics/AzureStreamAnalyticsJob.puml
1111
!includeurl AzurePuml/Analytics/AzureEventHub.puml
1212
!includeurl AzurePuml/Databases/AzureCosmosDb.puml
1313
!includeurl AzurePuml/Storage/AzureBlobStorage.puml
@@ -24,7 +24,7 @@ AzureEventHub(eventHubTelemetry, "Device Telemetry", "Standard, 5 TUs, 4 Partiti
2424
AzureFunction(telemetryFunction, "Telemetry Processing", "v1, App Service plan P3v2, C#", "transform it into a different format, e.g. joining external information")
2525
AzureCosmosDb(warmStorageCosmos, "Warm Storage", "2,000 RUs", "for consumption, e.g. display on a dashboard")
2626

27-
AzureStreamAnalytics(streamAnalytics, "Stream Analytics", "6 SUs", "apply complex queries over time periods, tolerates late (up to 21 days) and out-of-order (up to one hour) events")
27+
AzureStreamAnalyticsJob(streamAnalytics, "Stream Analytics", "6 SUs", "apply complex queries over time periods, tolerates late (up to 21 days) and out-of-order (up to one hour) events")
2828
AzureFunction(alertingFunction, "Alerting", "v2, Consumption plan, JS")
2929

3030
AzureBlobStorage(coldBlobStorage, "Cold Storage", "General Purpose v2, Cool, RA-GRS", "all incoming data records are archived indefinitely at low cost, and are easily accessible for batch processing")

samples/Two Mode Sample - Normal.puml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
!includeurl AzurePuml/Compute/AzureFunction.puml
1111
!includeurl AzurePuml/Databases/AzureCosmosDb.puml
1212
!includeurl AzurePuml/Storage/AzureDataLakeStorage.puml
13-
!includeurl AzurePuml/Analytics/AzureStreamAnalytics.puml
13+
!includeurl AzurePuml/Analytics/AzureStreamAnalyticsJob.puml
1414
!includeurl AzurePuml/InternetOfThings/AzureTimeSeriesInsights.puml
1515
!includeurl AzurePuml/Identity/AzureActiveDirectoryB2C.puml
1616
!includeurl AzurePuml/DevOps/AzureApplicationInsights.puml
@@ -20,7 +20,7 @@ LAYOUT_LEFT_RIGHT
2020

2121
AzureEventHub(rawEventsHubAlias, "Raw Event Hub", "PK: Medallion HackLicense VendorId; 3 TUs")
2222
AzureDataLakeStorage(datalakeAlias, "Data Lake", "GRS")
23-
AzureStreamAnalytics(streamAnalyticsAlias, "Aggregate Events", "6 SUs")
23+
AzureStreamAnalyticsJob(streamAnalyticsAlias, "Aggregate Events", "6 SUs")
2424
AzureFunction(stateFunctionAlias, "State Processor", "C#, Consumption Plan")
2525
AzureEventHub(aggregatedEventsHubAlias, "Aggregated Hub", "6 TUs")
2626
AzureCosmosDb(stateDBAlias, "State Database", "SQL API, 1000 RUs")

samples/Two Mode Sample - Simplified.puml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
!includeurl AzurePuml/Compute/AzureFunction.puml
1111
!includeurl AzurePuml/Databases/AzureCosmosDb.puml
1212
!includeurl AzurePuml/Storage/AzureDataLakeStorage.puml
13-
!includeurl AzurePuml/Analytics/AzureStreamAnalytics.puml
13+
!includeurl AzurePuml/Analytics/AzureStreamAnalyticsJob.puml
1414
!includeurl AzurePuml/InternetOfThings/AzureTimeSeriesInsights.puml
1515
!includeurl AzurePuml/Identity/AzureActiveDirectoryB2C.puml
1616
!includeurl AzurePuml/DevOps/AzureApplicationInsights.puml
@@ -20,7 +20,7 @@ LAYOUT_LEFT_RIGHT
2020

2121
AzureEventHub(rawEventsHubAlias, "Raw Event Hub", "PK: Medallion HackLicense VendorId; 3 TUs")
2222
AzureDataLakeStorage(datalakeAlias, "Data Lake", "GRS")
23-
AzureStreamAnalytics(streamAnalyticsAlias, "Aggregate Events", "6 SUs")
23+
AzureStreamAnalyticsJob(streamAnalyticsAlias, "Aggregate Events", "6 SUs")
2424
AzureFunction(stateFunctionAlias, "State Processor", "C#, Consumption Plan")
2525
AzureEventHub(aggregatedEventsHubAlias, "Aggregated Hub", "6 TUs")
2626
AzureCosmosDb(stateDBAlias, "State Database", "SQL API, 1000 RUs")

scripts/GeneratePuml.csproj

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@
88
</PropertyGroup>
99

1010
<ItemGroup>
11-
<PackageReference Include="Microsoft.Extensions.Configuration" Version="6.0.0" />
12-
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="6.0.0" />
13-
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="6.0.0" />
14-
<PackageReference Include="Microsoft.Extensions.Hosting" Version="6.0.0" />
15-
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="6.0.0" />
16-
<PackageReference Include="YamlDotNet" Version="11.2.1" />
17-
<PackageReference Include="Microsoft.Playwright" Version="1.21.0" />
18-
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
11+
<PackageReference Include="Microsoft.Extensions.Configuration" Version="7.0.0" />
12+
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="7.0.0" />
13+
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="7.0.0" />
14+
<PackageReference Include="Microsoft.Extensions.Hosting" Version="7.0.0" />
15+
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="7.0.0" />
16+
<PackageReference Include="YamlDotNet" Version="12.3.1" />
17+
<PackageReference Include="Microsoft.Playwright" Version="1.28.0" />
18+
<PackageReference Include="Newtonsoft.Json" Version="13.0.2" />
1919
</ItemGroup>
2020

2121
</Project>

scripts/README.md

Lines changed: 42 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,17 @@ playwright install-deps
2828

2929
## Configure
3030

31-
### Icon files
31+
### Add Icon files
3232

3333
Download the [Microsoft Azure architecture icons](https://docs.microsoft.com/en-us/azure/architecture/icons/) and copy all folders from `Azure_Public_Service_Icons_V4\Azure_Public_Service_Icons\Icons` to [source/official](../source/official)
3434

3535
Place any icons that are not part of the Microsoft Azure Architecture bundle into [source/manual](../source/manual). For additional icons not in the official set, we suggest using the [Amazing Icon Downloader](https://chrome.google.com/webstore/detail/amazing-icon-downloader/kllljifcjfleikiipbkdcgllbllahaob/)
3636

3737
### Application Settings
3838

39-
Create a new file named `appsettings.json` within the `scripts` directory and save the following contents:
39+
Create a new file named `appsettings.json` within the `scripts` directory and add the following content based on your environment:
40+
41+
**Windows**
4042

4143
```json
4244
{
@@ -47,12 +49,42 @@ Create a new file named `appsettings.json` within the `scripts` directory and sa
4749
}
4850
```
4951

50-
### Configuration File: Config.yaml
52+
**Ubuntu**
5153

52-
This configuration file is used to map specific SVG file names to Azure services.
53-
On top each Azure service is mapped to his primary category.
54+
```json
55+
{
56+
"sourceFolderPath": "../source",
57+
"targetFolderPath": "../dist",
58+
"monochromeColorHex": "#0072C6",
59+
"plantUmlPath": "/usr/share/plantuml/plantuml.jar"
60+
}
61+
```
5462

55-
## Run
63+
**MacOS**
64+
65+
```json
66+
{
67+
"sourceFolderPath": "../source",
68+
"targetFolderPath": "../dist",
69+
"monochromeColorHex": "#0072C6",
70+
"plantUmlPath": "/opt/homebrew/Cellar/plantuml/1.2022.14/libexec/plantuml.jar"
71+
}
72+
```
73+
74+
> The path to PlantUML may vary based on the version you are using and how you installed it. Be sure to update the value for `plantUmlPath` accordingly to match your envioronment.
75+
76+
### Update Config.yaml
77+
78+
Update this file to add or remove icons in your distro. The `source` attribute represents the svg file name. Logic has been added to the PlantUML generation program to simplify the value used here. Dashes, spaces, and certain prefixes and suffixes are removed when searching for source files. For example, adding **App Service Plan Linux** will work for the following source files:
79+
80+
* <b>00046-icon-service-</b>App-Service-Plan-Linux.svg
81+
* App-Service-Plan-Linux<b>_COLOR</b>.svg
82+
* App-Service-Plan-Linux.svg
83+
84+
85+
The `target` attribute will be used for the PlantUML element stereotype and all target file names. Keep in mind that services are grouped into categories as reflected in the YAML structure.
86+
87+
## Generate PlantUML Elements
5688

5789
Use `dotnet run` from the `scripts` folder to execute the application.
5890

@@ -77,3 +109,7 @@ From a logical point of view, the following happens:
77109
1. In addition to single Azure services PUML files, also a combined PUML file per category is generated
78110
1. A markdown table with all Azure services, their colored and monochrome symbols and the PUML files is generated
79111
1. VSCode snippets for all Azure services for their PlantUML usage are generated
112+
113+
## Update the Azure Symbols page
114+
115+
When the program completes, replace the markdown table in [AzureSymbols.md](https://github.com/plantuml-stdlib/Azure-PlantUML/blob/release/2-2/AzureSymbols.md?plain=1#L34) with the contents from `table.md` located in your target folder.

0 commit comments

Comments
 (0)