diff --git a/rag/utils/opendal_conn.py b/rag/utils/opendal_conn.py index 255ccebef..715c18d19 100644 --- a/rag/utils/opendal_conn.py +++ b/rag/utils/opendal_conn.py @@ -58,10 +58,15 @@ class OpenDALStorage: if self._scheme == 'mysql': self.init_db_config() self.init_opendal_mysql_table() - self._operator = opendal.Operator(self._scheme, **self._kwargs) + self._operator = opendal.Operator(**self._kwargs) logging.info("OpenDALStorage initialized successfully") + def health(self): + bucket, fnm, binary = "txtxtxtxt1", "txtxtxtxt1", b"_t@@@1" + r = self._operator.write(f"{bucket}/{fnm}", binary) + return r + def put(self, bucket, fnm, binary): self._operator.write(f"{bucket}/{fnm}", binary)