Uploaded image for project: 'openATTIC'
  1. openATTIC
  2. OP-1915

Redirect REST-API update calls for DRBD connections from /api/volumes/xxx to /api/mirrors/xxx

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.0.19
    • Component/s: Backend: API
    • Labels:

      Description

      If a mirrored volume with file system is created, the volume API must take care to create the volume only. The file system must be created by the DRBD app because it must be created on top of the DRBD block device.

      File system
      --------------------------
      DRBD block device
      --------------------------
      Logical volume
      

      If a DRBD connection/volume is resized via WebUI the REST-API call is requested at /api/volumes/xxx. This does not work because the DRBD REST-API calls must be requested at /api/mirrors/xxx to forward them to the remote node, too. Because of this it is necessary to redirect calls from /api/volumes/ to the corresponding resource. Because the Volume's update method requires the attribute 'megs', but the DRBD's update method uses 'new_size' it is necessary to add/rename this attribute to call the method with the required arguments.

      Second, the DrbdConnectionProxyViewSet::update() method is not implemented correct, it does not redirect the request to the remote node. To fix this it should look like the destroy method.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              vtheile Theile, Volker
              Reporter:
              vtheile Theile, Volker
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: