1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
community.general/plugins/callback
patchback[bot] 839880d711
Add opentelemetry callback plugin (#3091) (#3373)
* Add opentelemetry callback plugin

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

* Formatting (text), booleans and renamed env variables

* This should be done in a future release

* Remove insecure in favour of the OTEL env variable. Add descriptions

* Use OpenTelemetrySource

* Move generate_distributed_traces

* Move update_span_data and set_span_attribute

* Move finish_task

* Move start_task

* Refactor to support UTs

* Add first UT

* Fix codestyle

* opentelemetry callback entry in the botmeta

* Fix linting

* Fix signature

* Mock methods

* Use MagicMock

* Mock the methods

* UT for transform_to_boolean_or_default

* Fix linting

* Set test data

* Mock _time_ns

* Exclude tests for python <= 3.6

* Remove obsoleted setup task type configuration

* Remove unused docs

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

* Fix docs

* unrequired logic that was originally took from https://github.com/ansible/ansible/blob/devel/lib/ansible/plugins/callback/junit.py\#L226

* Use raise_from for the required dependencies

* Fix linting

* Add requirements for the UTs

* add missing dependency for the opentelemetry plugin in the UTs

* Add ANSIBLE_ prefix for the ansible specific options

* Add more context in the docs and remove duplicated docs

* As suggested in the code review

* Verify if the OTEL env variables for the endpoint were set

* Fix docs typo

* Fix linting

* Revert "Fix linting"

This reverts commit 3a54c827c5472553a6baf5598bc76a0f63f020c1.

* Revert "Verify if the OTEL env variables for the endpoint were set"

This reverts commit cab9d8648899c28c0345745690c4ec7a41f7e680.

* Remove console_output as suggested

* Apply suggestions from code review

Co-authored-by: flowerysong <junk+github@flowerysong.com>

* Delegate the definition of OTEL_EXPORTER_OTLP_INSECURE to the user

* Move definitions above, close to the class that uses them

Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: flowerysong <junk+github@flowerysong.com>
(cherry picked from commit 517570a64f)

Co-authored-by: Victor Martinez <victormartinezrubio@gmail.com>
2021-09-15 07:20:36 +02:00
..
cgroup_memory_recap.py <plugin_type>: -> name: (#1541) 2021-01-12 07:12:03 +01:00
context_demo.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
counter_enabled.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
dense.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
diy.py Replace ansible.module_utils._text by ansible.module_utils.common.text.converters (#2877) (#2882) 2021-06-27 09:39:18 +02:00
hipchat.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
jabber.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
log_plays.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
loganalytics.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
logdna.py [PR #3194/1fec1d0c backport][stable-3] Fix sanity failures (#3195) 2021-08-12 13:46:55 +02:00
logentries.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
logstash.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
mail.py Replace ansible.module_utils._text by ansible.module_utils.common.text.converters (#2877) (#2882) 2021-06-27 09:39:18 +02:00
nrdp.py Add option type validation. (#2878) (#2886) 2021-06-27 10:24:38 +02:00
null.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
opentelemetry.py Add opentelemetry callback plugin (#3091) (#3373) 2021-09-15 07:20:36 +02:00
osx_say.py Initial commit 2020-03-09 09:11:07 +00:00
say.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
selective.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
slack.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
splunk.py callback_splunk - Add user-configurable event correlation id (#2790) (#2817) 2021-06-16 21:02:00 +02:00
sumologic.py <plugin_type>: -> name: (#1541) 2021-01-12 07:12:03 +01:00
syslog_json.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
unixy.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00
yaml.py fixed the utf-8 marker (#3162) (#3165) 2021-08-07 15:59:29 +02:00