On Wed, Feb 09, 2022 at 01:21:14PM +0800, Wu Fengguang wrote:
On Tue, Feb 08, 2022 at 03:10:57PM +0800, Wei Jihui wrote:
From: Wei Jihui weijihuiall@163.com
- /data_api/es/:index/es_search is es search by dsl
是这样的吧:
es_search => _search
yes
- /data_api/es/:index/es_search_by_sql is es search by sql
我看你后面用了
>+# curl -X POST localhost:10005/data_api/es/jobs/_search_by_sql
然后调用的是
>+ @client.perform_request('GET', '_nlpcn/sql', {}, search_sql)
但我们应该最终调用这个吧:
https://github.com/opendistro-for-elasticsearch/sql POST https://<host>:<port>/_opendistro/_sql { "query": "SELECT * FROM my-index LIMIT 50" }
相应的API是不是相应的写成
/data_api/_opendistro/_sql
这个接口需要安装的插件没有我们用的es版本 目前用的这个接口 _nlpcn/sql
-# curl -X POST localhost:10005/es_find -H 'Content-Type: application/json' -d '{ +# curl -X POST localhost:10005/data_api/es/jobs/_search -H 'Content-Type: application/json' -d '{ # "query": {"size":10, "sort": [{"start_time": {"order": "desc"}}]}, -# "index": "jobs", -# "my_token": "16132550-...", -# "my_account": "auto-submit", -# "query_type": "eql" # can be omitted in this scenario +# "cci_authorization": {
这个貌似不错:
credentials
cci_credentials?
Thanks, Jihui
1 ~ (for/as sth); ~ (to do sth) qualities, achievements, etc that make one suitable; qualifications (学历、资历等的)资格: She has the perfect credentials for the job. 她做这工作完全够格. 2 documents showing that a person is what he claims to be, is trustworthy, etc (某人合乎条件、可以信任等的)证明书, 证件: I examined his credentials. 我查验了他的证件.
相比而言,这更像是一个结果:
authorization n. 授权, 许可
Thanks, Fengguang