@webiny/migrations 5.40.6 → 5.41.0-beta.0
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/ddb-es.d.ts +2 -19
- package/ddb-es.js +5 -58
- package/ddb-es.js.map +1 -1
- package/ddb.d.ts +2 -19
- package/ddb.js +5 -42
- package/ddb.js.map +1 -1
- package/migrations/5.35.0/001/ddb/FileDataMigration.d.ts +1 -1
- package/migrations/5.35.0/001/ddb-es/FileDataMigration.d.ts +1 -1
- package/migrations/5.35.0/006/ddb/PageDataMigration.d.ts +1 -1
- package/migrations/5.35.0/006/ddb-es/PageDataMigration.d.ts +1 -1
- package/migrations/5.35.0/006/types.d.ts +2 -2
- package/migrations/5.36.0/001/ddb/FileDataMigration.d.ts +1 -1
- package/migrations/5.36.0/001/ddb-es/FileDataMigration.d.ts +1 -1
- package/migrations/5.36.0/001/types.d.ts +1 -1
- package/migrations/5.37.0/001/TenantLinkDataMigration.d.ts +1 -1
- package/migrations/5.37.0/001/types.d.ts +1 -1
- package/migrations/5.37.0/002/types.d.ts +1 -1
- package/migrations/5.37.0/003/ddb/AcoFolderMigration.d.ts +1 -1
- package/migrations/5.37.0/003/ddb-es/AcoFolderMigration.d.ts +1 -1
- package/migrations/5.37.0/003/types.d.ts +2 -2
- package/migrations/5.37.0/004/ddb/PageDataMigration.d.ts +1 -1
- package/migrations/5.37.0/004/ddb-es/PageDataMigration.d.ts +1 -1
- package/migrations/5.37.0/004/types.d.ts +2 -2
- package/migrations/5.37.0/005/ddb/index.d.ts +1 -1
- package/migrations/5.37.0/005/ddb-es/index.d.ts +1 -1
- package/migrations/5.37.0/005/types.d.ts +1 -1
- package/migrations/5.38.0/001/types.d.ts +1 -1
- package/migrations/5.38.0/002/types.d.ts +1 -1
- package/migrations/5.39.0/001/types.d.ts +1 -1
- package/migrations/5.39.6/001/ddb-es/utils.d.ts +1 -1
- package/migrations/5.41.0/001/createTenantEntity.d.ts +42 -0
- package/migrations/5.41.0/001/createTenantEntity.js +46 -0
- package/migrations/5.41.0/001/createTenantEntity.js.map +1 -0
- package/migrations/5.41.0/001/createUserEntity.d.ts +48 -0
- package/migrations/5.41.0/001/createUserEntity.js +54 -0
- package/migrations/5.41.0/001/createUserEntity.js.map +1 -0
- package/migrations/5.41.0/001/index.d.ts +11 -0
- package/migrations/5.41.0/001/index.js +89 -0
- package/migrations/5.41.0/001/index.js.map +1 -0
- package/package.json +18 -18
- package/utils/elasticsearch/esGetIndexName.js +3 -2
- package/utils/elasticsearch/esGetIndexName.js.map +1 -1
- package/utils/forEachTenantLocale.d.ts +1 -1
package/ddb-es.d.ts
CHANGED
|
@@ -1,19 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
import { AdminUsers_5_35_0_003 } from "./migrations/5.35.0/003";
|
|
4
|
-
import { Tenancy_5_35_0_004 } from "./migrations/5.35.0/004";
|
|
5
|
-
import { CmsModels_5_35_0_005 } from "./migrations/5.35.0/005";
|
|
6
|
-
import { AcoRecords_5_35_0_006 } from "./migrations/5.35.0/006/ddb-es";
|
|
7
|
-
import { AcoRecords_5_36_0_001 } from "./migrations/5.36.0/001/ddb-es";
|
|
8
|
-
import { TenantLinkRecords_5_37_0_001 } from "./migrations/5.37.0/001";
|
|
9
|
-
import { CmsEntriesRootFolder_5_37_0_002 } from "./migrations/5.37.0/002/ddb-es";
|
|
10
|
-
import { AcoFolders_5_37_0_003 } from "./migrations/5.37.0/003/ddb-es";
|
|
11
|
-
import { AcoRecords_5_37_0_004 } from "./migrations/5.37.0/004/ddb-es";
|
|
12
|
-
import { FileManager_5_37_0_005 } from "./migrations/5.37.0/005/ddb-es";
|
|
13
|
-
import { MultiStepForms_5_38_0_001 } from "./migrations/5.38.0/001/ddb-es";
|
|
14
|
-
import { MultiStepForms_5_38_0_002 } from "./migrations/5.38.0/002/ddb-es";
|
|
15
|
-
import { PageBlocks_5_38_0_003 } from "./migrations/5.38.0/003/ddb";
|
|
16
|
-
import { FileManager_5_39_0_002 } from "./migrations/5.39.0/002/ddb-es";
|
|
17
|
-
import { CmsEntriesInitNewMetaFields_5_39_6_001 } from "./migrations/5.39.6/001/ddb-es";
|
|
18
|
-
import { PbUniqueBlockElementIds_5_40_0_001 } from "./migrations/5.40.0/001/ddb";
|
|
19
|
-
export declare const migrations: () => (typeof FileManager_5_35_0_001 | typeof PageBuilder_5_35_0_002 | typeof AdminUsers_5_35_0_003 | typeof Tenancy_5_35_0_004 | typeof CmsModels_5_35_0_005 | typeof AcoRecords_5_35_0_006 | typeof AcoRecords_5_36_0_001 | typeof TenantLinkRecords_5_37_0_001 | typeof CmsEntriesRootFolder_5_37_0_002 | typeof AcoFolders_5_37_0_003 | typeof AcoRecords_5_37_0_004 | typeof FileManager_5_37_0_005 | typeof MultiStepForms_5_38_0_001 | typeof MultiStepForms_5_38_0_002 | typeof PageBlocks_5_38_0_003 | typeof FileManager_5_39_0_002 | typeof CmsEntriesInitNewMetaFields_5_39_6_001 | typeof PbUniqueBlockElementIds_5_40_0_001)[];
|
|
1
|
+
import { AdminUsers_5_41_0_001 } from "./migrations/5.41.0/001";
|
|
2
|
+
export declare const migrations: () => (typeof AdminUsers_5_41_0_001)[];
|
package/ddb-es.js
CHANGED
|
@@ -4,66 +4,13 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.migrations = void 0;
|
|
7
|
-
var
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
var _4 = require("./migrations/5.35.0/005");
|
|
12
|
-
var _ddbEs2 = require("./migrations/5.35.0/006/ddb-es");
|
|
13
|
-
var _ddbEs3 = require("./migrations/5.36.0/001/ddb-es");
|
|
14
|
-
var _5 = require("./migrations/5.37.0/001");
|
|
15
|
-
var _ddbEs4 = require("./migrations/5.37.0/002/ddb-es");
|
|
16
|
-
var _ddbEs5 = require("./migrations/5.37.0/003/ddb-es");
|
|
17
|
-
var _ddbEs6 = require("./migrations/5.37.0/004/ddb-es");
|
|
18
|
-
var _ddbEs7 = require("./migrations/5.37.0/005/ddb-es");
|
|
19
|
-
var _ddbEs8 = require("./migrations/5.38.0/001/ddb-es");
|
|
20
|
-
var _ddbEs9 = require("./migrations/5.38.0/002/ddb-es");
|
|
21
|
-
var _ddb = require("./migrations/5.38.0/003/ddb");
|
|
22
|
-
var _ddbEs10 = require("./migrations/5.39.0/002/ddb-es");
|
|
23
|
-
var _ddbEs11 = require("./migrations/5.39.6/001/ddb-es");
|
|
24
|
-
var _ddb2 = require("./migrations/5.40.0/001/ddb");
|
|
25
|
-
// 5.35.0
|
|
26
|
-
|
|
27
|
-
// 5.36.0
|
|
28
|
-
|
|
29
|
-
// 5.37.0
|
|
30
|
-
|
|
31
|
-
// 5.38.0
|
|
32
|
-
|
|
33
|
-
// Page Blocks storage is the same for both DDB abd DDB-ES projects.
|
|
34
|
-
|
|
35
|
-
// 5.39.0
|
|
36
|
-
// Because of the 5.39.6-001 migration, this one is no longer needed.
|
|
37
|
-
// import { CmsEntriesInitNewMetaFields_5_39_0_001 } from "~/migrations/5.39.0/001/ddb-es";
|
|
38
|
-
|
|
39
|
-
// 5.39.2
|
|
40
|
-
// Because of the 5.39.6-001 migration, this one is no longer needed.
|
|
41
|
-
// import { CmsEntriesInitNewMetaFields_5_39_2_001 } from "~/migrations/5.39.2/001/ddb-es";
|
|
42
|
-
|
|
43
|
-
// 5.39.6
|
|
7
|
+
var _ = require("./migrations/5.41.0/001");
|
|
8
|
+
// We only list current version migrations here. No need to have them all
|
|
9
|
+
// listed, as we only need the latest version migrations to be executed.
|
|
10
|
+
// This also helps with keeping the bundle size down / faster boot times.
|
|
44
11
|
|
|
45
12
|
const migrations = () => {
|
|
46
|
-
return [
|
|
47
|
-
// 5.35.0
|
|
48
|
-
_ddbEs.FileManager_5_35_0_001, _.PageBuilder_5_35_0_002, _2.AdminUsers_5_35_0_003, _3.Tenancy_5_35_0_004, _4.CmsModels_5_35_0_005, _ddbEs2.AcoRecords_5_35_0_006,
|
|
49
|
-
// 5.36.0
|
|
50
|
-
_ddbEs3.AcoRecords_5_36_0_001,
|
|
51
|
-
// 5.37.0
|
|
52
|
-
_5.TenantLinkRecords_5_37_0_001, _ddbEs4.CmsEntriesRootFolder_5_37_0_002, _ddbEs5.AcoFolders_5_37_0_003, _ddbEs6.AcoRecords_5_37_0_004, _ddbEs7.FileManager_5_37_0_005,
|
|
53
|
-
// 5.38.0
|
|
54
|
-
_ddbEs8.MultiStepForms_5_38_0_001, _ddbEs9.MultiStepForms_5_38_0_002, _ddb.PageBlocks_5_38_0_003,
|
|
55
|
-
// 5.39.0
|
|
56
|
-
// Because of the 5.39.6-001 migration, this one is no longer needed.
|
|
57
|
-
// CmsEntriesInitNewMetaFields_5_39_0_001,
|
|
58
|
-
_ddbEs10.FileManager_5_39_0_002,
|
|
59
|
-
// 5.39.2
|
|
60
|
-
// Because of the 5.39.6-001 migration, this one is no longer needed.
|
|
61
|
-
// CmsEntriesInitNewMetaFields_5_39_2_001
|
|
62
|
-
|
|
63
|
-
// 5.39.6
|
|
64
|
-
_ddbEs11.CmsEntriesInitNewMetaFields_5_39_6_001,
|
|
65
|
-
// 5.40.0
|
|
66
|
-
_ddb2.PbUniqueBlockElementIds_5_40_0_001];
|
|
13
|
+
return [_.AdminUsers_5_41_0_001];
|
|
67
14
|
};
|
|
68
15
|
exports.migrations = migrations;
|
|
69
16
|
|
package/ddb-es.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["_","require","migrations","AdminUsers_5_41_0_001","exports"],"sources":["ddb-es.ts"],"sourcesContent":["// We only list current version migrations here. No need to have them all\n// listed, as we only need the latest version migrations to be executed.\n// This also helps with keeping the bundle size down / faster boot times.\nimport { AdminUsers_5_41_0_001 } from \"~/migrations/5.41.0/001\";\n\nexport const migrations = () => {\n return [AdminUsers_5_41_0_001];\n};\n"],"mappings":";;;;;;AAGA,IAAAA,CAAA,GAAAC,OAAA;AAHA;AACA;AACA;;AAGO,MAAMC,UAAU,GAAGA,CAAA,KAAM;EAC5B,OAAO,CAACC,uBAAqB,CAAC;AAClC,CAAC;AAACC,OAAA,CAAAF,UAAA,GAAAA,UAAA","ignoreList":[]}
|
package/ddb.d.ts
CHANGED
|
@@ -1,19 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
import { AdminUsers_5_35_0_003 } from "./migrations/5.35.0/003";
|
|
4
|
-
import { Tenancy_5_35_0_004 } from "./migrations/5.35.0/004";
|
|
5
|
-
import { CmsModels_5_35_0_005 } from "./migrations/5.35.0/005";
|
|
6
|
-
import { AcoRecords_5_35_0_006 } from "./migrations/5.35.0/006/ddb";
|
|
7
|
-
import { AcoRecords_5_36_0_001 } from "./migrations/5.36.0/001/ddb";
|
|
8
|
-
import { TenantLinkRecords_5_37_0_001 } from "./migrations/5.37.0/001";
|
|
9
|
-
import { CmsEntriesRootFolder_5_37_0_002 } from "./migrations/5.37.0/002/ddb";
|
|
10
|
-
import { AcoFolders_5_37_0_003 } from "./migrations/5.37.0/003/ddb";
|
|
11
|
-
import { AcoRecords_5_37_0_004 } from "./migrations/5.37.0/004/ddb";
|
|
12
|
-
import { FileManager_5_37_0_005 } from "./migrations/5.37.0/005/ddb";
|
|
13
|
-
import { MultiStepForms_5_38_0_001 } from "./migrations/5.38.0/001/ddb";
|
|
14
|
-
import { MultiStepForms_5_38_0_002 } from "./migrations/5.38.0/002/ddb";
|
|
15
|
-
import { PageBlocks_5_38_0_003 } from "./migrations/5.38.0/003/ddb";
|
|
16
|
-
import { CmsEntriesInitNewMetaFields_5_39_0_001 } from "./migrations/5.39.0/001/ddb";
|
|
17
|
-
import { FileManager_5_39_0_002 } from "./migrations/5.39.0/002/ddb";
|
|
18
|
-
import { PbUniqueBlockElementIds_5_40_0_001 } from "./migrations/5.40.0/001/ddb";
|
|
19
|
-
export declare const migrations: () => (typeof PageBuilder_5_35_0_002 | typeof AdminUsers_5_35_0_003 | typeof Tenancy_5_35_0_004 | typeof CmsModels_5_35_0_005 | typeof TenantLinkRecords_5_37_0_001 | typeof PageBlocks_5_38_0_003 | typeof PbUniqueBlockElementIds_5_40_0_001 | typeof FileManager_5_35_0_001 | typeof AcoRecords_5_35_0_006 | typeof AcoRecords_5_36_0_001 | typeof CmsEntriesRootFolder_5_37_0_002 | typeof AcoFolders_5_37_0_003 | typeof AcoRecords_5_37_0_004 | typeof FileManager_5_37_0_005 | typeof MultiStepForms_5_38_0_001 | typeof MultiStepForms_5_38_0_002 | typeof CmsEntriesInitNewMetaFields_5_39_0_001 | typeof FileManager_5_39_0_002)[];
|
|
1
|
+
import { AdminUsers_5_41_0_001 } from "./migrations/5.41.0/001";
|
|
2
|
+
export declare const migrations: () => (typeof AdminUsers_5_41_0_001)[];
|
package/ddb.js
CHANGED
|
@@ -4,50 +4,13 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.migrations = void 0;
|
|
7
|
-
var
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
var _4 = require("./migrations/5.35.0/005");
|
|
12
|
-
var _ddb2 = require("./migrations/5.35.0/006/ddb");
|
|
13
|
-
var _ddb3 = require("./migrations/5.36.0/001/ddb");
|
|
14
|
-
var _5 = require("./migrations/5.37.0/001");
|
|
15
|
-
var _ddb4 = require("./migrations/5.37.0/002/ddb");
|
|
16
|
-
var _ddb5 = require("./migrations/5.37.0/003/ddb");
|
|
17
|
-
var _ddb6 = require("./migrations/5.37.0/004/ddb");
|
|
18
|
-
var _ddb7 = require("./migrations/5.37.0/005/ddb");
|
|
19
|
-
var _ddb8 = require("./migrations/5.38.0/001/ddb");
|
|
20
|
-
var _ddb9 = require("./migrations/5.38.0/002/ddb");
|
|
21
|
-
var _ddb10 = require("./migrations/5.38.0/003/ddb");
|
|
22
|
-
var _ddb11 = require("./migrations/5.39.0/001/ddb");
|
|
23
|
-
var _ddb12 = require("./migrations/5.39.0/002/ddb");
|
|
24
|
-
var _ddb13 = require("./migrations/5.40.0/001/ddb");
|
|
25
|
-
// 5.35.0
|
|
26
|
-
|
|
27
|
-
// 5.36.0
|
|
28
|
-
|
|
29
|
-
// 5.37.0
|
|
30
|
-
|
|
31
|
-
// 5.38.0
|
|
32
|
-
|
|
33
|
-
// 5.39.0
|
|
34
|
-
|
|
35
|
-
// Page Blocks storage is the same for both DDB abd DDB-ES projects.
|
|
7
|
+
var _ = require("./migrations/5.41.0/001");
|
|
8
|
+
// We only list current version migrations here. No need to have them all
|
|
9
|
+
// listed, as we only need the latest version migrations to be executed.
|
|
10
|
+
// This also helps with keeping the bundle size down / faster boot times.
|
|
36
11
|
|
|
37
12
|
const migrations = () => {
|
|
38
|
-
return [
|
|
39
|
-
// 5.35.0
|
|
40
|
-
_ddb.FileManager_5_35_0_001, _.PageBuilder_5_35_0_002, _2.AdminUsers_5_35_0_003, _3.Tenancy_5_35_0_004, _4.CmsModels_5_35_0_005, _ddb2.AcoRecords_5_35_0_006,
|
|
41
|
-
// 5.36.0
|
|
42
|
-
_ddb3.AcoRecords_5_36_0_001,
|
|
43
|
-
// 5.37.0
|
|
44
|
-
_5.TenantLinkRecords_5_37_0_001, _ddb4.CmsEntriesRootFolder_5_37_0_002, _ddb5.AcoFolders_5_37_0_003, _ddb6.AcoRecords_5_37_0_004, _ddb7.FileManager_5_37_0_005,
|
|
45
|
-
// 5.38.0
|
|
46
|
-
_ddb8.MultiStepForms_5_38_0_001, _ddb9.MultiStepForms_5_38_0_002, _ddb10.PageBlocks_5_38_0_003,
|
|
47
|
-
// 5.39.0
|
|
48
|
-
_ddb11.CmsEntriesInitNewMetaFields_5_39_0_001, _ddb12.FileManager_5_39_0_002,
|
|
49
|
-
// 5.40.0
|
|
50
|
-
_ddb13.PbUniqueBlockElementIds_5_40_0_001];
|
|
13
|
+
return [_.AdminUsers_5_41_0_001];
|
|
51
14
|
};
|
|
52
15
|
exports.migrations = migrations;
|
|
53
16
|
|
package/ddb.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["_","require","migrations","AdminUsers_5_41_0_001","exports"],"sources":["ddb.ts"],"sourcesContent":["// We only list current version migrations here. No need to have them all\n// listed, as we only need the latest version migrations to be executed.\n// This also helps with keeping the bundle size down / faster boot times.\nimport { AdminUsers_5_41_0_001 } from \"~/migrations/5.41.0/001\";\n\nexport const migrations = () => {\n return [AdminUsers_5_41_0_001];\n};\n"],"mappings":";;;;;;AAGA,IAAAA,CAAA,GAAAC,OAAA;AAHA;AACA;AACA;;AAGO,MAAMC,UAAU,GAAGA,CAAA,KAAM;EAC5B,OAAO,CAACC,uBAAqB,CAAC;AAClC,CAAC;AAACC,OAAA,CAAAF,UAAA,GAAAA,UAAA","ignoreList":[]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
2
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
3
|
-
export
|
|
3
|
+
export type FileMigrationCheckpoint = Record<string, string | boolean | undefined>;
|
|
4
4
|
export declare class FileManager_5_35_0_001_FileData implements DataMigration<FileMigrationCheckpoint> {
|
|
5
5
|
private readonly newFileEntity;
|
|
6
6
|
private readonly legacyFileEntity;
|
|
@@ -2,7 +2,7 @@ import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
|
2
2
|
import { Client } from "@elastic/elasticsearch";
|
|
3
3
|
import { PrimitiveValue } from "@webiny/api-elasticsearch/types";
|
|
4
4
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
5
|
-
|
|
5
|
+
type FileMigrationCheckpoint = Record<string, PrimitiveValue[] | boolean | undefined>;
|
|
6
6
|
export declare class FileManager_5_35_0_001_FileData implements DataMigration<FileMigrationCheckpoint> {
|
|
7
7
|
private readonly elasticsearchClient;
|
|
8
8
|
private readonly newFileEntity;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
2
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
3
|
-
export
|
|
3
|
+
export type PageDataMigrationCheckpoint = Record<string, string | boolean | undefined>;
|
|
4
4
|
export declare class AcoRecords_5_35_0_006_PageData implements DataMigration<PageDataMigrationCheckpoint> {
|
|
5
5
|
private readonly entryEntity;
|
|
6
6
|
private readonly localeEntity;
|
|
@@ -2,7 +2,7 @@ import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
|
2
2
|
import { Client } from "@elastic/elasticsearch";
|
|
3
3
|
import { PrimitiveValue } from "@webiny/api-elasticsearch/types";
|
|
4
4
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
5
|
-
export
|
|
5
|
+
export type PageDataMigrationCheckpoint = Record<string, PrimitiveValue[] | boolean | undefined>;
|
|
6
6
|
export declare class AcoRecords_5_35_0_006_PageData implements DataMigration<PageDataMigrationCheckpoint> {
|
|
7
7
|
private readonly elasticsearchClient;
|
|
8
8
|
private readonly ddbEntryEntity;
|
|
@@ -15,7 +15,7 @@ export interface Identity {
|
|
|
15
15
|
export interface CmsEntryValues {
|
|
16
16
|
[key: string]: any;
|
|
17
17
|
}
|
|
18
|
-
export
|
|
18
|
+
export type CmsEntryStatus = "published" | "unpublished" | "draft";
|
|
19
19
|
export interface CmsEntry<T = CmsEntryValues> {
|
|
20
20
|
webinyVersion: string;
|
|
21
21
|
tenant: string;
|
|
@@ -63,7 +63,7 @@ export interface PageSettings {
|
|
|
63
63
|
};
|
|
64
64
|
[key: string]: any;
|
|
65
65
|
}
|
|
66
|
-
export
|
|
66
|
+
export type PageStatus = "published" | "unpublished" | "draft";
|
|
67
67
|
export interface Page {
|
|
68
68
|
id: string;
|
|
69
69
|
pid: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
2
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
3
|
-
export
|
|
3
|
+
export type FileDataMigrationCheckpoint = Record<string, string | boolean | undefined>;
|
|
4
4
|
export declare class AcoRecords_5_36_0_001_FileData implements DataMigration<FileDataMigrationCheckpoint> {
|
|
5
5
|
private readonly entryEntity;
|
|
6
6
|
private readonly localeEntity;
|
|
@@ -2,7 +2,7 @@ import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
|
2
2
|
import { Client } from "@elastic/elasticsearch";
|
|
3
3
|
import { PrimitiveValue } from "@webiny/api-elasticsearch/types";
|
|
4
4
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
5
|
-
export
|
|
5
|
+
export type FileDataMigrationCheckpoint = Record<string, PrimitiveValue[] | boolean | undefined>;
|
|
6
6
|
export declare class AcoRecords_5_36_0_001_FileData implements DataMigration<FileDataMigrationCheckpoint> {
|
|
7
7
|
private readonly elasticsearchClient;
|
|
8
8
|
private readonly ddbEntryEntity;
|
|
@@ -15,7 +15,7 @@ export interface Identity {
|
|
|
15
15
|
export interface CmsEntryValues {
|
|
16
16
|
[key: string]: any;
|
|
17
17
|
}
|
|
18
|
-
export
|
|
18
|
+
export type CmsEntryStatus = "published" | "unpublished" | "draft";
|
|
19
19
|
export interface CmsEntry<T = CmsEntryValues> {
|
|
20
20
|
webinyVersion: string;
|
|
21
21
|
tenant: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
2
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
3
|
-
export
|
|
3
|
+
export type FileDataMigrationCheckpoint = Record<string, string | boolean | undefined>;
|
|
4
4
|
export declare class TenantLinkRecords_5_37_0_001_FileData implements DataMigration<FileDataMigrationCheckpoint> {
|
|
5
5
|
private readonly tenantEntity;
|
|
6
6
|
private readonly tenantLinkEntity;
|
|
@@ -15,7 +15,7 @@ export interface Identity {
|
|
|
15
15
|
export interface CmsEntryValues {
|
|
16
16
|
[key: string]: any;
|
|
17
17
|
}
|
|
18
|
-
export
|
|
18
|
+
export type CmsEntryStatus = "published" | "unpublished" | "draft";
|
|
19
19
|
export interface CmsEntry<T = CmsEntryValues> {
|
|
20
20
|
webinyVersion: string;
|
|
21
21
|
tenant: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
2
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
3
|
-
export
|
|
3
|
+
export type AcoFolderMigrationCheckpoint = Record<string, string | boolean | undefined>;
|
|
4
4
|
export declare class AcoRecords_5_37_0_003_AcoFolders implements DataMigration<AcoFolderMigrationCheckpoint> {
|
|
5
5
|
private readonly entryEntity;
|
|
6
6
|
private readonly localeEntity;
|
|
@@ -2,7 +2,7 @@ import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
|
2
2
|
import { Client } from "@elastic/elasticsearch";
|
|
3
3
|
import { PrimitiveValue } from "@webiny/api-elasticsearch/types";
|
|
4
4
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
5
|
-
export
|
|
5
|
+
export type AcoFolderDataMigrationCheckpoint = Record<string, PrimitiveValue[] | boolean | undefined>;
|
|
6
6
|
export declare class AcoRecords_5_37_0_003_AcoFolder implements DataMigration<AcoFolderDataMigrationCheckpoint> {
|
|
7
7
|
private readonly elasticsearchClient;
|
|
8
8
|
private readonly ddbEntryEntity;
|
|
@@ -15,7 +15,7 @@ export interface Identity {
|
|
|
15
15
|
export interface CmsEntryValues {
|
|
16
16
|
[key: string]: any;
|
|
17
17
|
}
|
|
18
|
-
export
|
|
18
|
+
export type CmsEntryStatus = "published" | "unpublished" | "draft";
|
|
19
19
|
export interface CmsEntry<T = CmsEntryValues> {
|
|
20
20
|
webinyVersion: string;
|
|
21
21
|
tenant: string;
|
|
@@ -40,7 +40,7 @@ export interface CmsEntry<T = CmsEntryValues> {
|
|
|
40
40
|
export interface CmsEntryAcoFolderValues {
|
|
41
41
|
parentId?: string | null;
|
|
42
42
|
}
|
|
43
|
-
export
|
|
43
|
+
export type CmsEntryAcoFolder = CmsEntry<CmsEntryAcoFolderValues>;
|
|
44
44
|
export interface ListLocalesParams {
|
|
45
45
|
tenant: Tenant;
|
|
46
46
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
2
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
3
|
-
export
|
|
3
|
+
export type PageDataMigrationCheckpoint = Record<string, string | boolean | undefined>;
|
|
4
4
|
export declare class AcoRecords_5_37_0_004_PageData implements DataMigration<PageDataMigrationCheckpoint> {
|
|
5
5
|
private readonly entryEntity;
|
|
6
6
|
private readonly localeEntity;
|
|
@@ -2,7 +2,7 @@ import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
|
2
2
|
import { Client } from "@elastic/elasticsearch";
|
|
3
3
|
import { PrimitiveValue } from "@webiny/api-elasticsearch/types";
|
|
4
4
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
5
|
-
export
|
|
5
|
+
export type PageDataMigrationCheckpoint = Record<string, PrimitiveValue[] | boolean | undefined>;
|
|
6
6
|
export declare class AcoRecords_5_37_0_004_PageData implements DataMigration<PageDataMigrationCheckpoint> {
|
|
7
7
|
private readonly elasticsearchClient;
|
|
8
8
|
private readonly ddbEntryEntity;
|
|
@@ -15,7 +15,7 @@ export interface Identity {
|
|
|
15
15
|
export interface CmsEntryValues {
|
|
16
16
|
[key: string]: any;
|
|
17
17
|
}
|
|
18
|
-
export
|
|
18
|
+
export type CmsEntryStatus = "published" | "unpublished" | "draft";
|
|
19
19
|
export interface CmsEntry<T = CmsEntryValues> {
|
|
20
20
|
webinyVersion: string;
|
|
21
21
|
tenant: string;
|
|
@@ -63,7 +63,7 @@ export interface PageSettings {
|
|
|
63
63
|
};
|
|
64
64
|
[key: string]: any;
|
|
65
65
|
}
|
|
66
|
-
export
|
|
66
|
+
export type PageStatus = "published" | "unpublished" | "draft";
|
|
67
67
|
export interface Page {
|
|
68
68
|
id: string;
|
|
69
69
|
pid: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
2
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
3
|
-
|
|
3
|
+
type FileDataMigrationCheckpoint = Record<string, string | boolean | undefined>;
|
|
4
4
|
export declare class FileManager_5_37_0_005 implements DataMigration<FileDataMigrationCheckpoint> {
|
|
5
5
|
private readonly entryEntity;
|
|
6
6
|
private readonly localeEntity;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
2
|
import { Client } from "@elastic/elasticsearch";
|
|
3
3
|
import { DataMigration, DataMigrationContext } from "@webiny/data-migration";
|
|
4
|
-
|
|
4
|
+
type FileDataMigrationCheckpoint = Record<string, string | boolean | undefined>;
|
|
5
5
|
export declare class FileManager_5_37_0_005 implements DataMigration<FileDataMigrationCheckpoint> {
|
|
6
6
|
private readonly elasticsearchClient;
|
|
7
7
|
private readonly ddbEntryEntity;
|
|
@@ -15,7 +15,7 @@ export interface Identity {
|
|
|
15
15
|
export interface CmsEntryValues {
|
|
16
16
|
[key: string]: any;
|
|
17
17
|
}
|
|
18
|
-
export
|
|
18
|
+
export type CmsEntryStatus = "published" | "unpublished" | "draft";
|
|
19
19
|
export interface CmsEntry<T = CmsEntryValues> {
|
|
20
20
|
webinyVersion: string;
|
|
21
21
|
tenant: string;
|
|
@@ -16,7 +16,7 @@ export interface Identity {
|
|
|
16
16
|
export interface CmsEntryValues {
|
|
17
17
|
[key: string]: any;
|
|
18
18
|
}
|
|
19
|
-
export
|
|
19
|
+
export type CmsEntryStatus = "published" | "unpublished" | "draft";
|
|
20
20
|
export interface CmsEntry<T = CmsEntryValues> {
|
|
21
21
|
webinyVersion: string;
|
|
22
22
|
tenant: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DynamoDBDocument } from "@webiny/aws-sdk/client-dynamodb";
|
|
2
2
|
import { IWaitUntilHealthyParams } from "@webiny/api-elasticsearch";
|
|
3
|
-
export
|
|
3
|
+
export type EsHealthChecksParams = Required<IWaitUntilHealthyParams>;
|
|
4
4
|
export declare const DEFAULT_ES_HEALTH_CHECKS_PARAMS: EsHealthChecksParams;
|
|
5
5
|
export declare const migrationSkippedDdbRecord: {
|
|
6
6
|
PK: string;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
|
+
export declare const createTenantEntity: (table: Table<string, string, string>) => import("dynamodb-toolbox/dist/cjs/classes/Entity/Entity").default<string, import("dynamodb-toolbox/dist/cjs/classes/Entity").Overlay, import("dynamodb-toolbox/dist/cjs/classes/Entity").Overlay, Table<string, string, string>, true, true, boolean, string, string, string, boolean, {
|
|
3
|
+
PK: {
|
|
4
|
+
partitionKey: true;
|
|
5
|
+
};
|
|
6
|
+
SK: {
|
|
7
|
+
sortKey: true;
|
|
8
|
+
};
|
|
9
|
+
GSI1_PK: {
|
|
10
|
+
type: "string";
|
|
11
|
+
};
|
|
12
|
+
GSI1_SK: {
|
|
13
|
+
type: "string";
|
|
14
|
+
};
|
|
15
|
+
TYPE: {
|
|
16
|
+
type: "string";
|
|
17
|
+
};
|
|
18
|
+
}, {
|
|
19
|
+
PK: {
|
|
20
|
+
partitionKey: true;
|
|
21
|
+
};
|
|
22
|
+
SK: {
|
|
23
|
+
sortKey: true;
|
|
24
|
+
};
|
|
25
|
+
GSI1_PK: {
|
|
26
|
+
type: "string";
|
|
27
|
+
};
|
|
28
|
+
GSI1_SK: {
|
|
29
|
+
type: "string";
|
|
30
|
+
};
|
|
31
|
+
TYPE: {
|
|
32
|
+
type: "string";
|
|
33
|
+
};
|
|
34
|
+
}, import("dynamodb-toolbox/dist/cjs/classes/Entity").ParsedAttributes<import("ts-toolbelt/out/Any/Key").Key>, any, {
|
|
35
|
+
[x: string]: any;
|
|
36
|
+
[x: number]: any;
|
|
37
|
+
[x: symbol]: any;
|
|
38
|
+
}, {
|
|
39
|
+
[x: string]: any;
|
|
40
|
+
[x: number]: any;
|
|
41
|
+
[x: symbol]: any;
|
|
42
|
+
}>;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.createTenantEntity = void 0;
|
|
7
|
+
var _utils = require("../../../utils");
|
|
8
|
+
const createTenantEntity = table => {
|
|
9
|
+
return (0, _utils.createLegacyEntity)(table, "TenancyTenant", {
|
|
10
|
+
id: {
|
|
11
|
+
type: "string"
|
|
12
|
+
},
|
|
13
|
+
name: {
|
|
14
|
+
type: "string"
|
|
15
|
+
},
|
|
16
|
+
description: {
|
|
17
|
+
type: "string"
|
|
18
|
+
},
|
|
19
|
+
status: {
|
|
20
|
+
type: "string",
|
|
21
|
+
default: "active"
|
|
22
|
+
},
|
|
23
|
+
createdOn: {
|
|
24
|
+
type: "string"
|
|
25
|
+
},
|
|
26
|
+
savedOn: {
|
|
27
|
+
type: "string"
|
|
28
|
+
},
|
|
29
|
+
createdBy: {
|
|
30
|
+
type: "map"
|
|
31
|
+
},
|
|
32
|
+
parent: {
|
|
33
|
+
type: "string"
|
|
34
|
+
},
|
|
35
|
+
webinyVersion: {
|
|
36
|
+
type: "string"
|
|
37
|
+
},
|
|
38
|
+
settings: {
|
|
39
|
+
type: "map",
|
|
40
|
+
default: {}
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
};
|
|
44
|
+
exports.createTenantEntity = createTenantEntity;
|
|
45
|
+
|
|
46
|
+
//# sourceMappingURL=createTenantEntity.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_utils","require","createTenantEntity","table","createLegacyEntity","id","type","name","description","status","default","createdOn","savedOn","createdBy","parent","webinyVersion","settings","exports"],"sources":["createTenantEntity.ts"],"sourcesContent":["import { Table } from \"@webiny/db-dynamodb/toolbox\";\nimport { createLegacyEntity } from \"~/utils\";\n\nexport const createTenantEntity = (table: Table<string, string, string>) => {\n return createLegacyEntity(table, \"TenancyTenant\", {\n id: {\n type: \"string\"\n },\n name: {\n type: \"string\"\n },\n description: {\n type: \"string\"\n },\n status: {\n type: \"string\",\n default: \"active\"\n },\n createdOn: {\n type: \"string\"\n },\n savedOn: {\n type: \"string\"\n },\n createdBy: {\n type: \"map\"\n },\n parent: {\n type: \"string\"\n },\n webinyVersion: {\n type: \"string\"\n },\n settings: {\n type: \"map\",\n default: {}\n }\n });\n};\n"],"mappings":";;;;;;AACA,IAAAA,MAAA,GAAAC,OAAA;AAEO,MAAMC,kBAAkB,GAAIC,KAAoC,IAAK;EACxE,OAAO,IAAAC,yBAAkB,EAACD,KAAK,EAAE,eAAe,EAAE;IAC9CE,EAAE,EAAE;MACAC,IAAI,EAAE;IACV,CAAC;IACDC,IAAI,EAAE;MACFD,IAAI,EAAE;IACV,CAAC;IACDE,WAAW,EAAE;MACTF,IAAI,EAAE;IACV,CAAC;IACDG,MAAM,EAAE;MACJH,IAAI,EAAE,QAAQ;MACdI,OAAO,EAAE;IACb,CAAC;IACDC,SAAS,EAAE;MACPL,IAAI,EAAE;IACV,CAAC;IACDM,OAAO,EAAE;MACLN,IAAI,EAAE;IACV,CAAC;IACDO,SAAS,EAAE;MACPP,IAAI,EAAE;IACV,CAAC;IACDQ,MAAM,EAAE;MACJR,IAAI,EAAE;IACV,CAAC;IACDS,aAAa,EAAE;MACXT,IAAI,EAAE;IACV,CAAC;IACDU,QAAQ,EAAE;MACNV,IAAI,EAAE,KAAK;MACXI,OAAO,EAAE,CAAC;IACd;EACJ,CAAC,CAAC;AACN,CAAC;AAACO,OAAA,CAAAf,kBAAA,GAAAA,kBAAA","ignoreList":[]}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
|
+
export declare const createUserEntity: (table: Table<string, string, string>) => import("dynamodb-toolbox/dist/cjs/classes/Entity/Entity").default<string, import("dynamodb-toolbox/dist/cjs/classes/Entity").Overlay, import("dynamodb-toolbox/dist/cjs/classes/Entity").Overlay, Table<string, string, string>, true, true, boolean, string, string, string, boolean, {
|
|
3
|
+
PK: {
|
|
4
|
+
partitionKey: true;
|
|
5
|
+
};
|
|
6
|
+
SK: {
|
|
7
|
+
sortKey: true;
|
|
8
|
+
};
|
|
9
|
+
GSI1_PK: {
|
|
10
|
+
type: "string";
|
|
11
|
+
};
|
|
12
|
+
GSI1_SK: {
|
|
13
|
+
type: "string";
|
|
14
|
+
};
|
|
15
|
+
TYPE: {
|
|
16
|
+
type: "string";
|
|
17
|
+
};
|
|
18
|
+
data: {
|
|
19
|
+
type: "map";
|
|
20
|
+
};
|
|
21
|
+
}, {
|
|
22
|
+
PK: {
|
|
23
|
+
partitionKey: true;
|
|
24
|
+
};
|
|
25
|
+
SK: {
|
|
26
|
+
sortKey: true;
|
|
27
|
+
};
|
|
28
|
+
GSI1_PK: {
|
|
29
|
+
type: "string";
|
|
30
|
+
};
|
|
31
|
+
GSI1_SK: {
|
|
32
|
+
type: "string";
|
|
33
|
+
};
|
|
34
|
+
TYPE: {
|
|
35
|
+
type: "string";
|
|
36
|
+
};
|
|
37
|
+
data: {
|
|
38
|
+
type: "map";
|
|
39
|
+
};
|
|
40
|
+
}, import("dynamodb-toolbox/dist/cjs/classes/Entity").ParsedAttributes<import("ts-toolbelt/out/Any/Key").Key>, any, {
|
|
41
|
+
[x: string]: any;
|
|
42
|
+
[x: number]: any;
|
|
43
|
+
[x: symbol]: any;
|
|
44
|
+
}, {
|
|
45
|
+
[x: string]: any;
|
|
46
|
+
[x: number]: any;
|
|
47
|
+
[x: symbol]: any;
|
|
48
|
+
}>;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.createUserEntity = void 0;
|
|
7
|
+
var _utils = require("../../../utils");
|
|
8
|
+
const attributes = {
|
|
9
|
+
id: {
|
|
10
|
+
type: "string"
|
|
11
|
+
},
|
|
12
|
+
tenant: {
|
|
13
|
+
type: "string"
|
|
14
|
+
},
|
|
15
|
+
email: {
|
|
16
|
+
type: "string"
|
|
17
|
+
},
|
|
18
|
+
firstName: {
|
|
19
|
+
type: "string"
|
|
20
|
+
},
|
|
21
|
+
lastName: {
|
|
22
|
+
type: "string"
|
|
23
|
+
},
|
|
24
|
+
avatar: {
|
|
25
|
+
type: "map"
|
|
26
|
+
},
|
|
27
|
+
createdBy: {
|
|
28
|
+
type: "map"
|
|
29
|
+
},
|
|
30
|
+
createdOn: {
|
|
31
|
+
type: "string"
|
|
32
|
+
},
|
|
33
|
+
group: {
|
|
34
|
+
type: "string"
|
|
35
|
+
},
|
|
36
|
+
team: {
|
|
37
|
+
type: "string"
|
|
38
|
+
},
|
|
39
|
+
groups: {
|
|
40
|
+
type: "map"
|
|
41
|
+
},
|
|
42
|
+
teams: {
|
|
43
|
+
type: "map"
|
|
44
|
+
},
|
|
45
|
+
webinyVersion: {
|
|
46
|
+
type: "string"
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
const createUserEntity = table => {
|
|
50
|
+
return (0, _utils.createStandardEntity)(table, "AdminUsers.User", attributes);
|
|
51
|
+
};
|
|
52
|
+
exports.createUserEntity = createUserEntity;
|
|
53
|
+
|
|
54
|
+
//# sourceMappingURL=createUserEntity.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_utils","require","attributes","id","type","tenant","email","firstName","lastName","avatar","createdBy","createdOn","group","team","groups","teams","webinyVersion","createUserEntity","table","createStandardEntity","exports"],"sources":["createUserEntity.ts"],"sourcesContent":["import { Table } from \"@webiny/db-dynamodb/toolbox\";\nimport { createLegacyEntity, createStandardEntity } from \"~/utils\";\n\nconst attributes: Parameters<typeof createLegacyEntity>[2] = {\n id: {\n type: \"string\"\n },\n tenant: {\n type: \"string\"\n },\n email: {\n type: \"string\"\n },\n firstName: {\n type: \"string\"\n },\n lastName: {\n type: \"string\"\n },\n avatar: {\n type: \"map\"\n },\n createdBy: {\n type: \"map\"\n },\n createdOn: {\n type: \"string\"\n },\n group: {\n type: \"string\"\n },\n team: {\n type: \"string\"\n },\n groups: {\n type: \"map\"\n },\n teams: {\n type: \"map\"\n },\n webinyVersion: {\n type: \"string\"\n }\n};\n\nexport const createUserEntity = (table: Table<string, string, string>) => {\n return createStandardEntity(table, \"AdminUsers.User\", attributes);\n};\n"],"mappings":";;;;;;AACA,IAAAA,MAAA,GAAAC,OAAA;AAEA,MAAMC,UAAoD,GAAG;EACzDC,EAAE,EAAE;IACAC,IAAI,EAAE;EACV,CAAC;EACDC,MAAM,EAAE;IACJD,IAAI,EAAE;EACV,CAAC;EACDE,KAAK,EAAE;IACHF,IAAI,EAAE;EACV,CAAC;EACDG,SAAS,EAAE;IACPH,IAAI,EAAE;EACV,CAAC;EACDI,QAAQ,EAAE;IACNJ,IAAI,EAAE;EACV,CAAC;EACDK,MAAM,EAAE;IACJL,IAAI,EAAE;EACV,CAAC;EACDM,SAAS,EAAE;IACPN,IAAI,EAAE;EACV,CAAC;EACDO,SAAS,EAAE;IACPP,IAAI,EAAE;EACV,CAAC;EACDQ,KAAK,EAAE;IACHR,IAAI,EAAE;EACV,CAAC;EACDS,IAAI,EAAE;IACFT,IAAI,EAAE;EACV,CAAC;EACDU,MAAM,EAAE;IACJV,IAAI,EAAE;EACV,CAAC;EACDW,KAAK,EAAE;IACHX,IAAI,EAAE;EACV,CAAC;EACDY,aAAa,EAAE;IACXZ,IAAI,EAAE;EACV;AACJ,CAAC;AAEM,MAAMa,gBAAgB,GAAIC,KAAoC,IAAK;EACtE,OAAO,IAAAC,2BAAoB,EAACD,KAAK,EAAE,iBAAiB,EAAEhB,UAAU,CAAC;AACrE,CAAC;AAACkB,OAAA,CAAAH,gBAAA,GAAAA,gBAAA","ignoreList":[]}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
|
+
import { DataMigrationContext } from "@webiny/data-migration";
|
|
3
|
+
export declare class AdminUsers_5_41_0_001 {
|
|
4
|
+
private readonly newUserEntity;
|
|
5
|
+
private readonly tenantEntity;
|
|
6
|
+
constructor(table: Table<string, string, string>);
|
|
7
|
+
getId(): string;
|
|
8
|
+
getDescription(): string;
|
|
9
|
+
shouldExecute({ logger }: DataMigrationContext): Promise<boolean>;
|
|
10
|
+
execute({ logger }: DataMigrationContext): Promise<void>;
|
|
11
|
+
}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.AdminUsers_5_41_0_001 = void 0;
|
|
7
|
+
var _dataMigration = require("@webiny/data-migration");
|
|
8
|
+
var _utils = require("../../../utils");
|
|
9
|
+
var _createTenantEntity = require("./createTenantEntity");
|
|
10
|
+
var _createUserEntity = require("./createUserEntity");
|
|
11
|
+
var _ioc = require("@webiny/ioc");
|
|
12
|
+
var _utils2 = require("@webiny/utils");
|
|
13
|
+
class AdminUsers_5_41_0_001 {
|
|
14
|
+
constructor(table) {
|
|
15
|
+
this.newUserEntity = (0, _createUserEntity.createUserEntity)(table);
|
|
16
|
+
this.tenantEntity = (0, _createTenantEntity.createTenantEntity)(table);
|
|
17
|
+
}
|
|
18
|
+
getId() {
|
|
19
|
+
return "5.41.0-001";
|
|
20
|
+
}
|
|
21
|
+
getDescription() {
|
|
22
|
+
return "Introduce 'groups' and 'teams` properties (old 'group' and 'team' are no longer in use)";
|
|
23
|
+
}
|
|
24
|
+
async shouldExecute({
|
|
25
|
+
logger
|
|
26
|
+
}) {
|
|
27
|
+
const user = await (0, _utils.queryOne)({
|
|
28
|
+
entity: this.newUserEntity,
|
|
29
|
+
partitionKey: `T#root#ADMIN_USERS`,
|
|
30
|
+
options: {
|
|
31
|
+
index: "GSI1",
|
|
32
|
+
gt: " "
|
|
33
|
+
}
|
|
34
|
+
});
|
|
35
|
+
if (!user) {
|
|
36
|
+
logger.info(`No users were found; skipping migration.`);
|
|
37
|
+
return false;
|
|
38
|
+
}
|
|
39
|
+
if (Array.isArray(user.data.groups)) {
|
|
40
|
+
logger.info(`User records seems to be in order; skipping migration.`);
|
|
41
|
+
return false;
|
|
42
|
+
}
|
|
43
|
+
return true;
|
|
44
|
+
}
|
|
45
|
+
async execute({
|
|
46
|
+
logger
|
|
47
|
+
}) {
|
|
48
|
+
const tenants = await (0, _utils.queryAll)({
|
|
49
|
+
entity: this.tenantEntity,
|
|
50
|
+
partitionKey: "TENANTS",
|
|
51
|
+
options: {
|
|
52
|
+
index: "GSI1",
|
|
53
|
+
gt: " "
|
|
54
|
+
}
|
|
55
|
+
});
|
|
56
|
+
for (const tenant of tenants) {
|
|
57
|
+
const users = await (0, _utils.queryAll)({
|
|
58
|
+
entity: this.newUserEntity,
|
|
59
|
+
partitionKey: `T#${tenant.id}#ADMIN_USERS`,
|
|
60
|
+
options: {
|
|
61
|
+
index: "GSI1",
|
|
62
|
+
gt: " "
|
|
63
|
+
}
|
|
64
|
+
});
|
|
65
|
+
if (users.length === 0) {
|
|
66
|
+
logger.info(`No users found on tenant "${tenant.id}".`);
|
|
67
|
+
continue;
|
|
68
|
+
}
|
|
69
|
+
const newUsers = users.filter(user => !Array.isArray(user.data.groups)).map(user => {
|
|
70
|
+
return this.newUserEntity.putBatch({
|
|
71
|
+
...user,
|
|
72
|
+
data: {
|
|
73
|
+
...user.data,
|
|
74
|
+
groups: [user.data.group].filter(Boolean),
|
|
75
|
+
teams: [user.data.team].filter(Boolean)
|
|
76
|
+
}
|
|
77
|
+
});
|
|
78
|
+
});
|
|
79
|
+
await (0, _utils2.executeWithRetry)(() => (0, _utils.batchWriteAll)({
|
|
80
|
+
table: this.newUserEntity.table,
|
|
81
|
+
items: newUsers
|
|
82
|
+
}));
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
exports.AdminUsers_5_41_0_001 = AdminUsers_5_41_0_001;
|
|
87
|
+
(0, _ioc.makeInjectable)(AdminUsers_5_41_0_001, [(0, _ioc.inject)(_dataMigration.PrimaryDynamoTableSymbol)]);
|
|
88
|
+
|
|
89
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_dataMigration","require","_utils","_createTenantEntity","_createUserEntity","_ioc","_utils2","AdminUsers_5_41_0_001","constructor","table","newUserEntity","createUserEntity","tenantEntity","createTenantEntity","getId","getDescription","shouldExecute","logger","user","queryOne","entity","partitionKey","options","index","gt","info","Array","isArray","data","groups","execute","tenants","queryAll","tenant","users","id","length","newUsers","filter","map","putBatch","group","Boolean","teams","team","executeWithRetry","batchWriteAll","items","exports","makeInjectable","inject","PrimaryDynamoTableSymbol"],"sources":["index.ts"],"sourcesContent":["import { Table } from \"@webiny/db-dynamodb/toolbox\";\nimport { DataMigrationContext, PrimaryDynamoTableSymbol } from \"@webiny/data-migration\";\nimport { queryOne, queryAll, batchWriteAll } from \"~/utils\";\nimport { createTenantEntity } from \"./createTenantEntity\";\nimport { createUserEntity } from \"./createUserEntity\";\nimport { makeInjectable, inject } from \"@webiny/ioc\";\nimport { executeWithRetry } from \"@webiny/utils\";\n\nexport class AdminUsers_5_41_0_001 {\n private readonly newUserEntity: ReturnType<typeof createUserEntity>;\n private readonly tenantEntity: ReturnType<typeof createTenantEntity>;\n\n constructor(table: Table<string, string, string>) {\n this.newUserEntity = createUserEntity(table);\n this.tenantEntity = createTenantEntity(table);\n }\n\n getId() {\n return \"5.41.0-001\";\n }\n\n getDescription() {\n return \"Introduce 'groups' and 'teams` properties (old 'group' and 'team' are no longer in use)\";\n }\n\n async shouldExecute({ logger }: DataMigrationContext): Promise<boolean> {\n const user = await queryOne<{ data: any }>({\n entity: this.newUserEntity,\n partitionKey: `T#root#ADMIN_USERS`,\n options: {\n index: \"GSI1\",\n gt: \" \"\n }\n });\n\n if (!user) {\n logger.info(`No users were found; skipping migration.`);\n return false;\n }\n\n if (Array.isArray(user.data.groups)) {\n logger.info(`User records seems to be in order; skipping migration.`);\n return false;\n }\n\n return true;\n }\n\n async execute({ logger }: DataMigrationContext): Promise<void> {\n const tenants = await queryAll<{ id: string; name: string }>({\n entity: this.tenantEntity,\n partitionKey: \"TENANTS\",\n options: {\n index: \"GSI1\",\n gt: \" \"\n }\n });\n\n for (const tenant of tenants) {\n const users = await queryAll<{ id: string; email: string; data?: any }>({\n entity: this.newUserEntity,\n partitionKey: `T#${tenant.id}#ADMIN_USERS`,\n options: {\n index: \"GSI1\",\n gt: \" \"\n }\n });\n\n if (users.length === 0) {\n logger.info(`No users found on tenant \"${tenant.id}\".`);\n continue;\n }\n\n const newUsers = users\n .filter(user => !Array.isArray(user.data.groups))\n .map(user => {\n return this.newUserEntity.putBatch({\n ...user,\n data: {\n ...user.data,\n groups: [user.data.group].filter(Boolean),\n teams: [user.data.team].filter(Boolean)\n }\n });\n });\n\n await executeWithRetry(() =>\n batchWriteAll({ table: this.newUserEntity.table, items: newUsers })\n );\n }\n }\n}\n\nmakeInjectable(AdminUsers_5_41_0_001, [inject(PrimaryDynamoTableSymbol)]);\n"],"mappings":"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","ignoreList":[]}
|
package/package.json
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webiny/migrations",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.41.0-beta.0",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"build": "yarn webiny run build",
|
|
6
6
|
"watch": "yarn webiny run watch"
|
|
7
7
|
},
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"@elastic/elasticsearch": "7.12.0",
|
|
10
|
-
"@webiny/api-elasticsearch": "5.
|
|
11
|
-
"@webiny/aws-sdk": "5.
|
|
12
|
-
"@webiny/cli-plugin-deploy-pulumi": "5.
|
|
13
|
-
"@webiny/data-migration": "5.
|
|
14
|
-
"@webiny/db-dynamodb": "5.
|
|
15
|
-
"@webiny/error": "5.
|
|
16
|
-
"@webiny/ioc": "5.
|
|
17
|
-
"@webiny/logger": "5.
|
|
18
|
-
"@webiny/utils": "5.
|
|
10
|
+
"@webiny/api-elasticsearch": "5.41.0-beta.0",
|
|
11
|
+
"@webiny/aws-sdk": "5.41.0-beta.0",
|
|
12
|
+
"@webiny/cli-plugin-deploy-pulumi": "5.41.0-beta.0",
|
|
13
|
+
"@webiny/data-migration": "5.41.0-beta.0",
|
|
14
|
+
"@webiny/db-dynamodb": "5.41.0-beta.0",
|
|
15
|
+
"@webiny/error": "5.41.0-beta.0",
|
|
16
|
+
"@webiny/ioc": "5.41.0-beta.0",
|
|
17
|
+
"@webiny/logger": "5.41.0-beta.0",
|
|
18
|
+
"@webiny/utils": "5.41.0-beta.0",
|
|
19
19
|
"execa": "5.1.1",
|
|
20
20
|
"fast-glob": "3.2.12",
|
|
21
21
|
"jsonpack": "1.1.5",
|
|
@@ -30,16 +30,16 @@
|
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@types/execa": "2.0.0",
|
|
33
|
-
"@webiny/api-headless-cms": "5.
|
|
34
|
-
"@webiny/api-headless-cms-ddb-es": "5.
|
|
35
|
-
"@webiny/cli": "5.
|
|
36
|
-
"@webiny/handler-aws": "5.
|
|
37
|
-
"@webiny/plugins": "5.
|
|
38
|
-
"@webiny/project-utils": "5.
|
|
33
|
+
"@webiny/api-headless-cms": "5.41.0-beta.0",
|
|
34
|
+
"@webiny/api-headless-cms-ddb-es": "5.41.0-beta.0",
|
|
35
|
+
"@webiny/cli": "5.41.0-beta.0",
|
|
36
|
+
"@webiny/handler-aws": "5.41.0-beta.0",
|
|
37
|
+
"@webiny/plugins": "5.41.0-beta.0",
|
|
38
|
+
"@webiny/project-utils": "5.41.0-beta.0",
|
|
39
39
|
"elastic-ts": "0.8.0",
|
|
40
40
|
"jest-dynalite": "3.6.1",
|
|
41
41
|
"ttypescript": "1.5.15",
|
|
42
|
-
"typescript": "4.
|
|
42
|
+
"typescript": "4.9.5"
|
|
43
43
|
},
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "9ce5e75fc577aa4de2cf08d5ca734b3c98fe65b6"
|
|
45
45
|
}
|
|
@@ -6,6 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.esGetIndexName = void 0;
|
|
8
8
|
var _error = _interopRequireDefault(require("@webiny/error"));
|
|
9
|
+
var _apiElasticsearch = require("@webiny/api-elasticsearch");
|
|
9
10
|
const esGetIndexName = params => {
|
|
10
11
|
const {
|
|
11
12
|
tenant,
|
|
@@ -19,7 +20,7 @@ const esGetIndexName = params => {
|
|
|
19
20
|
if (!tenant) {
|
|
20
21
|
throw new _error.default(`Missing "tenant" parameter when trying to create Elasticsearch index name.`, "TENANT_ERROR");
|
|
21
22
|
}
|
|
22
|
-
const sharedIndex =
|
|
23
|
+
const sharedIndex = (0, _apiElasticsearch.isSharedElasticsearchIndex)();
|
|
23
24
|
const tenantId = sharedIndex ? "root" : tenant;
|
|
24
25
|
let localeCode = null;
|
|
25
26
|
if (isHeadlessCmsModel || process.env.WEBINY_ELASTICSEARCH_INDEX_LOCALE === "true") {
|
|
@@ -29,7 +30,7 @@ const esGetIndexName = params => {
|
|
|
29
30
|
localeCode = locale;
|
|
30
31
|
}
|
|
31
32
|
const index = [tenantId, isHeadlessCmsModel && "headless-cms", localeCode, type].filter(Boolean).join("-").toLowerCase();
|
|
32
|
-
const prefix =
|
|
33
|
+
const prefix = (0, _apiElasticsearch.getElasticsearchIndexPrefix)();
|
|
33
34
|
if (!prefix) {
|
|
34
35
|
return index;
|
|
35
36
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_error","_interopRequireDefault","require","esGetIndexName","params","tenant","locale","type","isHeadlessCmsModel","WebinyError","sharedIndex","
|
|
1
|
+
{"version":3,"names":["_error","_interopRequireDefault","require","_apiElasticsearch","esGetIndexName","params","tenant","locale","type","isHeadlessCmsModel","WebinyError","sharedIndex","isSharedElasticsearchIndex","tenantId","localeCode","process","env","WEBINY_ELASTICSEARCH_INDEX_LOCALE","index","filter","Boolean","join","toLowerCase","prefix","getElasticsearchIndexPrefix","exports"],"sources":["esGetIndexName.ts"],"sourcesContent":["import WebinyError from \"@webiny/error\";\nimport { getElasticsearchIndexPrefix, isSharedElasticsearchIndex } from \"@webiny/api-elasticsearch\";\n\nexport interface EsGetIndexNameParams {\n tenant: string;\n locale: string;\n type: string;\n isHeadlessCmsModel?: boolean;\n}\n\nexport const esGetIndexName = (params: EsGetIndexNameParams) => {\n const { tenant, locale, type, isHeadlessCmsModel } = params;\n\n if (!type) {\n throw new WebinyError(\n `Missing \"type\" parameter when trying to create Elasticsearch index name.`,\n \"INDEX_TYPE_ERROR\"\n );\n }\n\n if (!tenant) {\n throw new WebinyError(\n `Missing \"tenant\" parameter when trying to create Elasticsearch index name.`,\n \"TENANT_ERROR\"\n );\n }\n\n const sharedIndex = isSharedElasticsearchIndex();\n\n const tenantId = sharedIndex ? \"root\" : tenant;\n let localeCode: string | null = null;\n if (isHeadlessCmsModel || process.env.WEBINY_ELASTICSEARCH_INDEX_LOCALE === \"true\") {\n if (!locale) {\n throw new WebinyError(\n `Missing \"locale\" parameter when trying to create Elasticsearch index name.`,\n \"LOCALE_ERROR\"\n );\n }\n localeCode = locale;\n }\n\n const index = [tenantId, isHeadlessCmsModel && \"headless-cms\", localeCode, type]\n .filter(Boolean)\n .join(\"-\")\n .toLowerCase();\n\n const prefix = getElasticsearchIndexPrefix();\n if (!prefix) {\n return index;\n }\n return prefix + index;\n};\n"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,iBAAA,GAAAD,OAAA;AASO,MAAME,cAAc,GAAIC,MAA4B,IAAK;EAC5D,MAAM;IAAEC,MAAM;IAAEC,MAAM;IAAEC,IAAI;IAAEC;EAAmB,CAAC,GAAGJ,MAAM;EAE3D,IAAI,CAACG,IAAI,EAAE;IACP,MAAM,IAAIE,cAAW,CAChB,0EAAyE,EAC1E,kBACJ,CAAC;EACL;EAEA,IAAI,CAACJ,MAAM,EAAE;IACT,MAAM,IAAII,cAAW,CAChB,4EAA2E,EAC5E,cACJ,CAAC;EACL;EAEA,MAAMC,WAAW,GAAG,IAAAC,4CAA0B,EAAC,CAAC;EAEhD,MAAMC,QAAQ,GAAGF,WAAW,GAAG,MAAM,GAAGL,MAAM;EAC9C,IAAIQ,UAAyB,GAAG,IAAI;EACpC,IAAIL,kBAAkB,IAAIM,OAAO,CAACC,GAAG,CAACC,iCAAiC,KAAK,MAAM,EAAE;IAChF,IAAI,CAACV,MAAM,EAAE;MACT,MAAM,IAAIG,cAAW,CAChB,4EAA2E,EAC5E,cACJ,CAAC;IACL;IACAI,UAAU,GAAGP,MAAM;EACvB;EAEA,MAAMW,KAAK,GAAG,CAACL,QAAQ,EAAEJ,kBAAkB,IAAI,cAAc,EAAEK,UAAU,EAAEN,IAAI,CAAC,CAC3EW,MAAM,CAACC,OAAO,CAAC,CACfC,IAAI,CAAC,GAAG,CAAC,CACTC,WAAW,CAAC,CAAC;EAElB,MAAMC,MAAM,GAAG,IAAAC,6CAA2B,EAAC,CAAC;EAC5C,IAAI,CAACD,MAAM,EAAE;IACT,OAAOL,KAAK;EAChB;EACA,OAAOK,MAAM,GAAGL,KAAK;AACzB,CAAC;AAACO,OAAA,CAAArB,cAAA,GAAAA,cAAA","ignoreList":[]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Table } from "@webiny/db-dynamodb/toolbox";
|
|
2
2
|
import { Logger } from "@webiny/logger";
|
|
3
|
-
|
|
3
|
+
type ForEachTenantLocaleCallback = (params: {
|
|
4
4
|
tenantId: string;
|
|
5
5
|
localeCode: string;
|
|
6
6
|
}) => boolean | Promise<boolean>;
|