reef-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mariia Mykhailova (JIRA)" <>
Subject [jira] [Created] (REEF-1079) Put a lock in ProtocolBufferClassHierarchy.SerializeNode
Date Tue, 15 Dec 2015 00:53:46 GMT
Mariia Mykhailova created REEF-1079:

             Summary: Put a lock in ProtocolBufferClassHierarchy.SerializeNode
                 Key: REEF-1079
             Project: REEF
          Issue Type: Bug
            Reporter: Mariia Mykhailova
            Assignee: Mariia Mykhailova

The method iterates over all children of a node, serializing them one by one.

foreach (INode child in n.GetChildren())

If the list of children is changed in a different thread, this code will throw {{System.InvalidOperationException
: Collection was modified after the enumerator was instantiated.}}. We observe this in {{TestNamedParameterWithAliasRoundTrip}}
test which passes when executed individually but fails when executed in parallel with other
tests. Adding a lock around this loop solves the issue.

This message was sent by Atlassian JIRA

View raw message