зеркало из
1
0
Форкнуть 0

* Fix DataMapping format when mapping is not provided

This commit is contained in:
Ramachandran A G 2024-04-02 19:10:46 +05:30 коммит произвёл Ramachandran G
Родитель 7e4d38adc2
Коммит 819ee0865c
2 изменённых файлов: 3 добавлений и 2 удалений

Просмотреть файл

@ -78,12 +78,13 @@ class LogStash::Outputs::Kusto < LogStash::Outputs::Base
is_mapping_ref_provided = !(json_mapping.nil? || json_mapping.empty?)
if is_mapping_ref_provided
@logger.debug('Using mapping reference.', json_mapping)
@ingestion_properties.setIngestionMapping(json_mapping, kusto_java.ingest.IngestionMapping::IngestionMappingKind::JSON)
@ingestion_properties.setDataFormat(kusto_java.ingest.IngestionProperties::DataFormat::JSON)
else
@logger.debug('No mapping reference provided. Columns will be mapped by names in the logstash output')
@ingestion_properties.setDataFormat(kusto_java.ingest.IngestionProperties::DataFormat::JSON)
end
# default mapping is JSON
@ingestion_properties.setIngestionMapping(json_mapping, kusto_java.ingest.IngestionMapping::IngestionMappingKind::JSON)
@delete_local = delete_local
@logger.debug('Kusto resources are ready.')
end

Просмотреть файл

@ -1 +1 @@
2.0.7
2.0.8