Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

discussion: Deprecation c4plantuml in favor of plantuml (plantuml-stdlib)? #1749

Open
arukiidou opened this issue May 6, 2024 · 0 comments

Comments

@arukiidou
Copy link
Contributor

arukiidou commented May 6, 2024

summary

c4plantuml URL was used in the past due to its history do you think plantuml should be preferred?

context

background

!include <C4/C4_Context>

title System Context diagram for Internet Banking System

Person(customer, "Banking Customer", "A customer of the bank, with personal bank accounts.")
System(banking_system, "Internet Banking System", "Allows customers to check their accounts.")

System_Ext(mail_system, "E-mail system", "The internal Microsoft Exchange e-mail system.")
System_Ext(mainframe, "Mainframe Banking System", "Stores all of the core banking information.")

Rel(customer, banking_system, "Uses")
Rel_Back(customer, mail_system, "Sends e-mails to")
Rel_Neighbor(banking_system, mail_system, "Sends e-mails", "SMTP")
Rel(banking_system, mainframe, "Uses")

plantuml-stdlib available.

plantuml-stdlib Better looking diagrams. kroki also supports several stdlibs.

#552

other example(AWS):

!include <awslib/AWSCommon>
!include <awslib/Groups/all>
!include <awslib/Compute/LambdaLambdaFunction>
!include <awslib/General/Documents>
!include <awslib/General/Multimedia>
!include <awslib/General/Tapestorage>
!include <awslib/General/User>
!include <awslib/MediaServices/ElementalMediaConvert>
!include <awslib/MachineLearning/Transcribe>
!include <awslib/Storage/SimpleStorageService>

' define custom group for Amazon S3 bucket
AWSGroupColoring(S3BucketGroup, #FFFFFF, AWS_COLOR_GREEN, plain)
!define S3BucketGroup(g_alias, g_label="Amazon S3 bucket") AWSGroupEntity(g_alias, g_label, AWS_COLOR_GREEN, SimpleStorageService, S3BucketGroup)

!procedure $stepnum($number) 
<back:black><color:white><b> $number </b></color></back>
!endprocedure

' Groups are rectangles with a custom style using stereotype - need to hide
hide stereotype
skinparam linetype ortho
skinparam rectangle {
    BackgroundColor AWS_BG_COLOR
    BorderColor transparent
}

rectangle "$UserIMG()\nUser" as user
AWSCloudGroup(cloud){
  RegionGroup(region) {
    S3BucketGroup(s3) {
      rectangle "$MultimediaIMG()\n\tvideo\t" as video
      rectangle "$TapestorageIMG()\n\taudio\t" as audio
      rectangle "$DocumentsIMG()\n\ttranscript\t" as transcript

      user -r-> video: $stepnum("1")\lupload
      video -r-> audio
      audio -r-> transcript
    }

    rectangle "$LambdaLambdaFunctionIMG()\nObjectCreated\nevent handler" as e1
    rectangle "$ElementalMediaConvertIMG()\nAWS Elemental\nMediaConvert" as mediaconvert
    rectangle "$TranscribeIMG()\nAmazon Transcribe\n" as transcribe
    
    video -d-> e1: $stepnum("2")
    e1 -[hidden]r-> mediaconvert
    mediaconvert -[hidden]r-> transcribe
    mediaconvert -u-> audio: $stepnum("3")
    transcribe -u-> transcript: $stepnum("4") 
    
    StepFunctionsWorkflowGroup(sfw) {
      rectangle "$LambdaLambdaFunctionIMG()\nextract audio" as sfw1
      rectangle "$LambdaLambdaFunctionIMG()\ntranscribe audio" as sfw2

      e1 -r-> sfw1: Start\nExecution
      sfw1 -r-> sfw2
      sfw1 -u-> mediaconvert
      sfw2 -u-> transcribe
    }
  }
}

https://kroki.io/plantuml/svg/eNqVVOFO2zAQ_u-nODqkEakoKuwX6ipB16FJMCTKxI91Qk58tB6OHTk2hU28C8_Ck8123CaBCGmV6rp3333f-e7sHS5zYRnCmK4rwbP0-Ho-VUWh5ITsvPadamXLKqVC9DhdVGkNpme0yBit169W5ob3c6FETUX6ReW2QGmqdzDnVhheIOP0HdAVLbEyStMlvoP6UaHucZ978jnqe55jlc4E-pSoCOapkveoTV8UzVdc4hlSLblcpleayirXPOvLYF7nls55UQqM_6LkhJCPwPDWkUFu3SkKWPpaw63ScFzQP0rC_BAym9-hIa5FoRNTJZR2unvzw5PgCdYhfPgaPkNwwJvpxdnF5c3p5Wz2fQiloFwmZCdKdeL2ljdUcFoNYXkjaIbi8-C18iCBjfZMGm4e38T0aPadd9iVTgjZKbXKkVmNsFsZLKUt9nbdkqFOgIwzmt8dZcKtk3Huj320XnGDk3E2eXmOuJfncZpNxmnwu18f4_qAkm25fZnrIQbqlDTmhsqlwArW3KyAbopfmUeBYCtXXLdHjco8lgj7IBEZGAUrzpD4peUm1R2XJdW0AOGqGyKUNivVcmwV4S8B9zlxOfpOSxaaGap3cloXsAYozVDXTuPHy_G40SRPhDRcg10_1t_OT_eShfTbAdDKpY_az8pUKMvqFud-m3jpS1y6e1lbddgnMaXuUFSHGztAW7C5klF2Ye5dOdTCBO2w7wlrXdJtHLWMb-LCvidu-0pso0y8a6WJoY2BRAJfANjX-5M6naNmsgajQbIQthSKsggOkBrdTiLsa3NLwHueapl2ln1PX0z4IvvtgFON1CBbSLx3h4EVlUzEbuHoDV3vMxT5XF9h61_INiLQhdbkteENcfNObdjqi97YF7JT0wwDB2kVirmK4Khd04NBEgA4gv2f7m4wlL983d6k0jZ0oa_0ukC7aU1b9DCKNpE1sGlWG_3JvWDNSebOvGlTda303a1Q6zj2t-v-uX-nxfjgRHNT5xjK51hG_8fROkaH5mAz0764vlKe-sidgGqzkLMHzK1niSDv3MIOOkbb15DgPOgWLrbgifjvE_kH0eG7jw==

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant