Commit graph

75 commits

Author SHA1 Message Date
Simen Bekkhus
e7fcd56b12
feat: Support OTel 0.25 & 0.26 (#188)
* feat: Support OTel 0.25

* feat: Support OTel 0.26
2024-10-16 21:05:35 +01:00
Alexander Kjäll
fc89e7ddb7
the example in the readme didn't compile (#189) 2024-10-16 20:25:08 +01:00
Collin Styles
cf06f0962a
Use new matchit syntax in documentation (#181)
* Use new matchit syntax in documentation

* Fix link in GitHub pull request template
2024-08-28 22:37:51 +01:00
Tom Finlayson
6cd4eb93f8 docs: add CHANGELOG entry 2024-08-22 16:14:38 +01:00
Tom Finlayson
3ddfded9e3 fix: restore adding http.url as an attribute when deprecated_attributes feature is enabled 2024-08-22 16:14:38 +01:00
Ethan Brierley
603ef97144 chore: prepare release 🚀
Prepare release of:
- reqwest-middleware 0.3.2 -> 0.3.3
- reqwest-tracing 0.5.2 -> 0.5.3
- reqwest-retry 0.6.0 -> 0.6.1
2024-08-09 09:17:32 +01:00
David Mládek
053d329e8b
OpenTelemetry 0.24 support (#171)
* feat: support opentelemetry 0.24

* minor fix

* Fix opentelemetry 0.24 by upgrading tracing-opentelemetry to 0.25

---------

Co-authored-by: Aitor Fernandez <aitor.fernandez@truelayer.com>
Co-authored-by: Ethan Brierley <ethanboxx@gmail.com>
2024-07-30 09:46:19 +01:00
Aitor Fernández
c90089ebd4
fix: user-agent (#172)
* fix: user-agent

* add deprecated_attributes on actions

* add package-name/feature-name for visibility
2024-07-29 18:47:29 +01:00
Aitor Fernández
4ce811911b
Add feature flag for deprecated fields (#167)
* Add feature flag for deprecated fields

* revert editor format

* rename flag

* remove unnecessary cfg not

* add comment and publish old and new attributes on request_span macro

* add comment

* update changelog

* Update reqwest-tracing/CHANGELOG.md

Co-authored-by: Ethan Brierley <ethanboxx@gmail.com>

* bump version

---------

Co-authored-by: Ethan Brierley <ethanboxx@gmail.com>
2024-07-15 11:53:31 +01:00
Ethan Brierley
f8c3e487de
chore: prepare release 🚀 (#165)
* chore: bump minor version for `reqwest-retry`

Breaking change introduced in https://github.com/TrueLayer/reqwest-middleware/pull/155

* chore: bump patch version for `reqwest-middlware`

* fix: `opentelemetry` item in wrong changelog

* chore: bump patch version for `reqwest-tracing`
2024-06-28 10:43:04 +01:00
Marcus Griep
88dbfe67fb
feat: support opentelemetry 0.23 (#156) 2024-06-03 10:12:56 +01:00
Luca Palmieri
9ac5f691bf
Fix logging of User-Agent header in reqwest-tracing (#148) 2024-04-26 13:54:35 +01:00
Ben Beasley
1954b5c94f
Fix missing LICENSE-* files in released crates (#147)
* Fix missing LICENSE-* files in released crates

* Changelog: Included license files in crates
2024-04-26 13:53:50 +01:00
Ethan Brierley
d2286b5e79 fix: Remove full url from default span & http.url -> url.full in SpanBackendWithUrl 2024-04-10 09:55:52 +01:00
Ethan Brierley
d401fc52e7 chore: remove deprecated items (we're making a breaking change anyway) 2024-04-10 09:55:52 +01:00
Ethan Brierley
09189ab63e fix: test compilation 2024-04-10 09:55:52 +01:00
Christopher Serr
3422e7338c Match stable Semantic Conventions for HTTP Spans
The stable [Semantic Conventions for HTTP
Spans](https://opentelemetry.io/docs/specs/semconv/http/http-spans/) use
different keys than the ones used in this crate. This changes them to
match the keys as defined by the stable specification.
2024-04-10 09:55:52 +01:00
Ethan Brierley
94a38211f7
feat!: prepare breaking release (#143) 2024-04-10 09:55:41 +01:00
Ethan Brierley
0bdb2b6ef4
feat!: upgrade to matchit 0.8.0 (#140)
A copy of #134 but just with the matchit upgrade.

Thank you @matiu2 for raising the original PR
2024-04-10 09:05:51 +01:00
Ethan Brierley
938a3a0e3c
chore: cargo-fmt 2024-04-03 18:23:30 +01:00
Conrad Ludgate
60212ae451
reqwest 0.12 and other breaking changes (#135)
* update reqwest and http crates

remove task_local_extensions

* remove older opentelemetry packages

* remove more legacy and add new otel

* attempt to make features additive

* features are additive

* delete commented out code

* build split

* docs

* more uniform with reqwest::Client

* remove arcs

* slight optimisation

* update readmes

* update changelog
2024-04-03 18:13:10 +01:00
Ethan Brierley
a7df7657e6
chore(request-tracing): release patch version 🚀 (#123) 2024-03-15 16:26:17 +00:00
Vasiliy Taranov
2a3f239a05
fix typos, add github action (#122) 2024-03-12 15:10:18 +00:00
Ethan Brierley
d20903e2f7
fix(reqwest-tracing): fix missing deps (#124)
Missed in https://github.com/TrueLayer/reqwest-middleware/pull/118
2024-03-12 15:03:25 +00:00
Robert Collins
d44458f402
Support opentelemetry 0.22 (#118) 2024-03-11 17:04:51 +00:00
Ethan Brierley
1c31f4bc7f
chore!(reqwest-tracing): bump patch version 🚀 2024-01-21 20:04:58 +00:00
Julian Tescher
32cc268f07
Add support for opentelemetry version 0.21 (#112)
* Add support for `opentelemetry` version `0.21`

* Fix tracer provider import
2024-01-19 11:17:54 +00:00
Ethan Brierley
a54319a9d6
Patch release v0.4.6 🚀 (#100)
* Add support for OpenTelemetry v0.20

* Add back dev-deps

* Attempt at tests

* Update reqwest-tracing/src/otel.rs

* Update reqwest-tracing/src/otel.rs

* Update reqwest-tracing/Cargo.toml

* Update reqwest-tracing/CHANGELOG.md
2023-08-23 12:34:20 +01:00
Conrad Ludgate
7b3493d96c
add opentelementry 0.20 support (#101) 2023-08-23 11:49:15 +01:00
Conrad Ludgate
b8b9400858
disable context propagation (#94)
* disable context propagation

* bump version

* removes leftover feature

* fix new test

* add back disabled test
2023-06-20 18:07:12 +01:00
Conrad Ludgate
fb7a964ba3
add default_span_name helper function (#93) 2023-05-15 14:55:56 +01:00
Conrad Ludgate
385314a298
fix otel status (#92)
* fix otel status

* bump
2023-05-15 11:45:55 +01:00
Alex Wakefield
af1080f21c
Move path matching changes to right log (#91)
* doc: move path matching changes to right log

* update

---------

Co-authored-by: Conrad Ludgate <conrad.ludgate@truelayer.com>
2023-05-12 11:16:42 +01:00
Conrad Ludgate
80d56d89f3
release middleware 2023-05-11 14:17:05 +01:00
Alex Wakefield
3457bf5702
Add OtelPathNames for span names (#89)
* feat: add `OtelPathNames` for span names

If this extension is provided span names will be `<method> <path name>`.
These path names will include parameter names rather than IDs or other elements that would increase the cardinality.

* doc: update changelog

* refactor: update `known_paths` to return error

* refactor: return `anyhow::Error` instead

This is as `reqwest_middleware::Error` is more focused on handling a
request.
2023-04-26 15:28:32 +01:00
Léo Gaspard
fef18b3506
feat: wasm32-unknown-unknown support (#79)
* feat: wasm32-unknown-unknown support

This replaces task-local-extensions with http's extensions, as http was
already in the dependency closure anyway and the other features of
task-local-extensions (that required an incompatible-with-wasm part of
tokio) were not used anyway.

* feat: have ci check that wasm32-unknown-unknown keeps compiling

* revert back to task-local-extensions

* fix ci

* fix random on wasm

* fix ci again

* bump

---------

Co-authored-by: Conrad Ludgate <conrad.ludgate@truelayer.com>
2023-03-09 11:33:13 +00:00
John Vandenberg
a7f9a112ed
Update example in tracing README (#76) 2022-11-23 07:39:54 +00:00
Conrad Ludgate
289bb0452c
bump all versions (#71) 2022-11-15 10:31:34 +00:00
tl-rodrigo-gryzinski
197f19781d
Make http.url field opt-in (#70) 2022-11-10 13:21:07 +00:00
Robert Collins
4fb158f785
Fix indents in Changelog. (#67) 2022-11-07 14:23:43 +00:00
Robert Collins
07d154cadf
Custom otel names (#65)
* Breaking change(macros): require explicit name for tracing middleware

Closes: #52

This is suggested by the Opentelemetry spec, which requires "Therefore,
HTTP client spans SHOULD be using conservative, low cardinality names
formed from the available parameters of an HTTP request, such as "HTTP
{METHOD_NAME}". Instrumentation MUST NOT default to using URI path as
span name, but MAY provide hooks to allow custom logic to override the
default span name.
"

* Permit customisation of otel span names via OtelName
2022-11-07 13:07:23 +00:00
Robert Collins
920cb5ac16
Capture URL as http.url (#64) 2022-11-07 08:45:58 +00:00
Robert Collins
7a09e335aa
Fix main builds (#66)
* Remove unneeded derefs

* Resolve reqwest_otel_span correctly in docs.

Macros always resolve to the crate root.
2022-11-07 08:39:03 +00:00
Robert Collins
ddd7e12104
Make clear examples are just examples (#63) 2022-11-07 06:51:40 +00:00
Kai
0f7c2e15fa
Add missing dep in reqwest-tracing README (#61) 2022-10-05 14:56:46 +01:00
Conrad Ludgate
3c00388cfb
bump reqwest-tracing (#59) 2022-09-29 16:17:12 +01:00
birkmose
dd877924c4
Opentelemetry 0.18 (#58)
* Support for opentelemetry 0.18

* Updated changelog

* Update CI/CD to test 0.18

* Update documentation to use opentelemetry 0.18

* Update to use 0.18 in libs
2022-09-20 16:07:32 +03:00
tl-flavio-barinas
ad18935d1f
bump/use alpha versions (#48) 2022-06-30 16:08:59 +01:00
tl-flavio-barinas
cbe69f61a1 reqwest-tracing: bump to v0.3.0 2022-06-30 14:57:55 +01:00
Alessandro Zanin
13ca870d20
Allows adding properties to the span (#43)
Provides reqwest-tracing with a trait ReqwestOtelSpanBackend, allowing custom fields/behaviour to be defined.

This is a breaking change as the TracingMiddleware signature now requires you to define a ReqwestOtelSpanBackend to provide it with the desired span behaviour.

Co-authored-by: Alessandro Zanin <ale.zanin90@gmail.com>
Co-authored-by: tl-flavio-barinas <flavio.barinas@truelayer.com>
Co-authored-by: Marco Tormento <tl-marco-tormento@users.noreply.github.com>
2022-06-30 14:54:54 +01:00