3:elasticsearch服务编写
import java.util.List;
import java.util.Map;
public interface IIndexService<T> {
public boolean insertOne(T t);
public boolean insertList(List<T> lists);
public boolean deleteOne(T t);
public boolean deleteList(List<T> lists);
public boolean updateOne(T t);
public boolean udateList(List<T> lists);
public List search(String JSONQuery, String indexName, int start, int size);
public List searchField(String jsonQuery, String indexName, int start, int size,String ...fields);
public boolean checkDocExisted(String indexName,String type,String id);
public boolean updateFields(String id, String indexName,String type,String script,Map<String, Object> maps);
}
相关文章