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

Destroying a participant after completion of alt is not possible without extra message #5143

Open
Vogel612 opened this issue Dec 13, 2023 · 0 comments
Labels
Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect

Comments

@Vogel612
Copy link

Description

The following is a simplified diagram that renders in the live editor, including the destroy directive right in front of an alt block.
Unfortunately the participant is not destroyed when rendering this diagram:

Steps to reproduce

sequenceDiagram
    participant R as Request

    create participant A
    R->>A: POST /enqueue
    A->>A: validate
    
    destroy A
    alt isValid
        A-)Q: Enqueue Message
        A->>R: 202 Accepted
    else isError
        A->>R: Validation Error Reply
    end

    Q->>Q: Queue Shenanigans
    Q-)R: Async Reply

    box transparent Service
    participant A as API
    participant Q as Queue
    end

Screenshots

Screenshot of Live Editor - Develop rendering the sequence diagram above

Code Sample

https://develop.git.mermaid.live/edit#pako:eNplUT1rwzAQ_SuHtkBKS0YNBkEzdCiN7ZLJy1W-OiK25EpyqAn57z1HNm2xBiHufdzd01VoV5OQItDXQFbTs8HGY1dZ4NOjj0abHm2EAjBAMbFCrGzCtSeM9I-mElI8ZJmScHgr3-GRLKsGSohKyAVbU7M4FdNds7V34-KBbQQTjhMxFZJ8k0vYJ0d4pRCwob9wlhUSdk87UFpTH2nWUhuI3fbeO7-iH9Mwxlm4E3jPvh1noa2XdXNmc_P83ro8kUVrGrRhQTdspcJo9aJPwIf7huiZxzkRR1SSvxhN64jVFLE6vKyRfELy3xB5KLEVHfkOTc2_d53KlYgn6qgSkp81-nMlKntjHg7RlTyWkNEPtBVDPyU__7SQn8jZ3H4AynClPg

Setup

  • Mermaid version: 10.6.1+6e64556
  • Browser and Version: Repro on both Edge 120.0 and Firefox 120

Suggested Solutions

The underlying issue is IMO that the destroy directive requires a message, which seems inappropriate when compared to activate and deactivate (as well as for combination with blocks as final action on a participant)

Additional Context

No response

@Vogel612 Vogel612 added Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect labels Dec 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect
Projects
None yet
Development

No branches or pull requests

1 participant