Hi,
Given it looks like the isolate method is never going to added back to the current or future versions of Seaside as it's been an open bug issue for the last 5 years, how in general would go about replicating it's behaviour ? I think it's a shame as I think this sort of functionality made Seaside standout from the crowd as a web framework. Thanks _______________________________________________ seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
On Sun, Jun 21, 2015 at 8:30 PM, <[hidden email]> wrote:
> Hi, > > Given it looks like the isolate method is never going to added back to the > current or future versions of Seaside as it's been an open bug issue for the > last 5 years, how in general would go about replicating it's behaviour ? A flag that's not backtracked. If you want to get fancy you can also store the last not expired continuation / state snapshot (again not backtracked) and redirect to this. Cheers Philippe _______________________________________________ seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
Hi all,
I found this post from 22/06/2015 using forum.world.st, and I'm having the same problem. I (think I) need the #isolate: method's behavior to prevent backtracking a WATask that has a transactional step in its flow. All the documentation I could find mention the #isolate: method. After searching for quite a bit, I haven't found a clear example of how to work around this in a different way. @Philippe: Unfortunately, I do not understand what you are saying here: Philippe Marschall wrote > A flag that's not backtracked. If you want to get fancy you can also > store the last not expired continuation / state snapshot (again not > backtracked) and redirect to this. Can anyone help me with this? I have the feeling that a possible solution might be found in overriding the #states method, but I don't understand enough of how that should work. I'm missing clear examples and/or documentation here. Thanks in advance! Best, Jonathan -- Sent from: http://forum.world.st/Seaside-General-f86180.html _______________________________________________ seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
Hello Jonathan
Implementing #isolate: may not be the ideal starter issue but maybe you can solve your issue without implementing isolate. I have two ideas on top of my head, maybe they work: - A boolean completed flag in your task class. On completion of the task set the flag to true. Override "the right methods" and add a check to the flag. Just make sure you don't backtrack this flag. - On completion of the task add a decoration that prevents is from being executed again, or simply renders "the task is expired". I know this is not very specific. I hope these are enough to get you started. Cheers Philippe On Fri, Nov 15, 2019 at 2:26 PM [hidden email] <[hidden email]> wrote: > > Hi all, > > I found this post from 22/06/2015 using forum.world.st, and I'm having the > same problem. I (think I) need the #isolate: method's behavior to prevent > backtracking a WATask that has a transactional step in its flow. > > All the documentation I could find mention the #isolate: method. After > searching for quite a bit, I haven't found a clear example of how to work > around this in a different way. > > @Philippe: Unfortunately, I do not understand what you are saying here: > > > Philippe Marschall wrote > > A flag that's not backtracked. If you want to get fancy you can also > > store the last not expired continuation / state snapshot (again not > > backtracked) and redirect to this. > > Can anyone help me with this? I have the feeling that a possible solution > might be found in overriding the #states method, but I don't understand > enough of how that should work. I'm missing clear examples and/or > documentation here. > > Thanks in advance! > > Best, > Jonathan > > > > -- > Sent from: http://forum.world.st/Seaside-General-f86180.html > _______________________________________________ > seaside mailing list > [hidden email] > http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
Hi Philippe,
Thanks for your reply.
I think I need some more help understanding your suggestions. I'm still learning Seaside and have only the code comments and documentation + books to go on.
Can you elaborate what you mean by the following?
What do you mean by 'the right methods'?
And can you explain to me how I can prevent backtracking? Unfortunately I still haven't been able to find a good explanation for that.
And perhaps you can tell me which version of Seaside still had the #isolate: behavior? That way I can investigate myself.
The transactional behavior I want to isolate represents very high business value, so I need to make absolutely certain that it cannot be performed more than once.
Cheers,
Jonathan
On 17 Nov 2019, 09:30 +0100, Philippe Marschall <[hidden email]>, wrote:
Hello Jonathan _______________________________________________ seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
On Wed, Nov 20, 2019 at 9:58 AM Jonathan van Alteren
<[hidden email]> wrote: > > Hi Philippe, > > Thanks for your reply. > > I think I need some more help understanding your suggestions. I'm still learning Seaside and have only the code comments and documentation + books to go on. I would add the debugger to this. > Can you elaborate what you mean by the following? > > Override "the right methods" and add a check to the flag. Just make sure you don't backtrack this flag. > > > > What do you mean by 'the right methods'? It's a cheap way of me to say "I don't know" you would have to figure that out either by studying the code or stepping through the debugger. > And can you explain to me how I can prevent backtracking? Unfortunately I still haven't been able to find a good explanation for that. Only the things returned by #states are backtracked so nothing is backtracked by default. Just make sure you don't accidentally backtrack something that shouldn't be. Maybe seeing it in action makes it easier to understand. Good entry points are the following methods: WASessionContinuation >> #captureState WASnapshot >> #restore > And perhaps you can tell me which version of Seaside still had the #isolate: behavior? That way I can investigate myself. The 2 series, so 2.8. You can find the code here [1]. [1] http://www.squeaksource.com/Seaside.html Cheers Philippe _______________________________________________ seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
Free forum by Nabble | Edit this page |