def _run(self, client: OpenrCtrl.Client, nodes: Any, json: bool) -> None: keyDumpParams = self.buildKvStoreKeyDumpParams(Consts.PREFIX_DB_MARKER) resp = client.getKvStoreKeyValsFiltered(keyDumpParams) if json: utils.print_prefixes_json(resp, nodes, self.iter_publication) else: utils.print_prefixes_table(resp, nodes, self.iter_publication)
def _run( self, client: OpenrCtrl.Client, nodes: set, json: bool, prefix: str, client_type: str, ) -> None: prefix_dbs = client.getDecisionPrefixDbs() if json: utils.print_prefixes_json(prefix_dbs, nodes, prefix, client_type, self.iter_dbs) else: utils.print_prefixes_table(prefix_dbs, nodes, prefix, client_type, self.iter_dbs)
def print_prefix( self, resp: Dict[str, openr_types.Publication], nodes: set, json: bool, prefix: str, client_type: str, ): all_kv = openr_types.Publication() all_kv.keyVals = {} for _, val in resp.items(): all_kv.keyVals.update(val.keyVals) if json: utils.print_prefixes_json(all_kv, nodes, prefix, client_type, self.iter_publication) else: utils.print_prefixes_table(all_kv, nodes, prefix, client_type, self.iter_publication)
def run(self, nodes, json): prefix_dbs = self.client.get_prefix_dbs() if json: utils.print_prefixes_json(prefix_dbs, nodes, self.iter_dbs) else: utils.print_prefixes_table(prefix_dbs, nodes, self.iter_dbs)
def run(self, nodes, json): resp = self.client.dump_all_with_prefix(Consts.PREFIX_DB_MARKER) if json: utils.print_prefixes_json(resp, nodes, self.iter_publication) else: utils.print_prefixes_table(resp, nodes, self.iter_publication)