summaryrefslogtreecommitdiffstats
path: root/integration-test/src/test
AgeCommit message (Collapse)AuthorFilesLines
2024-01-05Merge "Normalize JSON attributes during update"Toine Siebelink1-5/+5
2024-01-04Add performance tests for saveListElementsdanielhanrahan1-14/+75
Add performance tests for CpsDataService methods: - saveListElements - saveListElementsBatch Results show that saveListElementsBatch (used only by NCMP for saving CM-handles) has extremely poor performance compared to saveListElements, which is over 4x faster and uses less memory. Issue-ID: CPS-2019 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I89d634c69b3790f1e1a79e2ff5392db5a45c761b
2024-01-04Normalize JSON attributes during updatedanielhanrahan1-5/+5
This change fixes a few issues related to JSON encoding of FragmentEntity attributes (data leaves). This significantly improves update performance in cases of partial updates. - Normalize JSON and order leaves by name when comparing data leaves during update operations. - Update performance test timings. Issue-ID: CPS-2018 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: Ia764a353bf96c05758827845e1358745247ee237
2023-12-22CpsDataService Update performance testsdanielhanrahan1-42/+106
Test suite for CpsDataService update methods: - updateDataLeaves - updateDataNodeAndDescendants - replaceListContent Added JVM warmup for update tests Issue-ID: CPS-1674 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: Ia07d792bef63fbe2d376a16c210d9d0c4425e302
2023-12-22Fix performance tests after anchor/dataspace splitdanielhanrahan1-2/+2
CpsAdminService was split into CpsDataspaceService and CpsAnchorService. One test has incorrect changes. Issue-ID: CPS-871 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I8013c4d9d17a5846d183e1c06bc11fa5ef9b4c4d
2023-12-18Remove the dependency-cycle between beansToineSiebelink12-105/+159
- Splitting admin service into AnchorService and DataspaceService (this resolves the cyclic dependency) - Improved Delete dataspace integration error tests (were depending on execution order, now independent) Issue-ID: CPS-871 Change-Id: I47efedb6eb4bd2900f72d689616b7b7b62df2938 Signed-off-by: halil.cakal <halil.cakal@est.tech> Signed-off-by: ToineSiebelink <toine.siebelink@est.tech>
2023-12-18Merge "Remove Notification code for updated events"Toine Siebelink1-6/+0
2023-12-18Remove Notification code for updated eventsmpriyank1-6/+0
- removed existing code for sending notifications to topic cps.dataupdated events formerly used by cps-temporal - corresponding testware removed or updated - unnecessary to fetch anchor details for delete and replace operation removed which might gain minor performance boost - yaml configurations , documentation removal and update - Added missing test for AsyncConfig to comply with coverage check Issue-ID: CPS-2005 Change-Id: I1848f7f229cb713fe8c0302ea50328e7451652ee Signed-off-by: mpriyank <priyank.maheshwari@est.tech>
2023-12-18Merge "Update Model to allow Persisting of alternateId"Toine Siebelink2-2/+19
2023-12-14Update Model to allow Persisting of alternateIdleventecsanyi2-2/+19
- added new dmi model registry and modified tests Issue-ID: CPS-1989 Signed-off-by: leventecsanyi <levente.csanyi@est.tech> Change-Id: I576a5a0704fe28924dcc304c276fec5665b52764
2023-12-13Introduce Schema Set upgrade methodsourabh_sourabh1-3/+63
- Incl. integration test - Prod code is changed to use new method that update yand module. - updated module resource to return multiple modules. Issue-ID: CPS-1806 Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech> Change-Id: I751d9393ce78a3be9daeaff6d0252738c02115e0 Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
2023-12-11Uplift Guava dependencyhalil.cakal1-2/+3
- upgrade Guava to the latest version to fix critial vulnerability Issue-ID: CPS-1987 Change-Id: I6ea314407133dea229e9626fdf2d9c938f7c7e08 Signed-off-by: halil.cakal <halil.cakal@est.tech>
2023-11-22Make performance tests measure PEAK memory usagedanielhanrahan2-5/+115
Presently, performance tests measure CURRENT memory usage instead of PEAK memory usage, leading to under-reporting if garbage collector runs during a test. This patch fixes it, so that memory reported will now be at least the memory of live objects at that time. - Add tests for ResourceMeter class - ResourceMeter measures peak memory usage instead of current Issue-ID: CPS-1967 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I36e9ea2196420b84877ecabc1b7331c5d3e2e252
2023-11-14CPS Delta API 1: Delta between 2 anchorsArpit Singh4-0/+317
- CPS Delta Feature Part 1: To find delta between two anchors - created new endpoint deltaByDataspaceAndAnchors - endpoint to take dataspaceName, source anchor, target anchor, xpath, descendants as input - added new service CpsDeltaService - added method to find delta between DataNodes: getDeltaReport - added method to find removed data nodes: getRemovedDeltaReports - added method to get Added DataNodes: getAddedDeltaReports - added method to get Map of xpath to DataNode: convertToXPathToDataNodesMap - added a POJO for delta report - Added new JSON data for delta feature testing - Added groovy test files CpsDeltaServiceImplSpec and DeltaReportBuilderSpec - code related to update operation, will be added in separate commit Issue-ID: CPS-1824 Signed-off-by: Arpit Singh <as00745003@techmahindra.com> Change-Id: I313f0f71d04b03878be7643f709d8af1aa6df6ba
2023-11-13Adjust performance test timingsdanielhanrahan11-71/+64
New limits for time and memory are based on analyzing 40 previous performance job runs. Test limits are chosen so that individual test cases would pass 95% of the the time. Issue-ID: CPS-1884 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: Iadca27eb1f9482016759070e5afdc70c53f9d043
2023-11-08Use Seconds as time unit for all performance testsseanbeirne12-125/+116
-updated recordAndAssertResourceUsage Issue-ID: CPS-1941 Signed-off-by: seanbeirne <sean.beirne@est.tech> Change-Id: I62f42c7ab396e555d54a7280ebc7da8804045667
2023-10-17Merge "Add memory usage to integration tests [UPDATED]"Toine Siebelink12-201/+273
2023-10-11Expose REST endpoint to update YANG schema set using moduleSetTagsourabh_sourabh2-2/+2
- Added new schema to upgrade model into component. - Modified Ncmp rest input mapper to add upgradedCmHandles attributes. - Modified cm handle state mapper to add new lock reason. - Added new method to parse and upgrade Cm handles in DmiRegistration. - YANG data converter is modified to add "module-set-tag" atribute. - Cm handle new query method is added for cps path without appending ancestor. - Modified setCompositeStateForRetry to add lock reason. - New lock reason category is added. - Existing module sync service is modified to upgrade the model "syncAndCreateOrUpgradeSchemaSetAndAnchor". - Sync util method "getModuleSyncFailedCmHandles" to modified to add another lock reason "LOCKED_MISBEHAVING". - Added new attribute "UpgradedCmHandles" into DmiPluginRegistration and DmiPluginRegistrationResponse. - New attribute "moduleSetTag" is added into NcmpServiceCmHandle. - New model "UpgradedCmHandles" is added. - New method "updateSchemaSetWithExistingModules" is added into cps module service to update cm handle with exsting model. - Code coverage is reducced to 96 percentage that would be addressed and pushed into new patch. Issue-ID: CPS-1798 Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech> Change-Id: I540acb404e38fc434de87a0d959bfde710a18b03 Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
2023-10-11Add memory usage to integration tests [UPDATED]emaclee12-201/+273
Issue-ID: CPS-1753 Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech> Change-Id: I08fd0802f536b8fe333ddbfc9301356095f58171
2023-09-27Uplift Spring Boot to 3.1.2egernug1-1/+1
To align with Ericsson Spring Boot is being uplifted to version 3.1.2 Issue-ID: CPS-1888 Signed-off-by: egernug <gerard.nugent@est.tech> Change-Id: Icfe97df15ab67a7fb25e0a98e4bbbbe91f332321
2023-09-26Merge "CM Data Subscriptions PoC/Performance test fixes"Toine Siebelink1-28/+44
2023-09-26CM Data Subscriptions PoC/Performance test fixesdanielhanrahan1-28/+44
There were some issues in original update test that caused no updates to be written. This fixes those issues and adds verifies the subscriber count. Issue-ID: CPS-1881 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I7b5a5e95bee247d1b1d52f5bc5e8567b8871a659
2023-09-26Rename Subscrption Perf Test class to fit filenameToineSiebelink1-1/+1
Issue-ID: CPS-1881 Signed-off-by: ToineSiebelink <toine.siebelink@est.tech> Change-Id: I6b18d13fd8f1f877eb21fee783bc3fc8515a575c
2023-09-25CM Data Subscriptions PoC/Performance testToineSiebelink7-57/+281
- New model introduced in test can be ported to production code - Groovy test around the new use-cases can be used as a guid for actau production code solution - Current worst use-case about 10 secodn son windows laptop. is acceptable as per Requiremenyt of 30 second - TODO: update test limits/expectations based on CI results Issue-ID: CPS-1881 Signed-off-by: ToineSiebelink <toine.siebelink@est.tech> Change-Id: I05f3adf7f9cc4d9a9c94a8435a392ed76f9fad66
2023-08-22Merge "Missing test for getDataNodes (ep1)"Luke Gleeson1-0/+14
2023-08-18Missing test for getDataNodes (ep1)Arpit Singh1-0/+14
- there was no test to check the exceptions thrown by getDataNodes Signed-off-by: Arpit Singh <as00745003@techmahindra.com> Change-Id: Ifa1df8ebe83fafba833be14559d94261bca93ef0
2023-08-18CPS-Core : Expose a java interface to update schema setsourabh_sourabh6-5/+107
- Exposed an interface to update anchor by schema set name. - New interface is implemented into RI model. - New native query is exposed to update id with given schema set name. - A new integration test is written to test new interface into cps core. Issue-ID: CPS-1800 Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech> Change-Id: Ibf44712e11b53cb6673b04b9e3fd864321c90839 Signed-off-by: sourabh_sourabh <sourabh.sourabh@est.tech>
2023-08-17Update of top-level data node fails with SQL errordanielhanrahan1-0/+11
The error is caused by the fetch-descendants code using ResultSet.getLong which returns a 'long' primitive instead of a 'Long' object. Thus a parent ID of 'NULL' becomes '0', which causes an error during update. To preserve the NULL value, ResultSet.getObject must be used. Issue-ID: CPS-1841 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: Ida6837a04954cd3c23f0f2faabd7d0712d8ee19d
2023-08-15Update performance test timing for warmupdanielhanrahan2-2/+2
Incorrect limit on the warmup results in performance pipeline failing, as the first test that runs must include the time taken to write initial data. Issue-ID: CPS-1811 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I82353fcd5d0904f458808b32f4f01597ba25a688
2023-08-04Update performance test timings for larger datasetdanielhanrahan9-159/+159
- Populate 3 anchors with 1000 openroadm devices nodes for read and query tests (over 250,000 fragments) - Increase update perf tests to update 100 out of 1000 devices - Increase delete perf tests to delete 100 out of 300 devices - Remove bookstore data from performance tests - Update test timings Issue-ID: CPS-1811 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: Iaa36694be907278e772ae729a85510ea9d004fd1
2023-08-03Fix: integration test that is for add and delete top level list elementhalil.cakal1-1/+1
Issue-ID: CPS-1605 Change-Id: Ia6ba73d5e4930bcc547cf24d06c50c681c3a7452 Signed-off-by: halil.cakal <halil.cakal@est.tech>
2023-08-03Merge "Support pagination in query across all anchors(ep4)"Luke Gleeson4-24/+70
2023-08-02Support pagination in query across all anchors(ep4)rajesh.kumar4-24/+70
Add pagination query parameters in query across all anchors API pagination parameters (pageIndex and pageSize) are optional default is to query all fragments each pageSize represents number of records(number of anchors) TotalRecords is returned in response header to find number of pages. - If pagination option is provided in request then query number of anchors equal to pageSize. pageIndex is used for setting offset. - return number of records(one anchor per record) as per pagesize and pageSize Issue-ID: CPS-1605 Change-ID: I73f97f986a817d423f93a8d922dcd9647b2504bc Signed-off-by: rajesh.kumar <rk00747546@techmahindra.com>
2023-08-01Merge "Fix: Make bookstore data consistent"Toine Siebelink3-27/+17
2023-07-31Add 'direct' keyword to descendants option to query direct children (ep1)Rudrangi Anupriya5-29/+27
-added 'direct' keyword also to Fetch Descendants Option along with 'all' and 'none' to Query direct child. -added unit tests to test direct keyword Issue-ID: CPS-1784 Change-Id: Icb7f59fbeebb03703626132d6d5d2cfde0e5ab4d Signed-off-by: Rudrangi Anupriya <ra00745022@techmahindra.com>
2023-07-28Use constants for magic numbers in perf testsdanielhanrahan3-30/+30
Issue-ID: CPS-1811 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: Ic87bcb1847b97a0e8c59b2e3636e9ccd66f814ae
2023-07-28Add 'direct' keyword to descendants option to query direct children (ep1)Rudrangi Anupriya5-29/+32
-added 'direct' keyword also to Fetch Descendants Option along with 'all' and 'none' to Query direct child. -added unit tests to test direct keyword Issue-ID:CPS-1784 Change-Id: Iab7f59fbeebb03703626132c6d5c2afde0e5ab4d Signed-off-by: Rudrangi Anupriya <ra00745022@techmahindra.com>
2023-07-27Merge "Improve 32K limit tests"Toine Siebelink1-20/+56
2023-07-27Merge "Add write performance tests"Toine Siebelink1-0/+83
2023-07-27Improve 32K limit testsdanielhanrahan1-20/+56
Some operations were previously limited to 32,768 parameters, such as getDataNodesForMultipleXpaths. After this limit was lifted, the tests only verified that database exceptions were not thrown. This commit improves the tests by verifying that the operations return or delete the expected data. - Create 33,000 data nodes - Verify that getDataNodesForMultipleXpaths returns 33,000 nodes - Verify than deleteDataNodes deletes 33,000 nodes Issue-ID: CPS-1811 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I7029ea0cf1d4e95c5ca814ca62c222fc5b9ddc7e
2023-07-27Merge "Allow getDataNodes to read whole lists(ep 1)"Sourabh Sourabh2-21/+48
2023-07-27Allow getDataNodes to read whole lists(ep 1)danielhanrahan2-21/+48
- getDataNodes can now retrieve list data nodes. Issue-ID: CPS-1696 Signed-off-by: arpitsingh <as00745003@techmahindra.com> Change-Id: I320a368d6cb73599d3f7c13fe9b8ab7d0cc69470
2023-07-27Merge "Performance test of reading non-existing datanodes"Toine Siebelink2-3/+19
2023-07-27Fix: Make bookstore data consistentArpit Singh3-27/+17
- Removed list named invoice from all bookstore files - Added a new parent list as bookstore-address - Refactored tests Issue-ID: CPS-1813 Signed-off-by: Arpit Singh <as00745003@techmahindra.com> Change-Id: I5c7e83e1ee0ad9ac1d94d1906c2361c7a00d49af
2023-07-27Add write performance testsdanielhanrahan1-0/+83
- Add perf test for openroadm (linear time) - Add perf test for bookstore (exponential time!) Issue-ID: CPS-1811 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I9c1772a9e9684707f2dbb32b2c361ec248fb1c60
2023-07-26Performance test of reading non-existing datanodesdanielhanrahan2-3/+19
Issue-ID: CPS-1811 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I183129bb5b0a2d620b87e9b36f3113fe8e169798
2023-07-26Performance test of deleting non-existing datanodesdanielhanrahan1-2/+18
Issue-ID: CPS-1811 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: Ifae635f45d8ec1990452ade958253972fde68415
2023-07-26Some performance tests are skipped due to filenamedanielhanrahan2-2/+2
CPS POM is setup so that only files ending in 'Spec' or 'Test' are run as tests, and files ending in 'PerfTest' will only run in the 'include-performance' profile. The 32K limit tests are currently being skipped always, as they do not end in 'Spec', 'Test', or 'PerfTest'. This commit renames them to PerfTest. Issue-ID: CPS-1811 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: I75a4ae92edf324213f734503c23dedb2b31fd007
2023-07-20Merge "Apostrophe handling in CpsPathParser"Toine Siebelink1-0/+19
2023-07-20Merge "Persisting a list element to a parent list (ep2)"Luke Gleeson3-2/+59