Uploaded image for project: 'Spring Data REST'
  1. Spring Data REST
  2. DATAREST-1262

PersistentEntitiesResourceMappings throws ConcurrentModificationException

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      PersistentEntitiesResourceMappings uses HashMap and so I get this error:

      2018-07-14 15:11:52,504 org.apache.catalina.core.ContainerBase.[Tomcat].[localhost].[/storefront].[dispatcherServlet] [https-jsse-nio-127.0.0.1-8112-exec-7] ERROR: Servlet.service() for servlet [dispatcherServlet] in context with path [/storefront] threw exception [Request processing failed; nested exception is java.util.ConcurrentModificationException] with root cause
      java.util.ConcurrentModificationException
      	at java.util.HashMap$HashIterator.nextNode(HashMap.java:1442)
      	at java.util.HashMap$ValueIterator.next(HashMap.java:1471)
      	at org.springframework.data.rest.core.mapping.PersistentEntitiesResourceMappings.iterator(PersistentEntitiesResourceMappings.java:197)
      	at org.springframework.data.rest.core.mapping.PersistentEntitiesResourceMappings.exportsTopLevelResourceFor(PersistentEntitiesResourceMappings.java:140)
      	at org.springframework.data.rest.webmvc.RepositoryRestHandlerMapping.lookupHandlerMethod(RepositoryRestHandlerMapping.java:154)
      

      Please make it use ConcurrentHashMap.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              olivergierke Oliver Drotbohm
              Reporter:
              ptahchiev Petar Tahchiev
              Last updater:
              Oliver Drotbohm
              Votes:
              3 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: