Uploaded image for project: 'Blesta Core'
  1. Blesta Core
  2. CORE-1874

Adding services from admin UI do not fail expectedly

    Details

    • Type: Bug
    • Status: Reopened
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Staff Interface
    • Labels:
      None

      Description

      When adding a service from the admin interface, it is possible that it may fail during creation (i.e., when the module processes API calls after the initial Module::validateService call).

      In AdminClients::createService, each service (parent and add-on services) are added in a loop, but no check is done for errors, assuming all were successful. However, if the parent service failed, the add-on would still be attempted. Similarly, if the parent was successful, and an add-on failed, we would have only partial success.

      I would suggest making this loop of adding services transaction-based, but it appears that this would lead to nested transactions. Instead, we may want to consider deleting any successful services if there were an error with any of them in order to manually rollback those additions.

        Activity

        tyson Tyson Phillips (Inactive) created issue -
        Automated transition triggered when Jonathan Reissmueller created a branch in Stash -
        Field Original Value New Value
        Status Open [ 1 ] In Progress [ 3 ]
        Automated transition triggered when Jonathan Reissmueller created pull request #209 in Stash -
        Status In Progress [ 3 ] In Review [ 5 ]
        Resolution Fixed [ 1 ]
        jonathan Jonathan Reissmueller made changes -
        Assignee Tyson Phillips [ tyson ] Jonathan Reissmueller [ jonathan ]
        admin Paul Phillips made changes -
        Fix Version/s Short Term [ 10800 ]
        jonathan Jonathan Reissmueller made changes -
        Resolution Fixed [ 1 ]
        Status In Review [ 5 ] Reopened [ 4 ]

          People

          • Assignee:
            jonathan Jonathan Reissmueller
            Reporter:
            tyson Tyson Phillips (Inactive)
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated: