[ https://issues.apache.org/jira/browse/KUDU-2360?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Grant Henke resolved KUDU-2360. ------------------------------- Fix Version/s: NA Resolution: Cannot Reproduce > kudu java client predicate query may lost the scanner > ----------------------------------------------------- > > Key: KUDU-2360 > URL: https://issues.apache.org/jira/browse/KUDU-2360 > Project: Kudu > Issue Type: Bug > Components: client > Affects Versions: 1.6.0 > Environment: kudu tserver 1.6 > kudu java client 1.6.0 > Reporter: zhangguangqiang > Priority: Major > Fix For: NA > > Attachments: A2F356BB-7B7A-4BB7-85B9-D3B3673B3943.png > > > When I use kudu java client to count kudu data with predicate condition。I > found the same condition may return different result when I run the same > process again and again。 > my kudu table create sql is like: > CREATE TABLE events ( > day INT NOT NULL, > sampling_group INT NOT NULL, > user_id BIGINT NOT NULL, > event_id INT NULL ENCODING BIT_SHUFFLE COMPRESSION DEFAULT_COMPRESSION, > ... > PRIMARY KEY (day, sampling_group) > PARTITION BY HASH (user_id) PARTITIONS 9 > STORED AS KUDU > TBLPROPERTIES ('kudu.table_name'='event_wos_p2', > 'kudu.master_addresses'='xxx', 'kudu.num_tablet_replicas'='1') > > my predicate condition is like: > KuduPredicate.newComparisonPredicate( > kuduTable.getSchema().getColumn("day"), > KuduPredicate.ComparisonOp.GREATER_EQUAL, 17550); > KuduPredicate.newComparisonPredicate( > kuduTable.getSchema().getColumn("day"), > KuduPredicate.ComparisonOp.LESS_EQUAL, 17558); > KuduPredicate.newComparisonPredicate( > kuduTable.getSchema().getColumn("event_id"), > KuduPredicate.ComparisonOp.EQUAL, 8)); > actually, the result is 0 when select count(*) from events where day<17558 > and event_id=8; > the result is 7 when select count(*) from events where day=17558 and > event_id=8。 > > When I run the sql in impala shell: > select count(*) from events where day>=17550 and day <= 17558 and event_id=8; > the result is accurate right。return result is 7. > But when I query count result use kudu java client with predicate condition > above。The result is *not* *stable。*sometimes get result 0. sometimes get > result 3... > > Futher,I add logs in kudu java client,and print the scanner id。when the > result is wrong,I grep the scanner id in tserver.log。I found warning log like: > Expiring scanner id: a303100cce864990bef9748572a458e3, of tablet > 847484029857408086f765fb4870fd7a, after 62707 ms of inactivity, which is > > TTL (60000 ms). > But the client get no exception and return result is 0。 > So I think is possibly the java client bug。it lost the scaner。 > Impala shell works normally。 -- This message was sent by Atlassian Jira (v8.3.4#803005)