ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "kcheng.mvp" <kcheng....@gmail.com>
Subject Re: class org.apache.ignite.internal.processors.query.IgniteSQLException: Failed to find SQL table for type:
Date Sat, 02 Dec 2017 14:11:28 GMT
    @Test
    public void happyFlow(){
        UserAppInfo userAppInfo = dynamicUserAppInfo();
        userAppInfoService.put(userAppInfo);
        UserAppInfo userAppInfo1 =
userAppInfoService.get(userAppInfo.getAppId(), userAppInfo.getUid());
        Assert.assertNotNull(userAppInfo1);
        Assert.assertEquals(userAppInfo1, userAppInfo);
 *       SqlQuery sql = new SqlQuery(UserAppInfo.class, "appid =
?").setArgs(userAppInfo.getAppId());
       
userAppInfoService.getCache(PersistenceService.CacheName.USER_APP_INFO).query(sql);*
    }


it's very simple, firstly I create an object and put it into case then get
it out by key. the asserts passed.
when I try to get it out by SQLQuery then I got above exception.

here is part of my pojo code

I run into above exception when I do a SQLQuery. but it's works well with
put/get.

I have below dependency 

 <ignite.version>2.3.0</ignite.version>

 <dependency>
            <groupId>org.apache.ignite</groupId>
            <artifactId>ignite-core</artifactId>
            <version>${ignite.version}</version>
        </dependency>

        <dependency>
            <groupId>org.apache.ignite</groupId>
            <artifactId>ignite-spring</artifactId>
            <version>${ignite.version}</version>
        </dependency>

        <dependency>
            <groupId>org.apache.ignite</groupId>
            <artifactId>ignite-indexing</artifactId>
            <version>${ignite.version}</version>
        </dependency>

public class UserAppInfo implements Serializable{
    private static final long serialVersionUID = -6137971973241293268L;

    @QuerySqlField(index = true)
    private String appId;

    @QuerySqlField(index = true)
    private String uid;






--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Mime
View raw message