[MAGNOLIA-6877] YamlDefinitionProvider#getLastModified() emits mis-leading redundant and noisy log statements Created: 17/Nov/16  Updated: 05/Dec/16  Resolved: 18/Nov/16

Status: Closed
Project: Magnolia
Component/s: None
Affects Version/s: 5.4.9, 5.5
Fix Version/s: 5.4.10, 5.5.1

Type: Bug Priority: Neutral
Reporter: Aleksandr Pchelintcev Assignee: Aleksandr Pchelintcev
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Sprint: Basel 71
Story Points: 1

 Description   

The following logic is executed within a loop that calculates the max last modified date of a resource and all of its dependencies:

if (dependency.getLastModified() > lastModified) {
  log.info("Definition at [{}] will be re-resolved since its dependency at [{}] has changed", dependencyPath, resourcePath);
}

Since this ^ comparison happens before the actual max value is calculated - the whole log statement is incorrect. Also in this particular method we shouldn't make comments about how to interpret the last modified date at all!


Generated at Mon Feb 12 04:18:41 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.