JDBC River parameters

Jörg Prante edited this page on 23 Jan 2014 · 3 revisions

Overview of the default parameter settings:

{
"jdbc" :{
"strategy" : "simple",
"url" : null,
"user" : null,
"password" : null,
"sql" : null,
"schedule" : null,
"poolsize" : 1,
"rounding" : null,
"scale" : 2,
"autocommit" : false,
"fetchsize" : 10, /* Integer.MIN for MySQL */
"max_rows" : 0,
"max_retries" : 3,
"max_retries_wait" : "30s",
"locale" : Locale.getDefault().toLanguageTag(),
"index" : "jdbc",
"type" : "jdbc",
"bulk_size" : 100,
"max_bulk_requests" : 30,
"bulk_flush_interval" : "5s",
"index_settings" : null,
"type_mapping" : null
}
}

strategy -the strategy of the JDBC river, currently implemented: "simple", "column"

url - the JDBC URL

user - the JDBC database user

password - the JDBC database password

sql - SQL statement(s), either a string or a list. If a statement ends with .sql, the statement is looked up in the file system. Example for a list of SQL statements:

"sql" : [
{
"statement" : "select ... from ... where a = ?, b = ?, c = ?",
"parameter" : [ "value for a", "value for b", "value for c" ],
"callable" : false
},
{
"statement" : ...
}
]

parameter - bind parameters for the SQL statement (in order)

callable - boolean flag, if true, the SQL statement is interpreted as a JDBC CallableStatement (default: false)

schedule - a cron expression for scheduled execution. Syntax is equivalent to the Quartz cron expression format and is documented at http://jprante.github.io/elasticsearch-river-jdbc/apidocs/org/xbib/elasticsearch/river/jdbc/support/cron/CronExpression.html

poolsize - the pool size of the thread pool that executes the scheduled SQL statements

rounding - rounding mode for numeric values: "ceiling", "down", "floor", "halfdown", "halfeven", "halfup", "unnecessary", "up"

scale - the precision of the numeric values

autocommit - true if each statement should be automatically executed

fetchsize - the fetchsize for large result sets, most drivers implement fetchsize to control the amount of rows in the buffer while iterating through the result set

max_rows - limit the number of rows fetches by a statement, the rest of the rows is ignored

max_retries - the number of retries to (re)connect to a database

max_retries_wait - the time that should be waited between retries

locale - the default locale (used for parsing numerical values, floating point character)

index - the Elasticsearch index used for indexing the data from JDBC

type - the Elasticsearch type of the index used for indexing the data from JDBC

bulk_size - the length of each bulk index request submitted

max_bulk_requests - the maximum number of concurrent bulk requests

bulk_flush_interval - the time period the bulk processor is flushing outstanding documents

index_settings - optional settings for the Elasticsearch index

type_mapping - optional mapping for the Elasticsearch index type

elasticsearch river 参数文档的更多相关文章

  1. Elasticsearch 7.x文档基本操作(CRUD)

    官方文档:https://www.elastic.co/guide/en/elasticsearch/reference/current/docs.html 1.添加文档 1.1.指定文档ID PUT ...

  2. elasticsearch 官方监控文档 老版但很有用

    https://zhaoyanblog.com/page/1?s=elasticsearch 监控每个节点(jvm部分) 操作系统和进程部分 操作系统和进程部分的含义是很清楚的,这里不会描述的很详细. ...

  3. elasticsearch 基础 —— 分布式文档存储原理

    路由一个文档到一个分片中 当索引一个文档的时候,文档会被存储到一个主分片中. Elasticsearch 如何知道一个文档应该存放到哪个分片中呢?当我们创建文档时,它如何决定这个文档应当被存储在分片  ...

  4. 【Elasticsearch学习】文档搜索全过程

    在ES执行分布式搜索时,分布式搜索操作需要分散到所有相关分片,若一个索引有3个主分片,每个主分片有一个副本分片,那么搜索请求会在这6个分片中随机选择3个分片,这3个分片有可能是主分片也可能是副本分片, ...

  5. 关于Elasticsearch单个索引文档最大数量问题

    因为ElasticSearch是一个基于Lucene的搜索服务器.Lucene的索引有个难以克服的限制,导致Elasticsearch的单个分片存在最大文档数量限制,一个索引分片的最大文档数量是20亿 ...

  6. Elasticsearch操作Document文档

    1.利用客户端操作Document文档数据        1.1 创建一个文档(创建数据的过程,向表中去添加数据)            请求方式:Post    请求地址:es所在IP:9200/索 ...

  7. 5.ElasticSearch系列之文档的基本操作

    1. 文档写入 # create document. 自动生成 _id POST users/_doc { "user" : "shenjian", " ...

  8. Elasticsearch 相同内容文档,不同score(评分)的奇怪问题

    原文:http://stackoverflow.com/questions/14580752/elasticsearch-gives-different-scores-for-same-documen ...

  9. elasticsearch 查询所有文档

    0.添加一个索引 curl -i -XPUT http://172.31.250.16:10004/test_index/user/1 -d '{ "name": "小明 ...

随机推荐

  1. adb命令 查看运行APP当前页面的Activity名称

    命令 adb shell "dumpsys window | grep mCurrentFocus" 结果

  2. ps -aux|grep mysql时候报错:Warning: bad syntax, perhaps a bogus '-'? See /usr/share/doc/procps-3.2.8/FAQ

    ps -aux|grep mysql时候报错:Warning: bad syntax, perhaps a bogus '-'? See /usr/share/doc/procps-3.2.8/FAQ ...

  3. 把云数据库带回家!阿里云发布POLARDB Box数据库一体机

    9月26日,2019杭州云栖大会上,阿里云宣布正式推出高性能数据库一体机——POLARDB Box,用户部署在自有数据中心即可享受云数据库的便捷体验,同时还为Oracle等传统数据库用户提供一键迁移功 ...

  4. JavaScript中纯JS写21点游戏

    // 21点游戏 分为人机对战和人人对战 // 玩家每次抽一张牌 牌的点数为1-10点随机数 谁更接近21点谁就获胜 let readline = require("readline-syn ...

  5. 二分查找总结及部分Lintcode题目分析 4

    二分法不只能像之前的记录,可以找到index~第二种类型是找到二分答案.有以下几个例子,都是之前二分法的扩展,不再赘述,只记录下忽略的点,以后回顾多注意~ 1. wood cut class Solu ...

  6. 二分图最佳匹配KM算法 /// 牛客暑期第五场E

    题目大意: 给定n,有n间宿舍 每间4人 接下来n行 是第一年学校规定的宿舍安排 接下来n行 是第二年学生的宿舍安排意愿 求满足学生意愿的最少交换次数 input 2 1 2 3 4 5 6 7 8 ...

  7. 继承关系中子类使用@Data注解问题

    HashSet中使用@Data注解问题 平时习惯使用lombok工具,免去了我们写get.set方法之类的,当然了,我们使用@Data注解后,equals().hashCode().toString( ...

  8. Nodejs之路(三)—— Nodejs之Express框架

    Express 原生的 http 在某些方面表现不足以应对我们的开发需求,所以我们需要使用框架来加快我们的开发效率.框架的目的就是提高效率,让我们的代码更高度统一 在Node 中,有很多 Web 开发 ...

  9. oracle 如何在一个数据库创建多个实例

    实例:是一个非固定的.基于内存的基本进程与内存结构.当服务器关闭后,实例也就不存在了. 数据库(Database)指的是固定的.基于磁盘的数据文件.控制文件.日志文件.参数文件和归档日志文件等. 一般 ...

  10. 2019-11-12-浅谈-Windows-桌面端触摸架构演进

    title author date CreateTime categories 浅谈 Windows 桌面端触摸架构演进 lindexi 2019-11-12 14:37:31 +0800 2019- ...