Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade storage integration test: Use V2 Archive ReaderWriter #6489

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

ekefan
Copy link
Contributor

@ekefan ekefan commented Jan 6, 2025

Which problem is this PR solving?

Description of the changes

  • Incrementally swaps the fields of StorageIntegration to align with v2 storage api

    • replaced ArchiveSpanReader with ArchiveTraceReader
    • replaced ArchiveSpanWriter with ArchiveTraceWriter
  • Updates test functions accordingly to work with the updated fields

How was this change tested?

Checklist

@ekefan ekefan requested a review from a team as a code owner January 6, 2025 00:51
@ekefan ekefan requested a review from pavolloffay January 6, 2025 00:51
@ekefan ekefan force-pushed the archive-reader-writer branch from 2ca2f23 to 9ad6870 Compare January 6, 2025 00:53
@ekefan ekefan marked this pull request as draft January 6, 2025 02:26
@yurishkuro yurishkuro added the changelog:ci Change related to continuous integration / testing label Jan 6, 2025
@yurishkuro yurishkuro marked this pull request as ready for review January 6, 2025 02:51
@yurishkuro yurishkuro enabled auto-merge (squash) January 6, 2025 02:52
@yurishkuro yurishkuro disabled auto-merge January 6, 2025 02:54
@yurishkuro
Copy link
Member

looks like some archive tests are failing

    --- ❌ FAIL: TestElasticsearchStorage/ArchiveTrace (0.00s)
panic: runtime error: invalid memory address or nil pointer dereference [recovered]
	panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x22fe57b]

goroutine 65 [running]:
testing.tRunner.func1.2({0x2532840, 0x3a10eb0})
	/opt/hostedtoolcache/go/1.23.4/x64/src/testing/testing.go:1632 +0x3fc
testing.tRunner.func1()
	/opt/hostedtoolcache/go/1.23.4/x64/src/testing/testing.go:1635 +0x6b6
panic({0x2532840?, 0x3a10eb0?})
	/opt/hostedtoolcache/go/1.23.4/x64/src/runtime/panic.go:785 +0x132
github.com/jaegertracing/jaeger/plugin/storage/integration.(*StorageIntegration).testArchiveTrace.func1(0x6c0f40?)
	/home/runner/work/jaeger/jaeger/plugin/storage/integration/integration.go:214 +0x47b
github.com/jaegertracing/jaeger/plugin/storage/integration.(*StorageIntegration).waitForCondition(0x2a7de18?, 0xc000523040, 0xc000439e58)
	/home/runner/work/jaeger/jaeger/plugin/storage/integration/integration.go:128 +0x165

@ekefan
Copy link
Contributor Author

ekefan commented Jan 6, 2025

there's no new change with the recent push... just trying to update the branch.

I will get back to these issues later in my day.

@ekefan ekefan force-pushed the archive-reader-writer branch from aaab620 to a43bc9a Compare January 7, 2025 09:16
@ekefan
Copy link
Contributor Author

ekefan commented Jan 7, 2025

Hello @yurishkuro,

I can't find the cause of this bug, but for elastic search and open search, the testArchiveTrace test fails; the archive trace reader returns an empty trace...
I want to try updating the reader before the writer, but I'd be glad to get any help or way forward from you.
Thanks alot.

@yurishkuro
Copy link
Member

Did you look at the logs? I see nil pointer segfaults, that should be easy to troubleshoot.

Copy link

codecov bot commented Jan 8, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 50.29%. Comparing base (b3be011) to head (54a0a07).

❗ There is a different number of reports uploaded between BASE (b3be011) and HEAD (54a0a07). Click for more details.

HEAD has 2 uploads less than BASE
Flag BASE (b3be011) HEAD (54a0a07)
cassandra-4.x-v1-manual 1 0
unittests 1 0
Additional details and impacted files
@@             Coverage Diff             @@
##             main    #6489       +/-   ##
===========================================
- Coverage   96.26%   50.29%   -45.98%     
===========================================
  Files         372      188      -184     
  Lines       21282    11410     -9872     
===========================================
- Hits        20488     5739    -14749     
- Misses        607     5213     +4606     
- Partials      187      458      +271     
Flag Coverage Δ
badger_v1 10.67% <ø> (ø)
badger_v2 2.78% <ø> (ø)
cassandra-4.x-v1-manual ?
cassandra-4.x-v2-auto 2.71% <ø> (ø)
cassandra-4.x-v2-manual 2.71% <ø> (ø)
cassandra-5.x-v1-manual 16.57% <ø> (ø)
cassandra-5.x-v2-auto 2.71% <ø> (ø)
cassandra-5.x-v2-manual 2.71% <ø> (ø)
elasticsearch-6.x-v1 20.23% <ø> (-0.01%) ⬇️
elasticsearch-7.x-v1 20.30% <ø> (-0.01%) ⬇️
elasticsearch-8.x-v1 20.46% <ø> (-0.01%) ⬇️
elasticsearch-8.x-v2 2.77% <ø> (ø)
grpc_v1 12.31% <ø> (ø)
grpc_v2 9.08% <ø> (ø)
kafka-3.x-v1 10.35% <ø> (ø)
kafka-3.x-v2 2.78% <ø> (ø)
memory_v2 2.78% <ø> (ø)
opensearch-1.x-v1 20.36% <ø> (+<0.01%) ⬆️
opensearch-2.x-v1 20.36% <ø> (+<0.01%) ⬆️
opensearch-2.x-v2 2.77% <ø> (-0.01%) ⬇️
tailsampling-processor 0.51% <ø> (ø)
unittests ?

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

ekefan added 9 commits January 8, 2025 09:37
Signed-off-by: Emmanuel Emonueje Ebenezer <[email protected]>
Signed-off-by: Emmanuel Emonueje Ebenezer <[email protected]>
---------

Signed-off-by: Emmanuel Emonueje Ebenezer <[email protected]>
Signed-off-by: Emmanuel Emonueje Ebenezer <[email protected]>
Signed-off-by: Emmanuel Emonueje Ebenezer <[email protected]>
Signed-off-by: Emmanuel Emonueje Ebenezer <[email protected]>
Signed-off-by: Emmanuel Emonueje Ebenezer <[email protected]>
Signed-off-by: Emmanuel Emonueje Ebenezer <[email protected]>
@ekefan ekefan force-pushed the archive-reader-writer branch from ccf0435 to 54a0a07 Compare January 8, 2025 08:46
if len(traces) > 0 {
actualTrace = traces[0]
} else {
actualTrace, err = s.ArchiveSpanReader.GetTrace(context.Background(), spanstore.GetTraceParameters{TraceID: tID})
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

with span reader, the archive span test(specifically) doesn't fail,
I have had no luck figuring out why it does fail with the archive trace reader,

TraceWriter tracestore.Writer
TraceReader tracestore.Reader
ArchiveTraceReader tracestore.Reader
ArchiveSpanReader spanstore.Reader
Copy link
Contributor Author

@ekefan ekefan Jan 8, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the plan is not to get this merged, I just wanted to show you somthing:

the segfaults occured because the ArchiveTraceReader wasn't reading the spans, so `actualTrace1 remained nil, hence the errors when trying to read the spans

but that doesn't occur with the archive span reader...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a tip - if you don't think the PR is ready for merge, you can convert it to a Draft. I would still get a notification of all changes because I subscribe to all, but it won't be saying "Ready for review".

@ekefan
Copy link
Contributor Author

ekefan commented Jan 8, 2025

I'll get more familiar with time, but git messed with me alot for this pr... alot of commits🙃🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants