spring-statemachine icon indicating copy to clipboard operation
spring-statemachine copied to clipboard

Override Java 1.8 default Map methods in ObservableMap

Open rand0m86 opened this issue 3 years ago • 1 comments

This is to ensure that default map methods will be passed to the delegate, which is in this case an instance of ConcurrentHashMap.

Without this change, an attempt to modify state variables via default methods will be delegated to default Map implementation, which is not thread safe. These methods are already overridden in ConcurrentHashMap.

rand0m86 avatar Nov 21 '22 19:11 rand0m86

@jvalkeal please review.

rand0m86 avatar Nov 21 '22 19:11 rand0m86