[Unicode]   Common Locale Data Repository : Bug Tracking Home | Site Map | Search
 
Modify

CLDR Ticket #7521(accepted tools)

Opened 3 years ago

Last modified 2 years ago

CME in SimpleTestCache

Reported by: srl Owned by: anybody
Component: unknown Data Locale:
Phase: dsub Review:
Weeks: Data Xpath:
Xref:

ticket:7519

Description (last modified by srl) (diff)

SimpleTestCache is now using a Guava class "Cache<>".

*** MESSAGE java.util.ConcurrentModificationException null
*** STACK java.util.LinkedHashMap$LinkedHashIterator.nextEntry(LinkedHashMap.java:394)
java.util.LinkedHashMap$KeyIterator.next(LinkedHashMap.java:405)
org.unicode.cldr.test.SimpleTestCache.valueChanged(SimpleTestCache.java:51)
org.unicode.cldr.test.SimpleTestCache.valueChanged(SimpleTestCache.java:48)
org.unicode.cldr.test.SimpleTestCache.valueChanged(SimpleTestCache.java:42)
org.unicode.cldr.util.XMLSource.notifyListeners(XMLSource.java:1554)
org.unicode.cldr.web.STFactory$DataBackedSource.setValueFromResolver(STFactory.java:250)
org.unicode.cldr.web.STFactory$PerLocaleData.internalSetVoteForValue(STFactory.java:1195)
org.unicode.cldr.web.STFactory$PerLocaleData.voteForValue(STFactory.java:1176)
org.unicode.cldr.web.STFactory$PerLocaleData.voteForValue(STFactory.java:368)
org.unicode.cldr.web.SurveyAjax.processRequest(SurveyAjax.java:672)
org.unicode.cldr.web.SurveyAjax.doPost(SurveyAjax.java:280)

Attachments

Change History

comment:1 Changed 3 years ago by srl

  • Xref set to 7519

Recycling this ticket..

Last edited 3 years ago by srl (previous) (diff)

comment:2 Changed 3 years ago by srl

  • Description modified (diff)
  • Summary changed from DataSectoin - JSON error checking to CME in SimpleTestCache

comment:3 Changed 3 years ago by ribnitz

I rewrote SimpleTestCache to use a Cache (the behaviour of which is comparable to that of a ConcurrentMap); I also committed the change to not pass References to the cache (to avoid chaining references). According to the Guava doc, the behaviour of the cache is that iteration is weakly consistent:

http://docs.guava-libraries.googlecode.com/git/javadoc/com/google/common/cache/Cache.html#asMap()

Iterators from the returned map are at least weakly consistent: they are safe for concurrent use, but if the cache is modified (including by eviction) after the iterator is created, it is undefined which of the changes (if any) will be reflected in that iterator.

If the problem is still present, the safe option is to use synchronization in the few cases iteration/eviction is done.

comment:4 Changed 3 years ago by emmons

  • Status changed from new to assigned
  • Component changed from unknown to tools
  • Priority changed from assess to medium
  • Milestone changed from UNSCH to 26rc
  • Owner changed from anybody to ribnitz
  • Type changed from unknown to enhancement

comment:5 Changed 3 years ago by mark

  • Owner changed from ribnitz to googler

comment:6 Changed 3 years ago by mark

  • Owner changed from googler to anybody
  • Milestone changed from 26rc to 27dsub

comment:7 Changed 3 years ago by markus

  • Phase set to dsub
  • Milestone changed from 27dsub to 27

comment:8 Changed 2 years ago by emmons

  • Milestone changed from 27 to UNSCH

Moving all 27+anybody tickets to UNSCH.

comment:9 Changed 2 years ago by markus

  • Type changed from enhancement to tools
  • Component changed from tools to unknown

comment:10 Changed 2 years ago by srl

  • Status changed from assigned to accepted
View

Add a comment

Modify Ticket

Action
as accepted
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.