diff options
-rw-r--r-- | src/util/util/Cache.ts | 42 | ||||
-rw-r--r-- | src/util/util/Database.ts | 1 |
2 files changed, 42 insertions, 1 deletions
diff --git a/src/util/util/Cache.ts b/src/util/util/Cache.ts new file mode 100644 index 00000000..44839a65 --- /dev/null +++ b/src/util/util/Cache.ts @@ -0,0 +1,42 @@ +/* eslint-disable */ +import { DataSource, QueryRunner } from "typeorm"; +import { QueryResultCache } from "typeorm/cache/QueryResultCache"; +import { QueryResultCacheOptions } from "typeorm/cache/QueryResultCacheOptions"; + +export class CustomQueryResultCache implements QueryResultCache { + constructor(private dataSource: DataSource) {} + connect(): Promise<void> { + throw new Error("Method not implemented."); + } + disconnect(): Promise<void> { + throw new Error("Method not implemented."); + } + synchronize(queryRunner?: QueryRunner | undefined): Promise<void> { + throw new Error("Method not implemented."); + } + getFromCache( + options: QueryResultCacheOptions, + queryRunner?: QueryRunner | undefined, + ): Promise<QueryResultCacheOptions | undefined> { + throw new Error("Method not implemented."); + } + storeInCache( + options: QueryResultCacheOptions, + savedCache: QueryResultCacheOptions | undefined, + queryRunner?: QueryRunner | undefined, + ): Promise<void> { + throw new Error("Method not implemented."); + } + isExpired(savedCache: QueryResultCacheOptions): boolean { + throw new Error("Method not implemented."); + } + clear(queryRunner?: QueryRunner | undefined): Promise<void> { + throw new Error("Method not implemented."); + } + remove( + identifiers: string[], + queryRunner?: QueryRunner | undefined, + ): Promise<void> { + throw new Error("Method not implemented."); + } +} diff --git a/src/util/util/Database.ts b/src/util/util/Database.ts index e625ea9b..5c5c8b4c 100644 --- a/src/util/util/Database.ts +++ b/src/util/util/Database.ts @@ -63,7 +63,6 @@ const DataSourceOptions = new DataSource({ supportBigNumbers: true, name: "default", migrations: [path.join(__dirname, "..", "migration", DatabaseType, "*.js")], - cache: true, }); // Gets the existing database connection |