-
Notifications
You must be signed in to change notification settings - Fork 109
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix(mixedcontentsourceadapter.ts): error - Delete operation of experiencepropertytype metadata this change is to fix the error during delete operation for experiencepropertytype metadata api. as the bundle is all json files and there is no xml file in place delete operation is failing when the metadata API is failing in the backend and this is the fix for same. * feat(mixedcontentsourceadapter.ts): error during delete operation of experiencepropertytype bundle This change is to fix the error during the delete operation for experiencepropertytype metadata bundle. As the bundle is all JSON files and there is no XML file in the bundle there will be an error when the delete operation fails in the backend and this is the fix for the same. * fix(mixedcontentsourceadapter.test.ts): error during delete operation of experiencepropertytype This change is to fix the error during the delete operation for experiencepropertytype metadata bundle. As the bundle is all JSON files and there is no XML file in the bundle there will be an error when the delete operation fails in the backend and this is the fix for the same. * test: record perf * fix: lint fix * test: record perf --------- Co-authored-by: Prashanth Josyula <prashanth.16@gmail.com> Co-authored-by: svc-cli-bot <svc_cli_bot@salesforce.com>
- Loading branch information
1 parent
c0ef12f
commit 411d011
Showing
12 changed files
with
112 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
test/mock/type-constants/experiencePropertyTypeBundleConstants.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
/* | ||
* Copyright (c) 2020, salesforce.com, inc. | ||
* All rights reserved. | ||
* Licensed under the BSD 3-Clause license. | ||
* For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause | ||
*/ | ||
import { join } from 'path'; | ||
|
||
import { registry, SourceComponent } from '../../../src'; | ||
|
||
/** | ||
* Experience Property Type Bundle will be of the following shape: | ||
* | ||
* experiencePropertyTypeBundles/ | ||
* ├── prop1/ | ||
* | ├── schema.json | ||
* | ├── design.json | ||
* | ||
* schema.json is always expected to be in the bundle, while design.json is optional. | ||
* | ||
* NOTE: there is no -meta.xml. schema.json acts as the meta XML file. | ||
*/ | ||
|
||
// This is the type defined in metadataRegistry.json | ||
const type = registry.types.experiencepropertytypebundle; | ||
|
||
// This will be the root directory experiencePropertyTypeBundles.It is something like /path/to/experiencePropertyTypeBundles | ||
export const TYPE_DIRECTORY = join('path', 'to', type.directoryName); | ||
|
||
// This is the name of the property type we are creating. | ||
export const COMPONENT_NAME = 'prop1'; | ||
|
||
// This is the schema.json and design.json paths inside the property type. | ||
export const CONTENT_NAMES = [type.metaFileSuffix, 'design.json']; | ||
|
||
// This is the complete path to the content. It is something like /path/to/experiencePropertyTypeBundles/prop1/schema.json. | ||
export const CONTENT_PATHS = CONTENT_NAMES.map((n) => join(TYPE_DIRECTORY, join(COMPONENT_NAME, n))); | ||
|
||
// Finally we construct our component. | ||
export const COMPONENT = SourceComponent.createVirtualComponent( | ||
{ | ||
name: COMPONENT_NAME, | ||
type, | ||
content: join(TYPE_DIRECTORY, COMPONENT_NAME), | ||
xml: CONTENT_PATHS[0], | ||
}, | ||
[ | ||
{ | ||
dirPath: TYPE_DIRECTORY, | ||
children: [COMPONENT_NAME], | ||
}, | ||
] | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 5 additions & 5 deletions
10
test/nuts/perfResults/x64-linux-2xIntel-Xeon-CPU-E5-2673-v3-2-40GHz/eda.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
[ | ||
{ | ||
"name": "componentSetCreate", | ||
"duration": 345.28876100000343 | ||
"duration": 360.789472000004 | ||
}, | ||
{ | ||
"name": "sourceToMdapi", | ||
"duration": 8330.387101 | ||
"duration": 8919.91247500002 | ||
}, | ||
{ | ||
"name": "sourceToZip", | ||
"duration": 5822.162848000007 | ||
"duration": 6025.233091000002 | ||
}, | ||
{ | ||
"name": "mdapiToSource", | ||
"duration": 6123.899523999979 | ||
"duration": 6253.451692000002 | ||
} | ||
] | ||
] |
10 changes: 5 additions & 5 deletions
10
test/nuts/perfResults/x64-linux-2xIntel-Xeon-CPU-E5-2673-v3-2-40GHz/lotsOfClasses.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
[ | ||
{ | ||
"name": "componentSetCreate", | ||
"duration": 675.3449159999727 | ||
"duration": 744.0605729999952 | ||
}, | ||
{ | ||
"name": "sourceToMdapi", | ||
"duration": 11995.010080000007 | ||
"duration": 13127.422728999984 | ||
}, | ||
{ | ||
"name": "sourceToZip", | ||
"duration": 9518.928809000005 | ||
"duration": 10371.91620399995 | ||
}, | ||
{ | ||
"name": "mdapiToSource", | ||
"duration": 7432.586432000011 | ||
"duration": 7902.201856 | ||
} | ||
] | ||
] |
10 changes: 5 additions & 5 deletions
10
test/nuts/perfResults/x64-linux-2xIntel-Xeon-CPU-E5-2673-v3-2-40GHz/lotsOfClassesOneDir.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
[ | ||
{ | ||
"name": "componentSetCreate", | ||
"duration": 1170.5348080000258 | ||
"duration": 1188.3639100000146 | ||
}, | ||
{ | ||
"name": "sourceToMdapi", | ||
"duration": 17969.274023000035 | ||
"duration": 18936.191220000037 | ||
}, | ||
{ | ||
"name": "sourceToZip", | ||
"duration": 14706.58613000001 | ||
"duration": 15125.748401999997 | ||
}, | ||
{ | ||
"name": "mdapiToSource", | ||
"duration": 13242.275161000027 | ||
"duration": 12817.04882299999 | ||
} | ||
] | ||
] |
10 changes: 5 additions & 5 deletions
10
test/nuts/perfResults/x64-linux-2xIntel-Xeon-Platinum-8272CL-CPU-2-60GHz/eda.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
[ | ||
{ | ||
"name": "componentSetCreate", | ||
"duration": 222.67407499998808 | ||
"duration": 226.34448500000872 | ||
}, | ||
{ | ||
"name": "sourceToMdapi", | ||
"duration": 6166.7441540000145 | ||
"duration": 4705.3344459999935 | ||
}, | ||
{ | ||
"name": "sourceToZip", | ||
"duration": 4826.558009000029 | ||
"duration": 4886.161657999997 | ||
}, | ||
{ | ||
"name": "mdapiToSource", | ||
"duration": 4281.85755700001 | ||
"duration": 4058.82406600003 | ||
} | ||
] | ||
] |
10 changes: 5 additions & 5 deletions
10
test/nuts/perfResults/x64-linux-2xIntel-Xeon-Platinum-8272CL-CPU-2-60GHz/lotsOfClasses.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
[ | ||
{ | ||
"name": "componentSetCreate", | ||
"duration": 442.19902300002286 | ||
"duration": 447.82590599998366 | ||
}, | ||
{ | ||
"name": "sourceToMdapi", | ||
"duration": 8834.219169000047 | ||
"duration": 8922.643469000002 | ||
}, | ||
{ | ||
"name": "sourceToZip", | ||
"duration": 7419.940933000005 | ||
"duration": 6673.310636000009 | ||
}, | ||
{ | ||
"name": "mdapiToSource", | ||
"duration": 5108.842208000016 | ||
"duration": 4866.022824999993 | ||
} | ||
] | ||
] |
10 changes: 5 additions & 5 deletions
10
...s/perfResults/x64-linux-2xIntel-Xeon-Platinum-8272CL-CPU-2-60GHz/lotsOfClassesOneDir.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
[ | ||
{ | ||
"name": "componentSetCreate", | ||
"duration": 780.378497000027 | ||
"duration": 774.8018560000346 | ||
}, | ||
{ | ||
"name": "sourceToMdapi", | ||
"duration": 12146.644433000009 | ||
"duration": 12633.609111000027 | ||
}, | ||
{ | ||
"name": "sourceToZip", | ||
"duration": 10558.852648 | ||
"duration": 10770.84330399998 | ||
}, | ||
{ | ||
"name": "mdapiToSource", | ||
"duration": 9052.254910999967 | ||
"duration": 8976.685232000018 | ||
} | ||
] | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters