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

feat: conversation folders [WPB-14309] #3106

Merged
merged 19 commits into from
Nov 15, 2024
Merged

Conversation

Garzas
Copy link
Contributor

@Garzas Garzas commented Nov 14, 2024

TaskWPB-14309 Handle conversation folders and favorites from events


PR Submission Checklist for internal contributors

  • The PR Title

    • conforms to the style of semantic commits messages¹ supported in Wire's Github Workflow²
    • contains a reference JIRA issue number like SQPIT-764
    • answers the question: If merged, this PR will: ... ³
  • The PR Description

    • is free of optional paragraphs and you have filled the relevant parts to the best of your ability

What's new in this PR?

  • handling label events with user and favorites folder with conversation ids
  • added sync step to fetch all labels
  • added functionality to create favorite folder if it does not exist on backend
  • extracted method toModelConversationWithEvents to parse ConversationDetailsWithEvents from dao to model
  • added use cases to get favorite folder and to observe favorite conversations

@Garzas Garzas self-assigned this Nov 14, 2024
@echoes-hq echoes-hq bot added the echoes: product-roadmap Work aligned with the customer-announced roadmap, targeting a specific release date. label Nov 14, 2024
Copy link
Contributor

github-actions bot commented Nov 14, 2024

Test Results

3 284 tests  +7   3 177 ✅ +7   5m 6s ⏱️ +38s
  559 suites +2     107 💤 ±0 
  559 files   +2       0 ❌ ±0 

Results for commit c07e618. ± Comparison against base commit f2ae88b.

♻️ This comment has been updated with latest results.

Copy link
Contributor

github-actions bot commented Nov 14, 2024

🐰 Bencher Report

Branchfeat/conversation-folders
Testbedubuntu-latest

⚠️ WARNING: The following Measure does not have a Threshold. Without a Threshold, no Alerts will ever be generated!

Click here to create a new Threshold
For more information, see the Threshold documentation.
To only post results if a Threshold exists, set the --ci-only-thresholds CLI flag.

Click to view all benchmark results
BenchmarkLatencynanoseconds (ns)
com.wire.kalium.benchmarks.logic.CoreLogicBenchmark.createObjectInFiles📈 view plot
⚠️ NO THRESHOLD
662,220.96
com.wire.kalium.benchmarks.logic.CoreLogicBenchmark.createObjectInMemory📈 view plot
⚠️ NO THRESHOLD
582,489,421.14
com.wire.kalium.benchmarks.persistence.MessagesNoPragmaTuneBenchmark.messageInsertionBenchmark📈 view plot
⚠️ NO THRESHOLD
1,325,344,024.72
com.wire.kalium.benchmarks.persistence.MessagesNoPragmaTuneBenchmark.queryMessagesBenchmark📈 view plot
⚠️ NO THRESHOLD
21,477,269.15
🐰 View full continuous benchmarking report in Bencher

@datadog-wireapp
Copy link

datadog-wireapp bot commented Nov 14, 2024

Datadog Report

Branch report: feat/conversation-folders
Commit report: 9bbaa06
Test service: kalium-jvm

✅ 0 Failed, 3177 Passed, 107 Skipped, 38.55s Total Time

Copy link
Contributor

@yamilmedina yamilmedina left a comment

Choose a reason for hiding this comment

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

Looking solid! I have some questions and small improvements, here and there that we can take a look 🚀

Copy link
Contributor

@saleniuk saleniuk left a comment

Choose a reason for hiding this comment

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

👏

@Garzas Garzas enabled auto-merge November 15, 2024 09:48
@codecov-commenter
Copy link

codecov-commenter commented Nov 15, 2024

Codecov Report

Attention: Patch coverage is 48.40000% with 129 lines in your changes missing coverage. Please review.

Project coverage is 54.20%. Comparing base (f2ae88b) to head (c07e618).

Files with missing lines Patch % Lines
...m/network/api/authenticated/properties/LabelDTO.kt 0.00% 21 Missing ⚠️
.../api/authenticated/notification/EventContentDTO.kt 0.00% 19 Missing ⚠️
.../conversation/folders/ConversationFolderMappers.kt 51.72% 12 Missing and 2 partials ⚠️
...nversation/folders/ConversationFolderRepository.kt 66.66% 12 Missing ⚠️
...lium/logic/data/conversation/ConversationFolder.kt 0.00% 11 Missing ⚠️
...rveConversationListDetailsWithEventsUseCaseImpl.kt 0.00% 9 Missing ⚠️
...re/conversation/folder/GetFavoriteFolderUseCase.kt 0.00% 8 Missing ⚠️
...in/com/wire/kalium/logic/data/event/EventMapper.kt 0.00% 6 Missing ⚠️
.../logic/data/conversation/ConversationRepository.kt 50.00% 5 Missing ⚠️
...um/logic/feature/conversation/ConversationScope.kt 0.00% 4 Missing ⚠️
... and 8 more
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #3106      +/-   ##
===========================================
- Coverage    54.21%   54.20%   -0.02%     
===========================================
  Files         1196     1205       +9     
  Lines        35596    35806     +210     
  Branches      3625     3641      +16     
===========================================
+ Hits         19300    19410     +110     
- Misses       14896    14993      +97     
- Partials      1400     1403       +3     
Files with missing lines Coverage Δ
...Main/kotlin/com/wire/kalium/logger/KaliumLogger.kt 69.79% <100.00%> (ø)
...lium/logic/data/conversation/ConversationMapper.kt 57.84% <100.00%> (+0.09%) ⬆️
...n/kotlin/com/wire/kalium/logic/data/event/Event.kt 78.53% <100.00%> (+0.36%) ⬆️
.../com/wire/kalium/logic/data/sync/SlowSyncStatus.kt 100.00% <100.00%> (ø)
...logic/sync/receiver/UserPropertiesEventReceiver.kt 74.07% <100.00%> (+21.13%) ⬆️
...com/wire/kalium/logic/sync/slow/SlowSyncManager.kt 93.02% <ø> (ø)
.../com/wire/kalium/logic/sync/slow/SlowSyncWorker.kt 96.61% <100.00%> (+0.11%) ⬆️
...um/persistence/dao/conversation/ConversationDAO.kt 100.00% <ø> (ø)
...ersistence/dao/conversation/ConversationDAOImpl.kt 72.98% <100.00%> (ø)
...ao/conversation/folder/ConversationFolderEntity.kt 100.00% <100.00%> (ø)
... and 20 more

... and 3 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f2ae88b...c07e618. Read the comment docs.

@Garzas Garzas added this pull request to the merge queue Nov 15, 2024
Merged via the queue into develop with commit d140d79 Nov 15, 2024
22 checks passed
@Garzas Garzas deleted the feat/conversation-folders branch November 15, 2024 12:45
FOREIGN KEY (conversation_id) REFERENCES Conversation(qualified_id) ON DELETE CASCADE ON UPDATE CASCADE,
FOREIGN KEY (folder_id) REFERENCES ConversationFolder(id) ON DELETE CASCADE ON UPDATE CASCADE,

PRIMARY KEY (conversation_id, folder_id)
Copy link
Member

Choose a reason for hiding this comment

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

this should be the other way around if you want to query conversations by folder

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
echoes: product-roadmap Work aligned with the customer-announced roadmap, targeting a specific release date. 🚨 Potential breaking changes 👕 size: XXL type: feature ✨
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants