]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/smb: add raw data methods to MemConfigStore
authorJohn Mulligan <jmulligan@redhat.com>
Fri, 18 Jul 2025 14:23:12 +0000 (10:23 -0400)
committerJohn Mulligan <jmulligan@redhat.com>
Wed, 25 Mar 2026 14:22:46 +0000 (10:22 -0400)
Add the set_data/get_data methods to the MemConfigStore so that future
test updates will not fail to save tls credential objects.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
src/pybind/mgr/smb/config_store.py

index 38548df5d5e2ee621cd4f83942f07716ab646c73..94cbd99e6b010a3db929ac79832eeea23e87b4e8 100644 (file)
@@ -19,6 +19,14 @@ class MemConfigEntry:
     def get(self) -> Simplified:
         return self._store._data[(self._ns, self._name)]
 
+    def get_data(self) -> str:
+        value = self._store.data[(self._ns, self._name)]
+        assert isinstance(value, str)
+        return value
+
+    def set_data(self, value: Simplified) -> None:
+        self._store._data[(self._ns, self._name)] = value
+
     def remove(self) -> bool:
         return self._store.remove(self.full_key)