We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

Model transactions over non-transactional storage engines

I'm aware that MySQL just ignores transactions while working with non-transactional store engines such as MyISAM.

But then I saw that Phalcon\Mvc\Model has some transaction related methods and I was wondering if they are transactions implemententations at framework level or it's just a shortcut to create Db transactions.

Would be really nice to have some sort of transaction implemented at the model class so we can use it to enable transactions not only in any MySQL storage engine but also in any kind of model data source. Is there any chance of something like this get into the Phalcon's roadmap?



17.9k
Accepted
answer

I think the methods are related to DB transactions and are not implemented in code. Implementing transactions in code would be kind of pointless. If your code fails you would not have control over the transaction any longer. Transactions are DB features that help you in the event of code/network failure.