Skip to content

Releases: jamessimone/apex-rollup

Massive Flow Improvements

20 Aug 14:06
47ba302
Compare
Choose a tag to compare
  • bulkified full recalc code path with Invocables (REFRESH context), which involved some fun additional query parsing/formation - also allowed for further Flow efficiencies to be found
  • added a REFRESH action to the existing end-to-end Flow and a test for it in InvocableDrivenTests
  • fixed a bug in RollupCalculator where filtering on a non-filterable field (like Case.Description) would bomb out the query
  • removed some extraneous Rollup.defaultControl lines in test classes now that test classes aren't installed with the 2GP package
  • fixed an issue reported by Katherine West where in the odd event (still mostly not understood how) where a Rollup starts to run associated with a different set of records than the metadata it's associated with, the Rollup doesn't try to actually run given the mismatch
  • fixed bug in RollupRelationshipFieldFinder brought on by the research put into reconstituting where clauses with nested conditionals while bulkifying the Invocable full recalc code path

Thanks to @jongpie for the excellent code review on this one!

Annotation updates & Requeue bugfix

10 Aug 20:45
1a7e1e9
Compare
Choose a tag to compare
  • changing testVisible to TestVisible, and isTest to IsTest - (cc @gdoenlen)
  • moved toString def to Rollup base class
  • Moved all test classes to extra-tests/ directory
  • fixed requeue issue reported by Katherine West

Rollup Logger Enhancements

05 Aug 18:15
7d6fd42
Compare
Choose a tag to compare
  • Reworked rollup logger plugins to normalize the way that logging plugins are customized and interacted with. Added Rollup Logger Plugin and Rollup Logger Plugin Parameter Custom Metadata types to aid with this process. More information can be found in the Rollup Logging section of the README
    • Rollup now logs a variety of messages at different LoggingLevel permutations - FINEST, FINER, DEBUG, WARN, and ERROR are all valid LoggingLevel selections (can be customized with the Custom Object Rollup Logger unmanaged package, or while using the built in Apex Debugger and the newly provided RollupLoggerPluginParameter.LoggingDebugLevel CMDT record
  • Added sync override for invocables - you can now perform rollup calculations synchronously, if desired. Defaults to false, set to {!$GlobalConstant.True} to have calculations performed sync (and mind the README, again; if Defer Processing? is also set to true, will only run sync once the Processed Deferred Rollups action is called
  • fixed a bug reported by Katherine West where deferring rollups (typically when over the current query limit) could fail to requeue if they preferred to run as a Queueable but Limits.getLimitQueueableJobs() > Limits.getQueueableJobs()

Rollup Goes On a Diet

30 Jul 20:51
6be1152
Compare
Choose a tag to compare
  • Fixes #146 by going further down the rollup orchestrator/conductor path - the 'outer' rollup (previously referred to as the batchRollup - deprecating that term so that it's clear when a rollup is batched versus queued versus run sync) now 'conducts' the inner rollups by storing the calcItems and oldCalcItems map. This should drastically reduce memory consumption by basically eliminating how many List copies are being passed around in memory; whereas previously, the more CMDT/Rollup invocations you used, the more Lists were stored, now the outer rollup condenses that information into one place.
  • Avoids a possible string overflow exception when using the Custom Rollup Logger
  • Restores the packaging script to its former glory, including a more consistent update to the README when the package version is updated!

Rollup Logging Plugins Released!

22 Jul 21:15
ecd38f9
Compare
Choose a tag to compare
  • Fixes #68 by introducing two new rollup logging plugins 🎉 - one, an in-house custom lightweight logger to log rollup errors to, the second an adapter for rollup logging with @jongpie 's Nebula Logger - more information is available in the README, as well as in the READMEs for the individual logger plugins:
  • Added code coverage for new (optional) fields on RollupFlowBulkProcessor
  • fixes #141 by adding REFRESH context to invocables to allow flow to opt into the full recalculation code paths available in Apex/the full recalc button and app
  • fixes a bug reported by Karl Berlin where full recalcs for different parents could fail from the full recalc button

Additional Rollup Logging & CMDT Invocable updates

16 Jul 21:15
7784348
Compare
Choose a tag to compare
  • added additional rollup logging for deferred rollups
  • added additional fields to CMDT-based invocable to allow for Flow Builders to ovverride their CMDT for specific flows

Additional Full Recalc Work & CONCAT_DISTINCT bugfixes

07 Jul 19:48
333d988
Compare
Choose a tag to compare
  • fixes #132 (hopefully) by caching queries and avoiding undercounting when considering if/when to batch versus queue for full recalcs
  • separated RollupTests into RollupStandardIntegrationTests for tests actually querying for updated records / performing tons of DML
  • Fixed a restrictiveness issue for "always full recalc" operations (COUNT_DISTINCT, CONCAT_DISTINCT, FIRST, LAST, AVERAGE) where records that used to match but would be currently excluded by the calc item where clause sometimes didn't trigger a full recalculation of the parent record

Full Recalc Work, DLRS migration script enhancements

01 Jul 20:37
12b9752
Compare
Choose a tag to compare
  • Fixes #130 by removing bind issue in LWC
  • Fixes for the issues in #132 by (nearly completely) bulkifying the full recalc routes. This could still fall over if there were 50k+ children records for 2000 parents, but it should be good enough for now
  • Added proper null handling in RollupEvaluator
  • @jongpie added new script to deactivate converted DLRS rules to fix #134 🎉

Rollup Logger improvements, Full recalculation & invocable improvements

29 Jun 15:27
59ecc3d
Compare
Choose a tag to compare
  • Start of work on #68 - begin to flesh out Rollup Logger plugin, with beginning options for Nebula Logger and simple logging framework. For more information, see the "Rollup Logging" section of the README! More improvements will be coming on this front in v1.2.32
  • Fixes #125 by making the date/time/datetime comparisons as safe as possible
  • Fix CONCAT issue reported by Katherine West
  • Fixing RollupLogger instance lazy loading
  • Start of work to reproduce issues with multiple DML statements in the same transaction on objects with deferred Rollup actions called from Flow
  • Adding LWC coverage to deployment pipeline
  • Aligning flow engine, DLRS migration script, and LWC for Rollup Recalc App to use the same field labels/positions
  • Fix two straggler issues from invocable refactor - ensure grouped invocable rollups don't add the same item twice, and ensure count-based rollups properly set the recalculated value prior to returning it
  • Fixing issue with map key for CACHED_ROLLUPS + invocables. Bumped beta package version and beta links
  • Rollup class minimization (#128)
  • break apart mono-Rollup class
  • Improvements to recursion detection after adding recursive updates to Flow integration test in extra-tests/InvocableDrivenTests.cls. Because of the way that flow alternately boxcars/queues up different updates, it's doubly important here to make sure that the records are passing through in the right order to properly trigger detection on events like reparenting AND prevent recursive updates from running unless there's been a definitive change to the calc item/rollup operation in question
  • Properly calculate parent items with more than 2000 child records in RollupFullBatchRecalculator
  • Pinned to specific LWC jest version to avoid API version issue with VS Code test runner, added test coverage for LWC and added missing RollupLogger coverage

Summer 21, Parent Recalc Button bugfix, various improvements

18 Jun 22:33
e9aef85
Compare
Choose a tag to compare
  • Bump API versions to v52 for Summer21

  • Fixes #123 by moving to strongly-typed equality checks for greater than / less than in RollupEvaluator

  • Fixes #122 by properly filtering parent recalc button

  • Fixing Datetime -> Date conversion issue reported by Katherine West

  • Fixes #121 by properly decrementing count-based rollups when old calc item matches and updated version does not

  • Fix getBareOperationName in Rollup/consolidate with RollupCalculator

  • Further work on #121 - working fix for UPDATE_COUNT, but further consideration needed for the following operations: UPDATE_COUNT_DISTINCT, UPDATE_SUM, UPDATE_CONCAT, UPDATE_CONCAT_DISTINCT, UPDATE_MIN, UPDATE_MAX. UPDATE_AVERAGE, UPDATE_FIRST, and UPDATE_LAST should already be good (this will be a pending item to address in the next release(s)