Skip to content

Latest commit

 

History

History
22 lines (14 loc) · 543 Bytes

get-api.md

File metadata and controls

22 lines (14 loc) · 543 Bytes

Get API

根据id查看文档:

GetResponse response = client.prepareGet("twitter", "tweet", "1").get();

更多请查看 rest get API 文档

配置线程

operationThreaded 设置为 true 是在不同的线程里执行此次操作

下面的例子是operationThreaded 设置为 false

GetResponse response = client.prepareGet("twitter", "tweet", "1")
        .setOperationThreaded(false)
        .get();