Matthieu MOREL
564818fd7f
[chore]: fix testifylint rules ( #12791 )
...
#### Description
Fixes testifylint rules which where disabled with golangci-lint v2
upgrade
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
2025-04-02 23:10:07 +00:00
Alex Boten
fc28929061
move internal/testdata to pdata/testdata ( #9885 )
...
This reduces dependencies from the consumer package while making
testdata available across repos. It will allow us to remove duplicated
code and its a fairly small surface area.
Fixes
https://github.com/open-telemetry/opentelemetry-collector/issues/9886
---------
Signed-off-by: Alex Boten <223565+codeboten@users.noreply.github.com>
2024-04-08 08:36:57 -07:00
Alex Boten
062d0a7ffc
[chore] remove unnecessary underscores ( #9580 )
...
As per feedback from my previous PR
Signed-off-by: Alex Boten <aboten@lightstep.com>
2024-02-13 13:34:53 -08:00
Alex Boten
80d704deb4
[chore] use license shortform ( #7694 )
...
* [chore] use license shortform
To remain consistent w/ contrib repo, see https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/22052
Signed-off-by: Alex Boten <aboten@lightstep.com>
* make goporto
Signed-off-by: Alex Boten <aboten@lightstep.com>
---------
Signed-off-by: Alex Boten <aboten@lightstep.com>
2023-05-18 13:11:17 -07:00
Dmitrii Anoshin
7740c7b387
Remove usages of deprecated pdata Clone methods ( #6170 )
2022-09-28 18:25:22 -07:00
Bogdan Drutu
1a4361c49a
Remove unnecessary and unused testdata ( #5599 )
...
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2022-06-27 09:43:33 -07:00
Dmitrii Anoshin
734e25e8de
Split `model` by signal type and move it to the new `pdata` module ( #5168 )
...
Split all `pdata` related code by type and move it from `model` to the new module `pdata`.
- `model/pdata` and `model/otlp` are moved to `pdata/plog`, `pdata/pmetric` and `pdata/ptrace`.
- `model/otlpgrpc` is moved to `pdata/plogotlp`, `pdata/pmetricotlp` and `pdata/ptraceotlp`.
Now all the API in `model` except for `model/semconv` is deprecated.
2022-04-11 16:00:26 -07:00
Alex Boten
1d5fdd1c1f
Deprecation of pdata methods following OTLP v0.15.0 ( #5076 )
...
* Deprecation of pdata methods following OTLP v0.15.0
Adding deprecation methods for the following pdata methods:
- InstrumentationLibrary is now Scope
- InstrumentationLibrarySpans is now ScopeSpans
- InstrumentationLibraryLogs is now ScopeLogs
- InstrumentationLibraryMetrics is now ScopeMetrics
* update changelog
* add deprecated method on resource spans/metrics/logs
* add InstrumentationLibrary deprecation method
2022-03-28 00:32:48 -07:00
Bogdan Drutu
87405ddaa4
Small cleanup for batchprocessor split logic ( #4284 )
...
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-10-28 08:49:51 -07:00
Traian Schiau
fd61bbbc9b
pdatagen - Add MoveTo method for struct types ( #4240 )
...
* [pdatagen] Add MoveTo method for struct types
* [pdatagen] Add MoveTo method for struct types - regenerate
* [batchprocessor] Split benchmarks rework
- Fix metric split benchmark
- Ignore clone counters in split benchmarks
* [batchprocessor] Use MoveTo in split
* [batchprocessor] Skip long running split benchmarks
* [batchprocessor] Improve coverage
2021-10-27 10:18:54 -07:00
Anthony Mirabella
9e8bded5b4
Deprecate Resize() from pdata slice APIs ( #3573 )
...
* Remove Resize() from pointer slice API
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* model/pdata: refactor value slice interfaces
* Removed Resize()
* Added EnsureCapacity() and AppendEmptyN()
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* -Fix function signature in cpu_scraper_linux.go
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Fix remaining Resize() calls
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Fix OS-specific processes scraper
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Remove tests for equality of value slices that aren't comparable
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Remove AppendEmptyN from pdata slice APIs
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* batchprocessor: improve splitMetric() to avoid copying entire metric unless necessary
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* model/pdata: restore Resize() for slice types, mark as deprecated
Signed-off-by: Anthony J Mirabella <a9@aneurysm9.com>
* Update metrics_test.go
* Update metrics_test.go
Co-authored-by: Bogdan Drutu <bogdandrutu@gmail.com>
Co-authored-by: Bogdan Drutu <lazy@splunk.com>
2021-07-12 19:01:24 -07:00
Bogdan Drutu
c63d0c68cd
Move pdata in the new package ( #3483 )
...
The new module go.opentelemetry.io/collector/model will be created later when the internal data will
also be moved.
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-06-25 01:17:31 +03:00
Bogdan Drutu
2d48457b64
Rename [Trace|Log]Data to Traces|Logs in internal package testdata ( #3205 )
...
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-05-17 15:01:33 -07:00
Bogdan Drutu
7b39a894e1
Fix batch processor traces reorder, improve performance ( #3107 )
...
Benchmarks Before:
```
goos: darwin
goarch: amd64
pkg: go.opentelemetry.io/collector/processor/batchprocessor
cpu: Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
BenchmarkSplitTraces
BenchmarkSplitTraces-16 8277 135600 ns/op 222440 B/op 1725 allocs/op
PASS
```
Benchmarks After:
```
goos: darwin
goarch: amd64
pkg: go.opentelemetry.io/collector/processor/batchprocessor
cpu: Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
BenchmarkSplitTraces
BenchmarkSplitTraces-16 9896 108060 ns/op 172409 B/op 1372 allocs/op
PASS
```
Benchmarks Reference Clone:
```
goos: darwin
goarch: amd64
pkg: go.opentelemetry.io/collector/processor/batchprocessor
cpu: Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
BenchmarkCloneSpans
BenchmarkCloneSpans-16 12393 97528 ns/op 167896 B/op 1303 allocs/op
PASS
```
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-05-05 15:19:29 -07:00
Bogdan Drutu
13e45667cf
Cleanup usages of Resize(1), after PR #2970 ( #2971 )
...
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-04-20 18:04:31 -07:00
Bogdan Drutu
cb6014387d
Move testdata up one level, no point in being data/testdata ( #2198 )
...
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2020-11-24 11:53:36 -08:00
Jay Camp
1e65674799
Update copyright ( #1597 )
...
* Update copyright
* rebase
2020-08-19 18:25:44 -07:00
Pavol Loffay
5c7db8cce7
Fix overflowing batch size ( #1310 )
...
* Fix overflowing batch size
Signed-off-by: Pavol Loffay <ploffay@redhat.com>
* Use max size
Signed-off-by: Pavol Loffay <ploffay@redhat.com>
2020-07-14 08:04:37 -07:00