ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From James Isaac <jamesisaa...@gmail.com>
Subject Fwd: Create and query a binary cache in ignite
Date Mon, 31 Jul 2017 06:43:44 GMT

I am trying to use BinaryObjects to create the cache at runtime. For
example, instead of writing a pojo class such as Employee and configuring
it as a cache value type, I need to be able to dynamically configure the
cache with the field names and field types for the particular cache.

I have posted the sample code on stackoverflow: https://
binary-cache-in-ignite (Posting the code here would be messy)

I am trying to configure the cache with the employeeId (Integer) as key and
the whole employee record (BinaryObject) as value. When I run the above
class, I get the following exception :

Caused by: org.h2.jdbc.JdbcSQLException: Table "EMPLOYEE" not found;
SQL statement:
select * from "emplCache".Employee where salary > 500 limit 5

What am I doing wrong here? Is there anything more other than this line:


I checked out https://github.com/apache/ignite/blob/master/examples/sr

as Nikolay suggested but I see that they are setting the pojo class as the
indexed type. Is there any way I can avoid this?



View raw message