OT: ubuntu and node.js question

hi,

with transac sql, we can roll back transaction, with JS, say, we have two functions, we want them either both executed or none, that is, if function a has been executed, however, function b failed, we’ll roll back or void function a (and vice versa for function b). I guess it can be done manually by checking the execution state of function a and function b. But I wonder if there’s a better way.

And these two functions would be two node.js apps. thus,
node app1 and node app2.

a thought is to create a shell script, check the execution status for both node app1 and node app2 toward the end of the script, if one fails, roll back both of them. with a shell script, i could also pass parameters to both app1 and app2.

fyi, successful execution of node app1 and node app2 returns some text output respectively.

have you done something or how would you go about this? thanks.

Can you stick to Lucee topics in this forum?

1 Like

sorry for occasional ot