Uploaded image for project: 'Policy Framework'
  1. Policy Framework
  2. POLICY-1380

Apex throws an exception when flushing context

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Medium Medium
    • Casablanca Release
    • Casablanca Release
    • None

      Apex throws an exception when flushing context.

      Context flushing is not implemented in Apex as yet and this exception is ignored in running systems. However, the code should be fixed to stop the exception being generated.

      Two occurrances have been observed, A concurrent access exception:
      Exception in thread "DistributorFlushTimerTask" java.util.ConcurrentModificationException
      at java.util.HashMap$HashIterator.nextNode(HashMap.java:1442)
      at java.util.HashMap$EntryIterator.next(HashMap.java:1476)
      at java.util.HashMap$EntryIterator.next(HashMap.java:1474)
      at org.apache.avro.generic.GenericData.toString(GenericData.java:558)
      at org.apache.avro.generic.GenericData.toString(GenericData.java:525)
      at org.apache.avro.generic.GenericData.toString(GenericData.java:504)
      at org.apache.avro.generic.GenericData$Record.toString(GenericData.java:228)
      at com.ericsson.apex.context.impl.distribution.AbstractDistributor.flush(AbstractDistributor.java:202)
      at com.ericsson.apex.context.impl.distribution.DistributorFlushTimerTask.run(DistributorFlushTimerTask.java:73)
      at java.util.TimerThread.mainLoop(Timer.java:555)
      at java.util.TimerThread.run(Timer.java:505)

      And a class cast exception:
      Exception in thread "DistributorFlushTimerTask" java.lang.ClassCastException: java.util.UUID cannot be cast to org.onap.policy.apex.model.contextmodel.concepts.AxContextSchema

      at org.onap.policy.apex.context.impl.distribution.AbstractDistributor.flush(AbstractDistributor.java:250)

      at org.onap.policy.apex.context.impl.distribution.DistributorFlushTimerTask.run(DistributorFlushTimerTask.java:86)

      at java.util.TimerThread.mainLoop(Timer.java:555)

      at java.util.TimerThread.run(Timer.java:505)

            liamfallon liamfallon
            liamfallon liamfallon
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: