[ 
https://issues.apache.org/jira/browse/IGNITE-7219?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Dmitry Konstantinov updated IGNITE-7219:
----------------------------------------
    Description: 
As a part of store logic of CassandraCacheStore if strategy="POJO" is used to 
store a value entity - 
org.apache.ignite.cache.store.cassandra.persistence.PojoFieldAccessor is used 
to work with POJO properties. Within the methods getValue/setValue 
getReadMethod()/getWriteMethod() are invoked each time. As a part of the 
methods invocation sun.reflect.misc.ReflectUtil#isNonPublicProxyClass is 
triggered which works with class names as strings and allocates a memory. It is 
a small allocation by itself but it is triggered very frequently - for each 
field for each entity per each DB operation - so in summary it create a 
significant pressure. See attach:  [^ignitePojoFieldAccessorMemAlloc.png]

Suggestion: we can cache and reuse getReadMethod()/getWriteMethod() results as 
a part of constructor logic of PojoFieldAccessor

  was:
As a part of store logic of CassandraCacheStore if strategy="POJO" is used to 
store a value entity - 
org.apache.ignite.cache.store.cassandra.persistence.PojoFieldAccessor is used 
to work with POJO properties. Within the methods getValue/setValue 
getReadMethod()/getWriteMethod() are invoked each time. As a part of the 
methods invocation sun.reflect.misc.ReflectUtil#isNonPublicProxyClass is 
triggered which works with class names as strings and allocates a memory. It is 
a small allocation by itself but it is triggered very frequently - for each 
field for each entity per each DB operation - so in summary it create a 
significant pressure. See attach:  

Suggestion: we can cache and reuse getReadMethod()/getWriteMethod() results as 
a part of constructor logic of PojoFieldAccessor


> Reduce memory allocation in cassandra.persistence.PojoFieldAccessor
> -------------------------------------------------------------------
>
>                 Key: IGNITE-7219
>                 URL: https://issues.apache.org/jira/browse/IGNITE-7219
>             Project: Ignite
>          Issue Type: Improvement
>          Components: cassandra
>    Affects Versions: 2.1, 2.2, 2.3
>            Reporter: Dmitry Konstantinov
>         Attachments: ignitePojoFieldAccessorMemAlloc.png
>
>
> As a part of store logic of CassandraCacheStore if strategy="POJO" is used to 
> store a value entity - 
> org.apache.ignite.cache.store.cassandra.persistence.PojoFieldAccessor is used 
> to work with POJO properties. Within the methods getValue/setValue 
> getReadMethod()/getWriteMethod() are invoked each time. As a part of the 
> methods invocation sun.reflect.misc.ReflectUtil#isNonPublicProxyClass is 
> triggered which works with class names as strings and allocates a memory. It 
> is a small allocation by itself but it is triggered very frequently - for 
> each field for each entity per each DB operation - so in summary it create a 
> significant pressure. See attach:  [^ignitePojoFieldAccessorMemAlloc.png]
> Suggestion: we can cache and reuse getReadMethod()/getWriteMethod() results 
> as a part of constructor logic of PojoFieldAccessor



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to