From c37a44dfe67b54e25c3a55332a6d8bab289bc25d Mon Sep 17 00:00:00 2001 From: Tom Barron Date: Mon, 14 Mar 2022 15:29:11 -0400 Subject: [PATCH] Fix GaneshaNASHelper update_access signature The gluster GaneshaNFSHelper update_access method calls into the GaneshaNASHelper update_access method, but the signature it uses for this call is not up to date with the 2017 dynamic export changes made to the Ganesha driver. Fix this by adding an update_access method to the gluster-specific GaneshaNFSHelper which accepts the signature that the Gluster driver expects but calls into Ganesha with the signature that it expects. [1] Change-Id: I01ec100c0afe28a84e9afa8e0660d299e4b3d160 Closes-Bug: #1964696 Change-Id: I2cae5ba54ae0a95e84d5ef7cf0f05287b7ae5d22 (cherry picked from commit 6f4191a6d92342c35ece64c735be6c43ca171d58) --- manila/share/drivers/glusterfs/__init__.py | 10 ++++++++++ ...aneshaNFSHelper-update_access-6124a79e34e63030.yaml | 7 +++++++ 2 files changed, 17 insertions(+) create mode 100644 releasenotes/notes/bug-1964696-fix-GaneshaNFSHelper-update_access-6124a79e34e63030.yaml diff --git a/manila/share/drivers/glusterfs/__init__.py b/manila/share/drivers/glusterfs/__init__.py index fca1e5a8dd..38faf4565f 100644 --- a/manila/share/drivers/glusterfs/__init__.py +++ b/manila/share/drivers/glusterfs/__init__.py @@ -309,3 +309,13 @@ class GaneshaNFSHelper(ganesha.GaneshaNASHelper): return {"Hostname": self.gluster_manager.host, "Volume": self.gluster_manager.volume, "Volpath": self.gluster_manager.path} + + def update_access(self, base_path, share, add_rules, delete_rules, + recovery=False): + """Update access rules.""" + + context = None + access_rules = [] + super(GaneshaNFSHelper, self).update_access( + context, share, access_rules, add_rules, + delete_rules, share_server=None) diff --git a/releasenotes/notes/bug-1964696-fix-GaneshaNFSHelper-update_access-6124a79e34e63030.yaml b/releasenotes/notes/bug-1964696-fix-GaneshaNFSHelper-update_access-6124a79e34e63030.yaml new file mode 100644 index 0000000000..99091a84b8 --- /dev/null +++ b/releasenotes/notes/bug-1964696-fix-GaneshaNFSHelper-update_access-6124a79e34e63030.yaml @@ -0,0 +1,7 @@ +--- +fixes: + - | + `Bug #1964696 `_: Fix + calling the GaneshaNASHelper `update_access` method from the gluster + GaneshaNFSHelper with the wrong signature. +