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

Request for installation procedure tdt/core - discussion #21

Closed
coreation opened this issue Mar 1, 2013 · 2 comments
Closed

Request for installation procedure tdt/core - discussion #21

coreation opened this issue Mar 1, 2013 · 2 comments
Labels

Comments

@coreation
Copy link
Member

Currently issue #16 is fixed, but not in an ideal way.

Problem.

We have to rollback database transactions, and with our current ORM (RedBean) this is possible. It has a built-in transaction system with the normal components such as begin(), commit() and rollback(). Now, here's the tricky part. In order to make this work, the autocommit to the MySQL back-end should be set to false. If not, RedBean provides a function to work-around this by using R::freeze(true). However, since we work in a "fluid" environment (meaning tables get made and adjusted on the fly) using this function is not an option.
(http://stackoverflow.com/questions/10851471/why-arent-redbeans-transaction-functions-working)
Solution(s)

  1. A first solution is to configure the MySQL back-end to auto-commit = false.
    (http://stackoverflow.com/questions/2280465/how-do-i-turn-off-autocommit-for-a-mysql-client)

  2. A second solution exists in creating an installation script that you can call upon, and works just like it used to in our previous repository (iRail/The-DataTank), which initializes the databases. After that we can use R::freeze(true). This looks(!!) like a good solution, however with a CLI client you can't use our old approach, namely browsing to our /installation and following the steps. So maybe, a resource should be made that not only initializes the database back-end, but also updates the back-end when database changes are to be applied.

RFC!

@coreation
Copy link
Member Author

@NtynMichiel Reference this issue when you create a solution issue for this (probably in tdt/start?)

@pietercolpaert
Copy link
Member

Fixed in 2013.12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants