Code Monkey home page Code Monkey logo

Comments (6)

ljhan2 avatar ljhan2 commented on August 15, 2024

confluent-5.0.0
// 20200608132645
// http://10.5.3.125:8088/info

{
"KsqlServerInfo": {
"version": "5.0.0",
"kafkaClusterId": "ISsR3iwISiKafPcLW_UkxA",
"ksqlServiceId": "default_"
}
}

[root@esTest iflytek]# curl -X "POST" "http://10.5.3.125:8088/ksql" \

 -H "Content-Type: application/json; charset=utf-8" \
 -d $'{

"ksql": "LIST tables;",
"streamsProperties": {}
}'
[{"@type":"tables","statementText":"LIST tables;","tables":[{"type":"TABLE","name":"T","topic":"json","format":"JSON","isWindowed":false},{"type":"TABLE","name":"USERS_ORIGINAL","topic":"json1","format":"JSON","isWindowed":false}]}][root@esTest iflytek]#

from kcenter.

TrumanDu avatar TrumanDu commented on August 15, 2024

@ljhan2 应该是版本问题,目前支持5.3,5.4.未来一周内支持ksql db0.9。由于ksql接口变化,目前无法支持以下版本。

from kcenter.

ljhan2 avatar ljhan2 commented on August 15, 2024

能看得懂中文就好,问题我大体上排查了一下,原因如下:
curl -X "POST" "http://10.5.3.125:8088/ksql"
-H "Content-Type: application/json; charset=utf-8"
-d $'{
"ksql": "DESCRIBE EXTENDED T;",
"id":"fhswk-kafka|default_"
}'
其中包含了 "id":"fhswk-kafka|default_"会导致运行结果出错,去掉则正确
curl -X "POST" "http://10.5.3.125:8088/ksql"
-H "Content-Type: application/json; charset=utf-8"
-d $'{
"ksql": "DESCRIBE EXTENDED T;"
}'
需要修改的代码注释即可
image
另外websocket监听部分协议也需要适配下
curl -X "POST" "http://10.5.3.125:8088/query"
-H "Content-Type: application/vnd.ksql.v1+json; charset=utf-8"
-d $'{
"ksql": "select * from USERS_ORIGINAL;",
"streamsProperties": {}
}'==>这样错误,需要改成
curl -X "POST" "http://10.5.3.125:8088/query"
-H "Content-Type: application/json; charset=utf-8"
-d $'{
"ksql": "select * from USERS_ORIGINAL;",
"streamsProperties": {}
}'
代码位置如下
image
看你的回复是目前支持5.3,5.4.建议通过

image
查看版本信息进行针对性的适配处理,另外提个意见
image
建议以追加模式以表格的形式进行展示,且带上字段名称。
看好这个工具,望越做越好

from kcenter.

ljhan2 avatar ljhan2 commented on August 15, 2024

image

from kcenter.

TrumanDu avatar TrumanDu commented on August 15, 2024

@ljhan2 感谢回复!我们会持续改进的。

Content-Type: application/vnd.ksql.v1+json; charset=utf-8

是因为ksql rest api 需要,虽然目前两个都可以工作,整体来看还是需要修改为官方文档需要的类型。

from kcenter.

TrumanDu avatar TrumanDu commented on August 15, 2024

目前marter已经支持ksql0.9.0

from kcenter.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.