mirror of
https://git.yoctoproject.org/poky
synced 2026-06-02 01:19:52 +00:00
bitbake: hashserv: Add database column query API
Adds an API to retrieve the columns that can be queried on from the database backend. This prevents front end applications from needing to hardcode the query columns (Bitbake rev: abfce2b68bdab02ea2e9a63fbb3b9e270428a0a6) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
3a2c5a6fa2
commit
c1574ae46f
@@ -190,6 +190,10 @@ class AsyncClient(bb.asyncrpc.AsyncClient):
|
||||
await self._set_mode(self.MODE_NORMAL)
|
||||
return (await self.invoke({"get-db-usage": {}}))["usage"]
|
||||
|
||||
async def get_db_query_columns(self):
|
||||
await self._set_mode(self.MODE_NORMAL)
|
||||
return (await self.invoke({"get-db-query-columns": {}}))["columns"]
|
||||
|
||||
|
||||
class Client(bb.asyncrpc.Client):
|
||||
def __init__(self, username=None, password=None):
|
||||
@@ -219,6 +223,7 @@ class Client(bb.asyncrpc.Client):
|
||||
"delete_user",
|
||||
"become_user",
|
||||
"get_db_usage",
|
||||
"get_db_query_columns",
|
||||
)
|
||||
|
||||
def _get_async_client(self):
|
||||
|
||||
Reference in New Issue
Block a user