1

程序:Hbase 0.98、Elasticsearch 1.4.2 和 Phoenix 4.2.2

尝试为 Elasticsearch 创建 JDBC 河流时

curl -XPUT 'localhost:9200/_river/phoenix_jdbc_river/_meta' -d '{
    "type" : "jdbc",
    "jdbc" : {
        "url" : "jdbc:phoenix:localhost",
        "user" : "",
        "password" : "",
        "sql" : "select * from test.orders"
    }
}'

在终端收到错误

[ERROR][river.jdbc.RiverPipeline ] java.sql.SQLFeatureNotSupportedException
java.io.IOException: java.sql.SQLFeatureNotSupportedException
    at org.xbib.elasticsearch.river.jdbc.strategy.simple.SimpleRiverSource.fetch(SimpleRiverSource.java:341)
    at org.xbib.elasticsearch.river.jdbc.strategy.simple.SimpleRiverFlow.fetch(SimpleRiverFlow.java:220)
    at org.xbib.elasticsearch.river.jdbc.strategy.simple.SimpleRiverFlow.execute(SimpleRiverFlow.java:149)
    at org.xbib.elasticsearch.plugin.jdbc.RiverPipeline.request(RiverPipeline.java:88)
    at org.xbib.elasticsearch.plugin.jdbc.RiverPipeline.call(RiverPipeline.java:66)
    at org.xbib.elasticsearch.plugin.jdbc.RiverPipeline.call(RiverPipeline.java:30)
    at java.util.concurrent.FutureTask.run(FutureTask.java:262)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:745)
Caused by: java.sql.SQLFeatureNotSupportedException
    at org.apache.phoenix.jdbc.PhoenixStatement.setQueryTimeout(PhoenixStatement.java:1239)
    at org.xbib.elasticsearch.river.jdbc.strategy.simple.SimpleRiverSource.execute(SimpleRiverSource.java:380)
    at org.xbib.elasticsearch.river.jdbc.strategy.simple.SimpleRiverSource.fetch(SimpleRiverSource.java:320)
    ... 9 more.

您能否帮助找出问题所在以及如何解决?

4

1 回答 1

2

请替换jdbc:phoenix:localhostjdbc:phoenix:localhost:/hbase-unsecure

于 2015-01-22T18:49:29.543 回答