Missing shadows after upgrading from 3.7.0 to 3.7.5 (and 3.8.5)
See original GitHub issueWe are using Javers to historize our domain objects and it is doing a great job! However, after upgrading from 3.7.0 to 3.7.5 and above the following junit tests in our spring boot project fail (the branch is configured to use javers 3.8.5 at the moment): Missing Study Shadows Missing Survey Shadows
Both tests use the following piece of code to load the shadows with limit=5 and skip=0 (from GenericDomainObjectVersionsService.java)
public List<T> findPreviousVersions(String id, int limit, int skip) {
T domainObject = repository.findOne(id);
if (domainObject == null) {
return null;
}
QueryBuilder jqlQuery = QueryBuilder.byInstance(domainObject)
.withScopeDeepPlus(Integer.MAX_VALUE).limit(limit).skip(skip);
List<Shadow<T>> previousVersions = javers.findShadows(jqlQuery.build());
return previousVersions.stream().map(shadow -> {
T domainObjectVersion = shadow.get();
if (domainObjectVersion.getId() == null) {
// deleted shadow
domainObjectVersion.setLastModifiedBy(shadow.getCommitMetadata().getAuthor());
domainObjectVersion.setLastModifiedDate(shadow.getCommitMetadata().getCommitDate());
}
return domainObjectVersion;
}).collect(Collectors.toList());
}
Both tests expect to get 3 shadows (1 initial commit + 2 updates) but do get only 2 shadows.
Please let me know if this is an intended change introduced with 3.7.5 or if this is an unintended side effect from the performance improvements introduced with 3.7.5
Issue Analytics
- State:
- Created 5 years ago
- Comments:12 (7 by maintainers)
Top Results From Across the Web
All modules aren't available after upgrading to Python 3.8.5
I just upgraded the Python version from 3.8.4 to 3.8.5 And I ... ModuleNotFoundError: No module named 'module name' ... And when I...
Read more >When should you upgrade to Python 3.11?
1. Missing binary packages. To begin with, not all packages can be installed on 3.11 yet. · 2. Incompatible packages. Sometimes supporting a...
Read more >Release History Of SQLite
Release History. This page provides a high-level summary of changes to SQLite. For more detail, see the Fossil checkin logs at ...
Read more >What's New In Python 3.7 — Python 3.11.1 documentation
When filesystem timestamps are too coarse, Python can miss source updates, leading to ... The new loop.start_tls() method can be used to upgrade...
Read more >Python support policy updates for AWS SDKs and Tools
After this point, you can expect the oldest supported Python version ... No actions are required until you decide to upgrade to Python...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

@rreitmann seems correct but could be slow. I would be better to have correct & fast paging for Shadows in JaVers itself. Let me check it. I’ll be back to you.
Ok, I did not know that. Thx, for letting me know.