question

Agustin P3 avatar image
0 Likes"
Agustin P3 asked Connor A commented

Problem with Save Context in Preemption

I have encountered a quite strange issue around the Save Context activity when preempting tokens. I cannot share the model due to confidentiality reasons but basically the problem is that it looks like the Save Context activity is not saving the token's context at the time it is triggered but the context corresponding to the next activity the preempted token would enter instead. (I can tell by the changes in the labels when the token is stored).

At the moment of releasing the token, it is sitting in a Wait for Event activity actually far from progressing down its path so it is not due to it leaving Wait for Event right before it is released.

I figured out a temporary fix by adding a breath (Delay activity with a minimal time) so the Save Context would save the token's unaltered information in that Delay activity, but I'd like to know what is the real issue there.

Has anybody come across anything like this?

Thank you.

FlexSim 21.2.4
wait for eventpreemptionsave context
· 1
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Connor A avatar image Connor A commented ·

Hi @Agustin P3, was Jordan Johnson's answer helpful? If so, please click the "Accept" button at the bottom of their answer. Or if you still have questions, add a comment and we'll continue the conversation.

If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always unaccept and comment back to reopen your question.

0 Likes 0 ·

1 Answer

·
Jordan Johnson avatar image
2 Likes"
Jordan Johnson answered Jordan Johnson edited

Saving token contexts is a tricky business. You may have discovered a bug, but it's difficult to tell without a model. If you could make a simple model that has the behavior you've described, we may be able to tell if it's a bug, or if it's not a bug, explain how Save Context works in that particular situation.

5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.