Re: Ignite crashes with CorruptedTreeException: "B+Tree is corrupted" on a composite BinaryObject scenario

2020-04-24 Thread Ilya Kasnacheev
Hello! I have added comment to this ticket describing why does it happen and how to fix it. In Ignite, when you get key from your value binary object, it's actually a wrapper pointing at some position in its parent (value) binary object. When you try to put it to cache, indexing cannot process

Re: Ignite crashes with CorruptedTreeException: "B+Tree is corrupted" on a composite BinaryObject scenario

2020-04-17 Thread akorensh
Maxim, I've an appropriate ticket: https://issues.apache.org/jira/browse/IGNITE-12911 Thanks, Alex -- Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Ignite crashes with CorruptedTreeException: "B+Tree is corrupted" on a composite BinaryObject scenario

2020-04-17 Thread max904
Thank you, Alex! Yes, I figured that this line indeed causes this crash. And yes, I'm using queries and I need this line. For now, I'm using the workaround I've described (of rebuilding the key BinaryObject). But it's quite expensive operation and I would like to avoid it. This looks like a bug to

Re: Ignite crashes with CorruptedTreeException: "B+Tree is corrupted" on a composite BinaryObject scenario

2020-04-17 Thread max904
Thank you, Alex! Yes, I figured that this line indeed causes this crash. And yes, I'm using queries and I need this line. For now, I'm using the workaround I've described (of rebuilding the key BinaryObject). But it's quite expensive operation and I would like to avoid it. This looks like a bug to

Re: Ignite crashes with CorruptedTreeException: "B+Tree is corrupted" on a composite BinaryObject scenario

2020-04-16 Thread akorensh
Hi, I was able to reproduce your use-case. This line causes the issues you describe: cacheConfig.setIndexedTypes(EmployeeId.class, Employee.class); Comment it out, and everything works. If you need Indexes, define them as need be, but remove these lines: employeeCache.put(key2,

Re: Ignite crashes with CorruptedTreeException: "B+Tree is corrupted" on a composite BinaryObject scenario

2020-04-15 Thread max904
Yes, of course I'm using "cache.withKeepBinary()". Below is my exact reproducer: final URL configUrl = getClass().getClassLoader().getResource("example-ignite.xml"); final Ignite ignite = Ignition.start(configUrl); final CacheConfiguration cacheConfig = new CacheConfiguration<>("Employee");

Re: Ignite crashes with CorruptedTreeException: "B+Tree is corrupted" on a composite BinaryObject scenario

2020-04-10 Thread akorensh
Hi, When running your code I created the cache as follows: IgniteCache employeeCache = ignite.getOrCreateCache("employeeCache").withKeepBinary(); With the ".WithKeepBinary()" flag set code works, otherwise there are serialization errors. If you still get errors w/this flag set,

Ignite crashes with CorruptedTreeException: "B+Tree is corrupted" on a composite BinaryObject scenario

2020-04-09 Thread max904
Ignite crashes when I use composite BinaryObject as a key and also include it into the value object. Here is the BinaryObject scenario: // create a new composite key BinaryObjectBuilder key1Builder = Ignition.ignite().binary().builder(EmployeeId.class.getName());