| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
!4960 merge fix/mst-db-isolation into master fix(ans): fix cross-SO singleton issue by adding AnsNotification::GetInstance() Created-by: cheerful_ricky Commit-by: CheerfulRicky Merged-by: openharmony_ci Description: ## Problem DelayedSingleton<AnsNotification>::GetInstance() returns different singleton objects in different shared libraries because the template's static members (instance_, mutex_) have vague linkage (COMDAT) and are hidden per-SO by -fvisibility=hidden + version scripts. ## Solution 1. **Add AnsNotification::GetInstance()** using function-local static (C++11 thread-safe, defined out-of-line in ans_notification.cpp within libans_innerkits, symbol exported via *Ans* in .map) 2. **Replace ALL callers** (NAPI/ANI/Tools/Tests/CJ FFI) from DelayedSingleton<AnsNotification>::GetInstance() to AnsNotification::GetInstance() 3. **Clean up** #include singleton.h from files that no longer use DelayedSingleton (kept in ans_manager_death_recipient.h and pixelmap_cache_manager.h which still use DelayedSingleton as base class) ## Why it works The function-local static in ans_notification.cpp lives in libans_innerkits.so's data segment. AnsNotification::GetInstance() is a non-inline member function compiled only in libans_innerkits.so and exported via *Ans* pattern in libans_innerkits.map. All SOs call this exported function through dynamic linking, sharing the single instance. ## Verification Syntax-checked key files with exact ninja build flags: ans_notification.cpp, notification_helper.cpp, ans_manager_death_recipient.cpp, napi_cancel.cpp, ani_cance.cpp, notification_manager_impl.cpp (CJ FFI), notification_shell_command.cpp (Tools) — all passed. Co-Authored-By: Agent See merge request: openharmony/notification_distributed_notification_service!4960 | 8 小时前 | |
Merge branch 'fix/null-check-stability' of git@gitcode.com:stepend98/notification_distributed_notification_service.git into 'master' # Conflicts: # conflict services/ans/src/advanced_notification_service_ability.cpp # conflict services/ans/test/unittest/notification_preferences_test.cpp | 2 天前 | |
!4886 merge feat/rom-size-optimization into master feat(rom-size): ROM size optimization phase 1 - build config and symbol visibility Created-by: cheerful_ricky Commit-by: CheerfulRicky Merged-by: openharmony_ci Description: ## ROM Size Optimization Phase 1 ### 变更内容 Phase 1 of ROM size optimization (target: 30% reduction, baseline 7963KB). All changes are limited to BUILD.gn/.gni/.map files, no .cpp/.h modifications. ### Key changes - Add notification_size_opt_cflags/ldflags public variables in notification.gni - Add -fno-rtti/-flto/-Bsymbolic/-fno-exceptions config to all production targets - Extract ANI sts_*.cpp (21 files) to ohos_shared_library notification_ani_common - Extract NAPI common*.cpp (12 files) to ohos_shared_library notification_napi_common - Tighten libans_innerkits.map from global:* to class-name-based export (2366 -> ~400 symbols) - Add version_script to 6 NAPI .so (export only napi_module) - Add version_script to 4 ANI .so (export only ANI_Constructor) - Feature-gate clone source files with conditional sources - Add distributed_notification_service_feature_clone flag ### 实测优化效果 - Baseline: 7,963 KB (26 .so files) - After: 7,324 KB (28 .so files, including 2 new common libraries) - Net reduction: 639 KB (8.0%) ### 编译验证 - Local build: PASS (rk3568, distributed_notification_service) Co-Authored-By: Agent See merge request: openharmony/notification_distributed_notification_service!4886 | 22 天前 | |
AnsDialogCallback IDL化整改 Signed-off-by: zhengzhuolan <zhengzhuolan@huawei-partners.com> | 1 年前 | |
add subscribeNotification Signed-off-by: bettykico <fangxiaofen1@h-partners.com> | 17 天前 | |
ans operation callback Signed-off-by: zhengzhuolan <zhengzhuolan@huawei-partners.com> | 1 年前 | |
Ans异步化-Badge-GetNtf Signed-off-by: yangjun <yangjun273@huawei.com> | 8 个月前 | |
Add aggregation notification feature with classification and switch support Signed-off-by: stepend98 <yangjun273@huawei.com> Co-Authored-By: Agent | 2 个月前 | |
AnsSubscriberLocalLiveView IDL整改 Signed-off-by: zhengzhuolan <zhengzhuolan@huawei-partners.com> | 1 年前 | |
add getbadgenumber Signed-off-by: wangdi <wangdi154@huawei.com> | 8 个月前 | |
SwingCallBack_0311A Signed-off-by: zhengzhuolan <zhengzhuolan@huawei-partners.com> | 1 年前 | |
feat(rom-size): ROM size optimization phase 1 - build config and symbol visibility Phase 1 of ROM size optimization (target: 30% reduction, baseline 7963KB). All changes are limited to BUILD.gn/.gni/.map files, no .cpp/.h modifications. Key changes: - Add notification_size_opt_cflags/ldflags public variables in notification.gni - Add -fno-rtti/-flto/-Bsymbolic/-fno-exceptions config to all production targets - Extract ANI sts_*.cpp (21 files) to ohos_shared_library notification_ani_common - Extract NAPI common*.cpp (12 files) to ohos_shared_library notification_napi_common - Tighten libans_innerkits.map from global:* to class-name-based export - Add version_script to 6 NAPI .so (export only napi_module) - Add version_script to 4 ANI .so (export only ANI_Constructor) - Feature-gate priority_notification/clone/geofence source files - Add distributed_notification_service_feature_clone flag Expected benefit: 500-1100KB reduction. Co-Authored-By: Agent Signed-off-by: CheerfulRicky <yuegang7@h-partners.com> Change-Id: I029559a06708665662b1d2f9b7f66dcae53ee96f Signed-off-by: CheerfulRicky <yuegang7@h-partners.com> | 25 天前 |
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
| 8 小时前 | ||
| 2 天前 | ||
| 22 天前 | ||
| 1 年前 | ||
| 17 天前 | ||
| 1 年前 | ||
| 8 个月前 | ||
| 2 个月前 | ||
| 1 年前 | ||
| 8 个月前 | ||
| 1 年前 | ||
| 25 天前 |