Hi Slava
I did create the cache using DDL.
CREATE TABLE UserCache (
id long,
username varchar,
password varchar,
PRIMARY KEY (username, password)
)
WITH "template=partitioned, affinitykey=username, cache_name=UserCache,
key_type=no.toyota.gatekeeper.ignite.key.CredentialsKey,
value_type=no.toyota.gatekeeper.authenticate.Credentials";
The config looks like this, very simple:
<bean id="userCacheTemplate"
class="org.apache.ignite.configuration.CacheConfiguration">
<property name="name" value="userCache*"/>
<property name="cacheMode" value="REPLICATED"/>
<property name="backups" value="1"/>
</bean>
Why would I have to use uppercase? I did change now to test it but no still
getting the same exception.
./t
-----Original Message-----
From: slava.koptilin [mailto:[email protected]]
Sent: torsdag 25. januar 2018 14.08
To: [email protected]
Subject: Re: Binary type has different affinity key fields
Hi Thomas,
Could you please share a small code snippet of cache configuration/cache
creation?
Do you use DDL for that?
I guess that you need to define affinity keys using upper-case
public class CredentialsKey {
@QuerySqlField(index = true)
@AffinityKeyMapped
private String USERNAME;
@QuerySqlField(index = true)
private String PASSWORD;
...
}
Thanks,
Slava.
--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/