typeorm 0.3.21-dev.5c2330a → 0.3.21-dev.67c896f
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -1
- package/browser/cache/QueryResultCache.d.ts +4 -2
- package/browser/cache/QueryResultCache.js.map +1 -1
- package/browser/driver/cockroachdb/CockroachQueryRunner.js +5 -3
- package/browser/driver/cockroachdb/CockroachQueryRunner.js.map +1 -1
- package/browser/driver/postgres/PostgresQueryRunner.js +5 -1
- package/browser/driver/postgres/PostgresQueryRunner.js.map +1 -1
- package/browser/query-builder/InsertQueryBuilder.js.map +1 -1
- package/browser/query-builder/QueryBuilder.js.map +1 -1
- package/browser/schema-builder/RdbmsSchemaBuilder.js +1 -1
- package/browser/schema-builder/RdbmsSchemaBuilder.js.map +1 -1
- package/cache/QueryResultCache.d.ts +4 -2
- package/cache/QueryResultCache.js.map +1 -1
- package/commands/InitCommand.js +1 -1
- package/commands/InitCommand.js.map +1 -1
- package/driver/cockroachdb/CockroachQueryRunner.js +5 -3
- package/driver/cockroachdb/CockroachQueryRunner.js.map +1 -1
- package/driver/postgres/PostgresQueryRunner.js +5 -1
- package/driver/postgres/PostgresQueryRunner.js.map +1 -1
- package/package.json +1 -1
- package/query-builder/InsertQueryBuilder.js.map +1 -1
- package/query-builder/QueryBuilder.js.map +1 -1
- package/schema-builder/RdbmsSchemaBuilder.js +1 -1
- package/schema-builder/RdbmsSchemaBuilder.js.map +1 -1
package/README.md
CHANGED
|
@@ -1292,7 +1292,6 @@ There are a few repositories that you can clone and start with:
|
|
|
1292
1292
|
|
|
1293
1293
|
There are several extensions that simplify working with TypeORM and integrating it with other modules:
|
|
1294
1294
|
|
|
1295
|
-
- [TypeORM + GraphQL framework](https://github.com/vesper-framework/vesper)
|
|
1296
1295
|
- [TypeORM integration](https://github.com/typeorm/typeorm-typedi-extensions) with [TypeDI](https://github.com/pleerock/typedi)
|
|
1297
1296
|
- [TypeORM integration](https://github.com/typeorm/typeorm-routing-controllers-extensions) with [routing-controllers](https://github.com/pleerock/routing-controllers)
|
|
1298
1297
|
- Models generation from the existing database - [typeorm-model-generator](https://github.com/Kononnable/typeorm-model-generator)
|
|
@@ -13,11 +13,13 @@ export interface QueryResultCache {
|
|
|
13
13
|
*/
|
|
14
14
|
disconnect(): Promise<void>;
|
|
15
15
|
/**
|
|
16
|
-
*
|
|
16
|
+
* Perform operations during schema synchronization.
|
|
17
17
|
*/
|
|
18
18
|
synchronize(queryRunner?: QueryRunner): Promise<void>;
|
|
19
19
|
/**
|
|
20
|
-
*
|
|
20
|
+
* Get data from cache.
|
|
21
|
+
* Returns cache result if found.
|
|
22
|
+
* Returns undefined if result is not cached.
|
|
21
23
|
*/
|
|
22
24
|
getFromCache(options: QueryResultCacheOptions, queryRunner?: QueryRunner): Promise<QueryResultCacheOptions | undefined>;
|
|
23
25
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../browser/src/cache/QueryResultCache.ts"],"names":[],"mappings":"","file":"QueryResultCache.js","sourcesContent":["import { QueryResultCacheOptions } from \"./QueryResultCacheOptions\"\nimport { QueryRunner } from \"../query-runner/QueryRunner\"\n\n/**\n * Implementations of this interface provide different strategies to cache query builder results.\n */\nexport interface QueryResultCache {\n /**\n * Creates a connection with given cache provider.\n */\n connect(): Promise<void>\n\n /**\n * Closes a connection with given cache provider.\n */\n disconnect(): Promise<void>\n\n /**\n *
|
|
1
|
+
{"version":3,"sources":["../browser/src/cache/QueryResultCache.ts"],"names":[],"mappings":"","file":"QueryResultCache.js","sourcesContent":["import { QueryResultCacheOptions } from \"./QueryResultCacheOptions\"\nimport { QueryRunner } from \"../query-runner/QueryRunner\"\n\n/**\n * Implementations of this interface provide different strategies to cache query builder results.\n */\nexport interface QueryResultCache {\n /**\n * Creates a connection with given cache provider.\n */\n connect(): Promise<void>\n\n /**\n * Closes a connection with given cache provider.\n */\n disconnect(): Promise<void>\n\n /**\n * Perform operations during schema synchronization.\n */\n synchronize(queryRunner?: QueryRunner): Promise<void>\n\n /**\n * Get data from cache.\n * Returns cache result if found.\n * Returns undefined if result is not cached.\n */\n getFromCache(\n options: QueryResultCacheOptions,\n queryRunner?: QueryRunner,\n ): Promise<QueryResultCacheOptions | undefined>\n\n /**\n * Stores given query result in the cache.\n */\n storeInCache(\n options: QueryResultCacheOptions,\n savedCache: QueryResultCacheOptions | undefined,\n queryRunner?: QueryRunner,\n ): Promise<void>\n\n /**\n * Checks if cache is expired or not.\n */\n isExpired(savedCache: QueryResultCacheOptions): boolean\n\n /**\n * Clears everything stored in the cache.\n */\n clear(queryRunner?: QueryRunner): Promise<void>\n\n /**\n * Removes all cached results by given identifiers from cache.\n */\n remove(identifiers: string[], queryRunner?: QueryRunner): Promise<void>\n}\n"],"sourceRoot":".."}
|
|
@@ -158,7 +158,9 @@ export class CockroachQueryRunner extends BaseQueryRunner {
|
|
|
158
158
|
else {
|
|
159
159
|
this.storeQueries = false;
|
|
160
160
|
this.transactionDepth -= 1;
|
|
161
|
-
|
|
161
|
+
// This was disabled because it failed tests after update to CRDB 24.2
|
|
162
|
+
// https://github.com/typeorm/typeorm/pull/11190
|
|
163
|
+
// await this.query("RELEASE SAVEPOINT cockroach_restart")
|
|
162
164
|
await this.query("COMMIT");
|
|
163
165
|
this.queries = [];
|
|
164
166
|
this.isTransactionActive = false;
|
|
@@ -635,7 +637,7 @@ export class CockroachQueryRunner extends BaseQueryRunner {
|
|
|
635
637
|
});
|
|
636
638
|
// rename ENUM types
|
|
637
639
|
const enumColumns = newTable.columns.filter((column) => column.type === "enum" || column.type === "simple-enum");
|
|
638
|
-
for (
|
|
640
|
+
for (const column of enumColumns) {
|
|
639
641
|
// skip renaming for user-defined enum name
|
|
640
642
|
if (column.enumName)
|
|
641
643
|
continue;
|
|
@@ -2229,7 +2231,7 @@ export class CockroachQueryRunner extends BaseQueryRunner {
|
|
|
2229
2231
|
* Builds drop index sql.
|
|
2230
2232
|
*/
|
|
2231
2233
|
dropIndexSql(table, indexOrName) {
|
|
2232
|
-
|
|
2234
|
+
const indexName = InstanceChecker.isTableIndex(indexOrName) ||
|
|
2233
2235
|
InstanceChecker.isTableUnique(indexOrName)
|
|
2234
2236
|
? indexOrName.name
|
|
2235
2237
|
: indexOrName;
|