Hi, Is the question somehow related to your previous quiestion, entitled Error while loading data into cache with BinaryObject as key field ?
I see the same eexception here. How do you fill the cache with data ? 2016-07-01 11:39 GMT+03:00 pragmaticbigdata <amits...@gmail.com>: > I am using ignite version 1.6 and I have a replicated cache of <String, > BinaryObject> pre-loaded. In order to try out the dynamic structure change > ability with BinaryObjects, I tried iterating through the cache with > different approaches. All of them fail with an error > > Caused by: class org.apache.ignite.IgniteCheckedException: Class definition > was not found at marshaller cache and local file. > > Iterator Approach > > IgniteCache<String, BinaryObject> cache = > ignite.getOrCreateCache(cacheName); > > Iterator<Cache.Entry<String, BinaryObject>> iterator = > cache.iterator(); > while (iterator.hasNext()) { > > } > > > ForEach > > cache.forEach(entry -> { > BinaryObjectBuilder builder = entry.getValue().toBuilder(); > builder.setField(fieldToBeAdded, 0); > updatedCache.put(entry.getKey(), builder.build()); > }); > > cache.putAll(updatedCache); > > > Query Approach > > SqlQuery<String, BinaryObject> query = new SqlQuery<String, > BinaryObject>(table.getCacheValueType(), "CUSTOMER <> 'X'"); > try(QueryCursor<Cache.Entry<String, BinaryObject>> cursor = > cache.query(query)) { > logger.info("No of entries : {}", cursor.getAll().size()); > > } > > The error trace is here <http://pastebin.com/AV6kd2Ka> > > If I tried to query specific objects I am able to do it with the query > approach but iterating through all the elements of the cache is failing. > > What am I missing? > > Thanks > > > > > > -- > View this message in context: > http://apache-ignite-users.70518.x6.nabble.com/Iterating-through-a-BinaryObject-cache-fails-tp6038.html > Sent from the Apache Ignite Users mailing list archive at Nabble.com. > -- Best regards, Alexei Scherbakov