Igniters (especially Sergi),
What happens if I use Java primitives like Doubles as values? Are they indexed? I just created a simple example which loads some data and executes this query: 'select max(_val) from Double'. Indexes are not created and the speed of the query is the same as the speed of full cache iteration. I can't find any configuration properties to tweak this behavior. Also I see this in GridQueryProcessor.processAnnotationsInClass() method: if (U.isJdk(cls)) return; So it looks like all JDK classes are simply ignored. Is this on purpose? I think primitives should be indexed by default if they are provided in CacheConfiguration.setIndexedTypes(). -- Val |
Current workaround is to create separate class with single annotated
primitive field. Created issue https://issues.apache.org/jira/browse/IGNITE-930 Will fix it soon. Sergi 2015-05-21 4:25 GMT+03:00 Valentin Kulichenko <[hidden email] >: > Igniters (especially Sergi), > > What happens if I use Java primitives like Doubles as values? Are they > indexed? I just created a simple example which loads some data and executes > this query: 'select max(_val) from Double'. Indexes are not created and the > speed of the query is the same as the speed of full cache iteration. > > I can't find any configuration properties to tweak this behavior. Also I > see this in GridQueryProcessor.processAnnotationsInClass() method: > > if (U.isJdk(cls)) > return; > > So it looks like all JDK classes are simply ignored. Is this on purpose? > > I think primitives should be indexed by default if they are provided in > CacheConfiguration.setIndexedTypes(). > > -- > Val > |
On Wed, May 20, 2015 at 11:47 PM, Sergi Vladykin <[hidden email]>
wrote: > Current workaround is to create separate class with single annotated > primitive field. > > Created issue https://issues.apache.org/jira/browse/IGNITE-930 > Will fix it soon. > Thanks Sergi! I also agree that this should be fixed. Many performance tests are done with primitive keys and values, and last thing we want is to have poor performance due to counter-intuitive configuration. I this can be done quickly enough, I would even include this fix into 1.1 and resubmit the vote. D. > > Sergi > > 2015-05-21 4:25 GMT+03:00 Valentin Kulichenko < > [hidden email] > >: > > > Igniters (especially Sergi), > > > > What happens if I use Java primitives like Doubles as values? Are they > > indexed? I just created a simple example which loads some data and > executes > > this query: 'select max(_val) from Double'. Indexes are not created and > the > > speed of the query is the same as the speed of full cache iteration. > > > > I can't find any configuration properties to tweak this behavior. Also I > > see this in GridQueryProcessor.processAnnotationsInClass() method: > > > > if (U.isJdk(cls)) > > return; > > > > So it looks like all JDK classes are simply ignored. Is this on purpose? > > > > I think primitives should be indexed by default if they are provided in > > CacheConfiguration.setIndexedTypes(). > > > > -- > > Val > > > |
Free forum by Nabble | Edit this page |