[ 
https://issues.apache.org/jira/browse/AMBARI-14046?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Myroslav Papirkovskyy resolved AMBARI-14046.
--------------------------------------------
    Resolution: Fixed

Pushed to trunk and branch-2.1

> Refactor code that breaks transaction chaining
> ----------------------------------------------
>
>                 Key: AMBARI-14046
>                 URL: https://issues.apache.org/jira/browse/AMBARI-14046
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-server
>    Affects Versions: 2.0.0
>            Reporter: Myroslav Papirkovskyy
>            Assignee: Myroslav Papirkovskyy
>            Priority: Critical
>             Fix For: 2.1.3
>
>
> Pattern issue:
> {code}
>    @Transactional
> -  private void unmapHostClusterEntities(String hostName, long clusterId) {
> +  void unmapHostClusterEntities(String hostName, long clusterId) {
>      HostEntity hostEntity = hostDAO.findByName(hostName);
> {code}
> Transaction chaining allow graceful rollback as well as affects visibility of 
> changes to entity objects in a DB session.
> Presently a lot of chained methods have private access with @Transactional 
> annotation which means the MethodInterceptor which provides the chaining 
> functionality will not work and the intermediate DAO calls will persist.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to