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

mysql porting v2 #98

Closed
2 tasks done
syjer opened this issue Feb 10, 2016 · 3 comments
Closed
2 tasks done

mysql porting v2 #98

syjer opened this issue Feb 10, 2016 · 3 comments
Assignees
Milestone

Comments

@syjer
Copy link
Member

syjer commented Feb 10, 2016

Some additional task related to the mysql support:

  • re enable disabled test (Migration?) (seems to be an issue with the transactiontemplate (with hsqldb, check with others too))
  • check "check constraints" :) (emulate them with triggers?)
@syjer syjer self-assigned this Feb 10, 2016
@syjer syjer added this to the 1.8 milestone Feb 10, 2016
@syjer
Copy link
Member Author

syjer commented Apr 11, 2016

existing check constraints:

alter table promo_code add constraint "check_promo_code_min_length" check (char_length(promo_code) >= 7);
alter table promo_code add constraint "check_discount_type" check (discount_type = 'FIXED_AMOUNT' OR discount_type = 'PERCENTAGE');
alter table promo_code add constraint "check_discount_amount" check (
CASE
    WHEN discount_type = 'FIXED_AMOUNT' THEN discount_amount >= 0
    WHEN discount_type = 'PERCENTAGE' THEN discount_amount >= 0 and discount_amount <= 100
END);

syjer added a commit that referenced this issue May 2, 2016
@syjer
Copy link
Member Author

syjer commented May 2, 2016

The constraint has been ported as a code in the service layer.

syjer added a commit that referenced this issue May 5, 2016
- removing the @transactional annotation from the integration tests mysql and hsqldb are able to run their tests
- deleting the test plugin ensure that no constraint violation is done during the test
@syjer
Copy link
Member Author

syjer commented May 5, 2016

migration test has been reenabled :)

@syjer syjer closed this as completed May 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant