Skip to content

Commit 487eb83

Browse files
committed
Remove default type as Elastic 7 deprecates document types
See: https://www.elastic.co/guide/en/elasticsearch/reference/7.x/removal-of-types.html `_doc` is a dummy document type that will work as well with older Elastic versions
1 parent 23fd223 commit 487eb83

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

elasticsearch/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
44

55
cmake_minimum_required(VERSION 3.0)
6-
project(elasticsearch VERSION 1.0.8 LANGUAGES C)
6+
project(elasticsearch VERSION 1.0.9 LANGUAGES C)
77
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Elasticsearch encoders and outputs")
88
set(CPACK_DEBIAN_PACKAGE_DEPENDS "${PACKAGE_PREFIX}-heka (>= 1.0), ${PACKAGE_PREFIX}-rjson (>= 1.0), ${PACKAGE_PREFIX}-cjson (>= 2.1), ${PACKAGE_PREFIX}-socket (>= 3.0)")
99
string(REGEX REPLACE "[()]" "" CPACK_RPM_PACKAGE_REQUIRES ${CPACK_DEBIAN_PACKAGE_DEPENDS})

elasticsearch/io_modules/encoders/elasticsearch/common.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ encoders_elasticsearch_common = {
1919
2020
-- String to use as the `_type` key's value in the generated JSON.
2121
-- Supports field interpolation as described below.
22-
type_name = "message" -- optional, default shown
22+
type_name = "_doc" -- optional, default shown
2323
2424
-- String to use as the `_id` key's value in the generated JSON.
2525
-- Supports field interpolation as described below.
@@ -126,7 +126,7 @@ function load_encoder_cfg()
126126
end
127127

128128
if cfg.type_name == nil then
129-
cfg.type_name = "message"
129+
cfg.type_name = "_doc"
130130
else
131131
assert(type(cfg.type_name) == "string", "type_name must be nil or a string")
132132
end

0 commit comments

Comments
 (0)