Sergey Kosarev created IGNITE-17043:
---------------------------------------

             Summary: Performance degradation in Marshaller
                 Key: IGNITE-17043
                 URL: https://issues.apache.org/jira/browse/IGNITE-17043
             Project: Ignite
          Issue Type: Bug
          Components: cache
    Affects Versions: 2.13, 2.14
            Reporter: Sergey Kosarev


There is a problem in ignite-core code in GridHandleTable used inside 
OptimizedMarshaller where the internal buffers grow in size and does not shrink 
back.
SingletonList is serialized with OptimizedMarshaller by default in Ignite. In 
contrast, for ArrayList serialization, BinaryMarshallerExImpl is used.
The difference between OptimizedMarshaller and BinaryMarshallerExImpl is that 
when OptimizedMarshaller starts to serialize an object node, all the descedant 
nodes continue to be serialized in OptimizedMarshaller using the same 
GridHandleTable associated with the current thread. GridHandleTable is static 
for a thread and never shrinks in size, its buffer becomes only larger in time.
BinaryMarshallerExImpl though, can divert serizliation to OptimizedMarshaller 
down the road.
What problematic is in GridHandleTable? This is its reset() method that fills 
arrays in memory. Done once, it's not a big deal. Done a million times for a 
long buffer, it becomes really long and CPU-consuming.





--
This message was sent by Atlassian Jira
(v8.20.7#820007)

Reply via email to