-
Notifications
You must be signed in to change notification settings - Fork 885
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
Unify AdsService with iOS #26639
Unify AdsService with iOS #26639
Conversation
[puLL-Merge] - brave/brave-core@26639 DescriptionThis PR refactors and updates the Brave Ads service implementation, moving some functionality from the browser layer to the core layer and updating interfaces and implementations accordingly. The changes aim to improve code organization, reduce dependencies, and potentially enhance maintainability. ChangesChanges
Possible Issues
Security HotspotsNone identified. graph TD
A[AdsService] --> B[AdsServiceImpl]
A --> C[AdsServiceImplIOS]
B --> D[NotificationAdPlatformBridge]
B --> E[AdsServiceDelegate]
F[BraveAdsNativeHelper] --> A
G[BraveRewardsNativeWorker] --> A
H[BraveNewsController] --> A
I[ViewCounterService] --> A
sequenceDiagram
participant User
participant Browser
participant AdsService
participant AdsServiceDelegate
participant NotificationAdPlatformBridge
User->>Browser: Interacts with browser
Browser->>AdsService: Triggers ad-related event
AdsService->>AdsServiceDelegate: Requests to show/close ad
AdsServiceDelegate->>NotificationAdPlatformBridge: Shows/closes notification ad
NotificationAdPlatformBridge-->>AdsServiceDelegate: Confirms action
AdsServiceDelegate-->>AdsService: Reports result
AdsService-->>Browser: Updates ad state
Browser-->>User: Displays/removes ad
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM (see comments). Thanks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rewards 👍
Released in v1.75.35 |
This is a prerequisite for the Ads-Internals page task brave/brave-browser#40952, as we now need to access AdsService from various parts of the Brave iOS codebase.
This is also a step in Unification of Service Layer for iOS: brave/brave-browser#33868.
Resolves brave/brave-browser#42349
Submitter Checklist:
QA/Yes
orQA/No
;release-notes/include
orrelease-notes/exclude
;OS/...
) to the associated issuenpm run test -- brave_browser_tests
,npm run test -- brave_unit_tests
wikinpm run presubmit
wiki,npm run gn_check
,npm run tslint
git rebase master
(if needed)Reviewer Checklist:
gn
After-merge Checklist:
changes has landed on
Test Plan:
No manual testing is required.