HomeMesosphereNo notifications. 4 unresolved issues.

wip: fixes history loading issue (option b)
AbandonedAll Users

Authored by timcharper on Mar 21 2017, 3:32 AM.

Details

Summary

Marathon 1.4.x experienced a regression in which history would not load for an app definition. This is a slightly more complex, that retains similar performance properties and races.

Fixes MARATHON-7133

Test Plan

...

Diff Detail

Repository
rMARATHON marathon
Branch
tharper/fix-history-issue-2
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 1832
Build 3473: Marathon (deprecated)Jenkins
Build 3472: arc lint + arc unit
timcharper updated this revision to Diff 2324.Mar 21 2017, 3:32 AM
timcharper created this revision.

le compiles

jenkins requested changes to this revision.Mar 21 2017, 3:36 AM
This revision now requires changes to proceed.Mar 21 2017, 3:36 AM
jenkins accepted this revision.Mar 21 2017, 4:05 AM

Thanks.

This revision is now accepted and ready to land.Mar 21 2017, 4:05 AM
aquamatthias requested changes to this revision.Mar 21 2017, 10:53 AM
aquamatthias added inline comments.
src/main/scala/mesosphere/marathon/core/storage/store/impl/cache/LazyCachingPersistenceStore.scala
218

Without introducing a VersionCacheStorageReference we could simplify this to:

if (versionCache.contains((category, unversionedId))) {
  val cached = versionCache.getOrElse((category, unversionedId), Set.empty) // linter:ignore UndesirableTypeInference
  versionCache.put((category, unversionedId), cached + version)
}

Both solutions have a race problem, since the TrieMap does not have an update operation based on the existing value.

This revision now requires changes to proceed.Mar 21 2017, 10:53 AM
timcharper abandoned this revision.Mar 21 2017, 3:44 PM