feat(flr): windows paths, recovery-site gate, stable partition reads (#4)
This commit was merged in pull request #4.
This commit is contained in:
@@ -151,7 +151,7 @@ class ZertoClient:
|
||||
async def get_vpg(self, vpg_identifier: str) -> dict[str, Any]:
|
||||
data = await self.json("GET", f"/v1/vpgs/{vpg_identifier}")
|
||||
if not isinstance(data, dict):
|
||||
raise ZertoError("GET /v1/vpgs/{id} did not return an object")
|
||||
raise ZertoError(f"GET /v1/vpgs/{vpg_identifier} did not return an object")
|
||||
return data
|
||||
|
||||
async def list_checkpoints(self, vpg_identifier: str) -> list[dict[str, Any]]:
|
||||
@@ -231,6 +231,14 @@ class ZertoClient:
|
||||
status_code=last.status_code if last else None,
|
||||
)
|
||||
|
||||
async def get_localsite(self) -> dict[str, Any]:
|
||||
data = await self.json("GET", "/v1/localsite")
|
||||
return data if isinstance(data, dict) else {}
|
||||
|
||||
async def get_peersites(self) -> list[dict[str, Any]]:
|
||||
data = await self.json("GET", "/v1/peersites")
|
||||
return [r for r in data if isinstance(r, dict)] if isinstance(data, list) else []
|
||||
|
||||
async def list_flrs(self) -> Any:
|
||||
"""GET /v1/flrs. Every FLR session the ZVM currently knows about."""
|
||||
return await self.json("GET", "/v1/flrs")
|
||||
|
||||
Reference in New Issue
Block a user