Skip to content

Commit

Permalink
fix ConcurrentModificationException in CachingClusteredClient.run() (a…
Browse files Browse the repository at this point in the history
…pache#3278)

* fix ConcurrentModificationException in CachingClusteredClient.run()

* obtain new copy of PartitionHolder to avoid potential multi-threads read/write issue
  • Loading branch information
kaijianding authored and gianm committed Jul 29, 2016
1 parent 884017d commit 1fa6819
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ public Set<TimelineObjectHolder<VersionType, ObjectType>> findOvershadowed()
new TimelineObjectHolder<VersionType, ObjectType>(
object.getTrueInterval(),
object.getVersion(),
object.getPartitionHolder()
new PartitionHolder<ObjectType>(object.getPartitionHolder())
)
);
}
Expand Down Expand Up @@ -453,7 +453,7 @@ private List<TimelineObjectHolder<VersionType, ObjectType>> lookup(Interval inte
new TimelineObjectHolder<VersionType, ObjectType>(
timelineInterval,
val.getVersion(),
val.getPartitionHolder()
new PartitionHolder<ObjectType>(val.getPartitionHolder())
)
);
}
Expand Down

0 comments on commit 1fa6819

Please sign in to comment.