зеркало из
1
0
Форкнуть 0
Report plugin name/version when communicating with Kusto
This commit is contained in:
Bar Arnon 2019-05-26 16:20:46 +03:00 коммит произвёл Tamir Kamara
Родитель 5dc3ecbaa5
Коммит fbc43391c0
4 изменённых файлов: 13 добавлений и 3 удалений

3
.vscode/tasks.json поставляемый
Просмотреть файл

@ -10,7 +10,8 @@
"group": {
"kind": "build",
"isDefault": true
}
},
"problemMatcher": []
},
{
"label": "Run tests",

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

@ -20,3 +20,7 @@
- move to version 1.0.0-BETA-04 of azure-kusto-java sdk
- better support multiple kusto outputs running in parallel
## 0.4.0
- set 'client name for tracing' to identify usage of this plugin on Kusto logs

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

@ -30,6 +30,11 @@ class LogStash::Outputs::Kusto < LogStash::Outputs::Base
@logger.debug('Preparing Kusto resources.')
kusto_connection_string = Java::com.microsoft.azure.kusto.data.ConnectionStringBuilder.createWithAadApplicationCredentials(ingest_url, app_id, app_key.value, app_tenant)
# Unfortunately there's no way to avoid using the gem/plugin name directly...
name_for_tracing = "logstash-output-kusto:#{Gem.loaded_specs['logstash-output-kusto'].version}"
@logger.debug("Client name for tracing: #{name_for_tracing}")
kusto_connection_string.setClientVersionForTracing(name_for_tracing)
@kusto_client = Java::com.microsoft.azure.kusto.ingest.IngestClientFactory.createClient(kusto_connection_string)

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

@ -1,6 +1,6 @@
Gem::Specification.new do |s|
s.name = 'logstash-output-kusto'
s.version = '0.3.0'
s.name = 'logstash-output-kusto' #WATCH OUT: we hardcoded usage of this name in one of the classes.
s.version = '0.4.0'
s.licenses = ['Apache-2.0']
s.summary = 'Writes events to Azure Data Explorer (Kusto)'
s.description = 'This is a logstash output plugin used to write events to an Azure Data Explorer (a.k.a Kusto)'