Package dev.frostlake.metastore
Class QueryHistoryTracker
java.lang.Object
dev.frostlake.metastore.QueryHistoryTracker
Tracks query execution history for the entire Frostlake engine instance
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddQuery(QueryHistory query) Add a query to historyvoidclear()Clear all historyGet all query historygetHistory(int limit) Get query history with limitgetHistoryByDatabase(String database) Get history filtered by databasegetHistoryByQueryType(String queryType) Get history filtered by query typegetHistoryByStatus(String status) Get history filtered by statusgetHistoryByUser(String user) Get history filtered by userGet the most recent querygetQueryById(String queryId) Get query by IDintsize()Get current history size
-
Constructor Details
-
QueryHistoryTracker
public QueryHistoryTracker() -
QueryHistoryTracker
public QueryHistoryTracker(int maxHistorySize)
-
-
Method Details
-
addQuery
Add a query to history -
getAllHistory
Get all query history -
getHistory
Get query history with limit -
getQueryById
Get query by ID -
getHistoryByUser
Get history filtered by user -
getHistoryByDatabase
Get history filtered by database -
getHistoryByQueryType
Get history filtered by query type -
getHistoryByStatus
Get history filtered by status -
clear
public void clear()Clear all history -
size
public int size()Get current history size -
getLastQuery
Get the most recent query
-