Skip to content

Commit

Permalink
chore: default pagesize (#11795)
Browse files Browse the repository at this point in the history
  • Loading branch information
LiuJi-Jim committed Apr 25, 2024
1 parent 103cfdb commit 5204f4f
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion frontend/src/store/modules/v1/database.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ import { useEnvironmentV1Store } from "./environment";
import { useInstanceV1Store } from "./instance";
import { useProjectV1Store } from "./project";

export const DEFAULT_DATABASE_PAGE_SIZE = 1000000;

export const useDatabaseV1Store = defineStore("database_v1", () => {
const databaseMapByName = reactive(new Map<string, ComposedDatabase>());
const databaseMapByUID = reactive(new Map<string, ComposedDatabase>());
Expand Down Expand Up @@ -64,7 +66,10 @@ export const useDatabaseV1Store = defineStore("database_v1", () => {
}
};
const searchDatabases = async (args: Partial<SearchDatabasesRequest>) => {
const { databases } = await databaseServiceClient.searchDatabases(args);
const { databases } = await databaseServiceClient.searchDatabases({
pageSize: DEFAULT_DATABASE_PAGE_SIZE,
...args,
});
const composedDatabaseList = await upsertDatabaseMap(databases);
return composedDatabaseList;
};
Expand Down

0 comments on commit 5204f4f

Please sign in to comment.