admanagekit-mcp-server 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/content/README.md +851 -0
- package/content/docs/AD_FREQUENCY_CONTROL.md +450 -0
- package/content/docs/AD_LOADING_STRATEGIES.md +369 -0
- package/content/docs/API_REFERENCE.md +734 -0
- package/content/docs/APP_PURCHASE_GUIDE.md +704 -0
- package/content/docs/BANNER_AD_IMPROVEMENTS.md +325 -0
- package/content/docs/COMPOSE_INTEGRATION.md +477 -0
- package/content/docs/CONFIGURATION_USAGE.md +168 -0
- package/content/docs/INTERSTITIAL_BUILDER_GUIDE.md +518 -0
- package/content/docs/JAVA_USAGE_GUIDE.md +785 -0
- package/content/docs/LOADING_STRATEGY_EXAMPLES.md +463 -0
- package/content/docs/NATIVE_AD_MANAGER_ENHANCEMENTS.md +347 -0
- package/content/docs/NATIVE_AD_PRELOADING.md +467 -0
- package/content/docs/NATIVE_TEMPLATE_VIEW.md +413 -0
- package/content/docs/app-open-ads.md +412 -0
- package/content/docs/interstitial-ads.md +269 -0
- package/content/docs/native-ads-caching.md +182 -0
- package/content/docs/release-notes/RELEASE_NOTES_v2.1.0.md +156 -0
- package/content/docs/release-notes/RELEASE_NOTES_v2.2.0.md +248 -0
- package/content/docs/release-notes/RELEASE_NOTES_v2.3.0.md +280 -0
- package/content/docs/release-notes/RELEASE_NOTES_v2.5.0.md +73 -0
- package/content/docs/release-notes/RELEASE_NOTES_v2.6.0.md +265 -0
- package/content/docs/release-notes/RELEASE_NOTES_v2.7.0.md +168 -0
- package/content/docs/release-notes/RELEASE_NOTES_v2.8.0.md +153 -0
- package/content/docs/release-notes/RELEASE_NOTES_v2.9.0.md +479 -0
- package/content/docs/release-notes/RELEASE_NOTES_v3.0.0.md +343 -0
- package/content/docs/release-notes/RELEASE_NOTES_v3.1.0.md +131 -0
- package/content/docs/release-notes/RELEASE_NOTES_v3.3.0.md +252 -0
- package/content/docs/release-notes/RELEASE_NOTES_v3.3.2.md +215 -0
- package/content/docs/release-notes/RELEASE_NOTES_v3.3.3.md +116 -0
- package/content/docs/release-notes/RELEASE_NOTES_v3.3.4.md +142 -0
- package/content/docs/release-notes/RELEASE_NOTES_v3.3.5.md +94 -0
- package/content/docs/rewarded-ads.md +623 -0
- package/content/wiki/Ad-Loading-Strategies.md +209 -0
- package/content/wiki/App-Open-Ads.md +189 -0
- package/content/wiki/Banner-Ads.md +133 -0
- package/content/wiki/Billing-Integration.md +69 -0
- package/content/wiki/Configuration.md +252 -0
- package/content/wiki/Consumable-Products.md +166 -0
- package/content/wiki/Home.md +144 -0
- package/content/wiki/Interstitial-Ads.md +313 -0
- package/content/wiki/Jetpack-Compose.md +270 -0
- package/content/wiki/NativeAdManager.md +220 -0
- package/content/wiki/Purchase-Categories.md +94 -0
- package/content/wiki/Rewarded-Ads.md +420 -0
- package/content/wiki/Subscription-Upgrades.md +278 -0
- package/content/wiki/Subscriptions.md +368 -0
- package/content/wiki/_Footer.md +3 -0
- package/content/wiki/_Sidebar.md +18 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -0
- package/dist/server.d.ts +1 -0
- package/dist/server.js +18 -0
- package/dist/server.js.map +1 -0
- package/dist/tools/code-generation.d.ts +2 -0
- package/dist/tools/code-generation.js +264 -0
- package/dist/tools/code-generation.js.map +1 -0
- package/dist/tools/documentation.d.ts +2 -0
- package/dist/tools/documentation.js +202 -0
- package/dist/tools/documentation.js.map +1 -0
- package/dist/types.d.ts +18 -0
- package/dist/types.js +83 -0
- package/dist/types.js.map +1 -0
- package/dist/utils/doc-loader.d.ts +17 -0
- package/dist/utils/doc-loader.js +245 -0
- package/dist/utils/doc-loader.js.map +1 -0
- package/dist/utils/search.d.ts +2 -0
- package/dist/utils/search.js +62 -0
- package/dist/utils/search.js.map +1 -0
- package/dist/utils/templates.d.ts +60 -0
- package/dist/utils/templates.js +793 -0
- package/dist/utils/templates.js.map +1 -0
- package/package.json +51 -0
|
@@ -0,0 +1,280 @@
|
|
|
1
|
+
# Release Notes - AdManageKit v2.3.0
|
|
2
|
+
|
|
3
|
+
**Release Date:** December 16, 2024
|
|
4
|
+
**Version:** 2.3.0
|
|
5
|
+
**Compatibility:** Android API 21+ | Google Play Billing Library 8.x | Jetpack Compose 2024.12.01
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## 🚀 What's New in v2.3.0
|
|
10
|
+
|
|
11
|
+
### 🐛 **Critical Bug Fixes**
|
|
12
|
+
- **Fixed Native Ad Display Issue** - Resolved critical bug where cached native ads were found but not visually displayed
|
|
13
|
+
- **Enhanced AdChoices Handling** - Improved null AdChoices info handling for test ads
|
|
14
|
+
- **Consistent Logging** - Replaced manual logging with AdDebugUtils for unified debugging experience
|
|
15
|
+
|
|
16
|
+
### 🔧 **Core Improvements**
|
|
17
|
+
|
|
18
|
+
#### **Fixed Cached Ad Display Pipeline**
|
|
19
|
+
The major fix in this release addresses a critical issue where native ads reported successful loading but weren't displayed:
|
|
20
|
+
|
|
21
|
+
**Before (v2.2.0):**
|
|
22
|
+
```
|
|
23
|
+
Cache hit for MainActivity_MEDIUM: serving cached ad
|
|
24
|
+
✅ NativeBannerMedium loaded successfully
|
|
25
|
+
// Ad callback fired but no visual ad appeared
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
**After (v2.3.0):**
|
|
29
|
+
```
|
|
30
|
+
Cache hit for MainActivity_MEDIUM: serving cached ad
|
|
31
|
+
foundCachedAd: Found cached ad from integration manager - displaying it
|
|
32
|
+
✅ NativeBannerMedium loaded successfully
|
|
33
|
+
// Ad now displays visually on screen
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
#### **Enhanced NativeAdIntegrationManager**
|
|
37
|
+
- **Fixed cache serving logic** - Now properly passes cached ads to display layer
|
|
38
|
+
- **Added temporary ad storage** - Enables proper handoff between caching and display
|
|
39
|
+
- **Improved error handling** - Better fallback when cached ad display fails
|
|
40
|
+
|
|
41
|
+
#### **All Native Ad Components Fixed**
|
|
42
|
+
- ✅ **NativeBannerSmall** - Fixed cached ad display
|
|
43
|
+
- ✅ **NativeBannerMedium** - Fixed cached ad display
|
|
44
|
+
- ✅ **NativeLarge** - Fixed cached ad display
|
|
45
|
+
|
|
46
|
+
### 📊 **Enhanced Debugging**
|
|
47
|
+
|
|
48
|
+
#### **Unified AdDebugUtils Integration**
|
|
49
|
+
- **Consistent Event Logging** - All ad events now use `AdDebugUtils.logEvent()`
|
|
50
|
+
- **Structured Debug Output** - Categorized logging with success/failure indicators
|
|
51
|
+
- **Performance Tracking** - Enhanced timing and performance metrics
|
|
52
|
+
- **Clean Error Messages** - Improved error reporting with context
|
|
53
|
+
|
|
54
|
+
#### **Improved AdChoices Logging**
|
|
55
|
+
- **Informative Null Handling** - "AdChoices info: null (normal for test ads)" instead of confusing null
|
|
56
|
+
- **Visual State Tracking** - Detailed view state logging throughout display pipeline
|
|
57
|
+
- **Cache Hit Verification** - Logs confirm when cached ads are found and displayed
|
|
58
|
+
|
|
59
|
+
### 🔧 **Technical Improvements**
|
|
60
|
+
|
|
61
|
+
#### **BillingConfig Enhancements**
|
|
62
|
+
- **Java Interoperability** - Added `@JvmStatic` annotations for better Java integration
|
|
63
|
+
- **Static Method Access** - Java code can now use `BillingConfig.setPurchaseProvider(provider)`
|
|
64
|
+
- **Backward Compatible** - Instance access still works: `BillingConfig.INSTANCE.setPurchaseProvider(provider)`
|
|
65
|
+
|
|
66
|
+
#### **Code Quality Improvements**
|
|
67
|
+
- **Removed Unused Imports** - Cleaned up unused Log imports after AdDebugUtils migration
|
|
68
|
+
- **Consistent TAG Usage** - Unified logging tags across all components
|
|
69
|
+
- **Enhanced Code Documentation** - Better inline comments explaining fixes
|
|
70
|
+
|
|
71
|
+
---
|
|
72
|
+
|
|
73
|
+
## 📦 **Installation**
|
|
74
|
+
|
|
75
|
+
### Gradle Dependencies (Kotlin DSL)
|
|
76
|
+
```kotlin
|
|
77
|
+
implementation("com.github.i2hammad.AdManageKit:ad-manage-kit:v2.3.0")
|
|
78
|
+
implementation("com.github.i2hammad.AdManageKit:ad-manage-kit-billing:v2.3.0")
|
|
79
|
+
implementation("com.github.i2hammad.AdManageKit:ad-manage-kit-core:v2.3.0")
|
|
80
|
+
|
|
81
|
+
// For Jetpack Compose support
|
|
82
|
+
implementation("com.github.i2hammad.AdManageKit:ad-manage-kit-compose:v2.3.0")
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
### Gradle Dependencies (Groovy)
|
|
86
|
+
```groovy
|
|
87
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit:v2.3.0'
|
|
88
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-billing:v2.3.0'
|
|
89
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-core:v2.3.0'
|
|
90
|
+
|
|
91
|
+
// For Jetpack Compose support
|
|
92
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-compose:v2.3.0'
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
---
|
|
96
|
+
|
|
97
|
+
## 🔄 **Migration from v2.2.0**
|
|
98
|
+
|
|
99
|
+
### **Automatic Migration**
|
|
100
|
+
- **✅ Full Backward Compatibility** - All v2.2.0 code works without changes
|
|
101
|
+
- **✅ No Breaking Changes** - All method signatures and behaviors preserved
|
|
102
|
+
- **✅ Immediate Benefits** - Native ad display fixes apply automatically
|
|
103
|
+
|
|
104
|
+
### **No Action Required**
|
|
105
|
+
This is a **bug fix release** - simply update your dependency versions and rebuild. The fixes are automatically applied:
|
|
106
|
+
|
|
107
|
+
```groovy
|
|
108
|
+
// Update these version numbers
|
|
109
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit:v2.3.0' // was v2.2.0
|
|
110
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-billing:v2.3.0' // was v2.2.0
|
|
111
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-core:v2.3.0' // was v2.2.0
|
|
112
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-compose:v2.3.0' // was v2.2.0
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
### **Expected Improvements**
|
|
116
|
+
After updating to v2.3.0, you should immediately see:
|
|
117
|
+
|
|
118
|
+
1. **Native ads displaying visually** (not just success callbacks)
|
|
119
|
+
2. **Cleaner debug logs** with structured event information
|
|
120
|
+
3. **Better error messages** with proper context
|
|
121
|
+
4. **Improved Java interop** if using Java code
|
|
122
|
+
|
|
123
|
+
---
|
|
124
|
+
|
|
125
|
+
## 🐛 **Bug Fixes**
|
|
126
|
+
|
|
127
|
+
### **Critical Fixes**
|
|
128
|
+
- **Native Ad Display** - Fixed critical issue where `NativeAdIntegrationManager` found cached ads but only called callbacks without displaying them
|
|
129
|
+
- **AdChoices Null Handling** - Improved handling of null AdChoices info for test ad units
|
|
130
|
+
- **Cache Display Pipeline** - Fixed disconnect between cache hits and actual visual display
|
|
131
|
+
- **View Lifecycle Management** - Enhanced proper view attachment and visibility handling
|
|
132
|
+
|
|
133
|
+
### **Stability Improvements**
|
|
134
|
+
- **Thread Safety** - Better post-frame execution for view operations
|
|
135
|
+
- **Memory Management** - Improved cleanup of temporary cached ad references
|
|
136
|
+
- **Error Recovery** - Enhanced fallback when cached ad display fails
|
|
137
|
+
- **State Synchronization** - Better coordination between caching and display layers
|
|
138
|
+
|
|
139
|
+
---
|
|
140
|
+
|
|
141
|
+
## 🔍 **Debugging Improvements**
|
|
142
|
+
|
|
143
|
+
### **Enhanced Log Output**
|
|
144
|
+
**Before v2.3.0:**
|
|
145
|
+
```
|
|
146
|
+
D AdManageKit: Cache hit for MainActivity_MEDIUM: serving cached ad
|
|
147
|
+
D AdManageKit: ✅ [47696110] onAdLoaded: NativeBannerMedium loaded successfully
|
|
148
|
+
// Ad not visible - confusing for developers
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
**After v2.3.0:**
|
|
152
|
+
```
|
|
153
|
+
D AdManageKit-Event: foundCachedAd: Found cached ad from integration manager - displaying it
|
|
154
|
+
D AdManageKit-Event: displayCachedAd: Displaying cached/preloaded ad
|
|
155
|
+
D AdManageKit-Event: ✅ [47696110] onAdLoaded: NativeBannerMedium loaded successfully
|
|
156
|
+
// Ad now displays visually with clear debug trail
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
### **Structured Event Categories**
|
|
160
|
+
- **AdDisplay** - View manipulation and visibility events
|
|
161
|
+
- **CacheDisplay** - Cached ad retrieval and display events
|
|
162
|
+
- **AdPopulate** - Native ad content population events
|
|
163
|
+
- **ViewStates** - View hierarchy and layout state information
|
|
164
|
+
- **DisplayVerify** - Final verification of successful ad display
|
|
165
|
+
|
|
166
|
+
---
|
|
167
|
+
|
|
168
|
+
## 📈 **Performance Impact**
|
|
169
|
+
|
|
170
|
+
### **Improvements**
|
|
171
|
+
- **Faster Ad Display** - Eliminated unnecessary callback cycles in cached ad serving
|
|
172
|
+
- **Reduced Log Overhead** - More efficient structured logging vs. multiple Log.d() calls
|
|
173
|
+
- **Better Memory Usage** - Proper cleanup of temporary cached ad references
|
|
174
|
+
- **Fewer Wasted Cycles** - Direct display path for cached ads eliminates redundant processing
|
|
175
|
+
|
|
176
|
+
### **No Performance Degradation**
|
|
177
|
+
- **Same Load Times** - No impact on initial ad loading performance
|
|
178
|
+
- **Same Memory Footprint** - Debug improvements don't affect production memory usage
|
|
179
|
+
- **Same Network Usage** - No changes to ad fetching or caching behavior
|
|
180
|
+
|
|
181
|
+
---
|
|
182
|
+
|
|
183
|
+
## 🧪 **Testing Recommendations**
|
|
184
|
+
|
|
185
|
+
### **Verify the Fixes**
|
|
186
|
+
1. **Visual Verification** - Confirm native ads display on screen (not just success callbacks)
|
|
187
|
+
2. **Cache Hit Testing** - Test rapid navigation to verify cached ads display properly
|
|
188
|
+
3. **Debug Log Review** - Check for cleaner, more structured debug output
|
|
189
|
+
4. **Error Scenarios** - Test ad loading failures for improved error messaging
|
|
190
|
+
|
|
191
|
+
### **Test Scenarios**
|
|
192
|
+
```kotlin
|
|
193
|
+
// Test cached ad display
|
|
194
|
+
nativeBannerMedium.loadNativeBannerAd(activity, adUnitId, useCachedAd = true, callback)
|
|
195
|
+
|
|
196
|
+
// Test new debug output
|
|
197
|
+
AdManageKitConfig.debugMode = true
|
|
198
|
+
// Look for structured AdDebugUtils output in logs
|
|
199
|
+
|
|
200
|
+
// Test Java interop (if using Java)
|
|
201
|
+
BillingConfig.setPurchaseProvider(provider); // Now works in Java
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
---
|
|
205
|
+
|
|
206
|
+
## 🔗 **Dependencies**
|
|
207
|
+
|
|
208
|
+
### **Updated Components**
|
|
209
|
+
All modules updated to v2.3.0:
|
|
210
|
+
- **ad-manage-kit**: Core ad management with display fixes
|
|
211
|
+
- **ad-manage-kit-billing**: Enhanced Java interoperability
|
|
212
|
+
- **ad-manage-kit-core**: BillingConfig improvements
|
|
213
|
+
- **ad-manage-kit-compose**: Consistent with core version
|
|
214
|
+
|
|
215
|
+
### **No New Dependencies**
|
|
216
|
+
This release doesn't add any new dependencies - it's purely a bug fix and enhancement release.
|
|
217
|
+
|
|
218
|
+
---
|
|
219
|
+
|
|
220
|
+
## ⚠️ **Known Issues Fixed**
|
|
221
|
+
|
|
222
|
+
### **Resolved in v2.3.0**
|
|
223
|
+
- ✅ **Native ads reporting success but not displaying** - Fixed
|
|
224
|
+
- ✅ **"AdChoices info: null" appearing as error** - Now informational
|
|
225
|
+
- ✅ **Inconsistent debug logging format** - Now unified with AdDebugUtils
|
|
226
|
+
- ✅ **Java interop issues with BillingConfig** - Fixed with @JvmStatic
|
|
227
|
+
- ✅ **LiveEdit crashes with abstract classes** - Mitigated with proper error handling
|
|
228
|
+
|
|
229
|
+
### **Still Known**
|
|
230
|
+
- **LiveEdit Compatibility** - Android Studio LiveEdit may have issues with abstract classes - restart app to resolve
|
|
231
|
+
|
|
232
|
+
---
|
|
233
|
+
|
|
234
|
+
## 🛠️ **Developer Notes**
|
|
235
|
+
|
|
236
|
+
### **For Existing Users**
|
|
237
|
+
- **Update is Recommended** - This fixes critical display issues that may affect user experience
|
|
238
|
+
- **Zero Code Changes** - Update dependency versions and rebuild
|
|
239
|
+
- **Immediate Benefits** - Native ads will display properly without any code changes
|
|
240
|
+
|
|
241
|
+
### **For New Users**
|
|
242
|
+
- **Start with v2.3.0** - This version includes all Compose support plus critical bug fixes
|
|
243
|
+
- **Stable Foundation** - Built on the solid v2.2.0 base with important display fixes
|
|
244
|
+
- **Full Feature Set** - Complete Jetpack Compose integration with reliable native ad display
|
|
245
|
+
|
|
246
|
+
---
|
|
247
|
+
|
|
248
|
+
## 🔮 **What's Next**
|
|
249
|
+
|
|
250
|
+
### **Upcoming Features (v2.5.0 Preview)**
|
|
251
|
+
- **Enhanced Subscription Management** - Advanced offer handling and discount management
|
|
252
|
+
- **App Open Ad Compose** - Complete Compose support for app open ads
|
|
253
|
+
- **Rewarded Ad Compose** - Declarative rewarded ad integration
|
|
254
|
+
- **Advanced Analytics Dashboard** - Real-time ad performance monitoring
|
|
255
|
+
- **A/B Testing Framework** - Built-in ad performance optimization
|
|
256
|
+
|
|
257
|
+
### **Community Feedback**
|
|
258
|
+
This release addresses critical user feedback about native ad display issues. Please continue reporting issues:
|
|
259
|
+
- **GitHub Issues**: [AdManageKit Issues](https://github.com/i2hammad/AdManageKit/issues)
|
|
260
|
+
- **Discussions**: [AdManageKit Discussions](https://github.com/i2hammad/AdManageKit/discussions)
|
|
261
|
+
|
|
262
|
+
---
|
|
263
|
+
|
|
264
|
+
## 💝 **Acknowledgments**
|
|
265
|
+
|
|
266
|
+
Special thanks to the developers who reported the native ad display issues that led to this critical fix. Your detailed bug reports and testing feedback made this release possible.
|
|
267
|
+
|
|
268
|
+
---
|
|
269
|
+
|
|
270
|
+
## 📄 **Full Documentation**
|
|
271
|
+
|
|
272
|
+
- **[README.md](README.md)** - Updated integration guide with v2.3.0 information
|
|
273
|
+
- **[API Documentation](https://jitpack.io/com/github/i2hammad/AdManageKit/v2.3.0/javadoc/)** - Complete API reference
|
|
274
|
+
- **[Migration Guide](README.md#migrating-to-23)** - Simple version update instructions
|
|
275
|
+
- **[Compose Examples](app/)** - Working examples in the demo app
|
|
276
|
+
|
|
277
|
+
**Download AdManageKit v2.3.0**: [](https://jitpack.io/#i2hammad/AdManageKit)
|
|
278
|
+
|
|
279
|
+
---
|
|
280
|
+
*AdManageKit v2.3.0 - Now your cached native ads actually display! 🎯*
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# Release Notes - AdManageKit v2.5.0
|
|
2
|
+
|
|
3
|
+
**Release Date:** October 31, 2025
|
|
4
|
+
**Version:** 2.5.0
|
|
5
|
+
**Compatibility:** Android API 21+ | Google Play Billing Library 8.x | Jetpack Compose 2024.12.01
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## 🚀 What's New in v2.5.0
|
|
10
|
+
|
|
11
|
+
### 🛡️ App Open Stability Overhaul
|
|
12
|
+
- **Thread-Safe Lifecycle:** `AppOpenManager` now relies on `AtomicBoolean`, `AtomicInteger`, and `WeakReference` state to prevent race conditions and memory leaks when activities rotate or background.
|
|
13
|
+
- **Smarter Activity Exclusion:** Adds a fast-path cache for excluded activities and uses `cleanup()` to unregister lifecycle callbacks when the manager is no longer needed.
|
|
14
|
+
- **Force & Conditional Showing:** `forceShowAdIfAvailable()` and the new `canShowAd()` helper guard against duplicate displays and return actionable reasons when an ad cannot be shown.
|
|
15
|
+
- **Lifecycle-Ready Cleanup:** `cleanup()` resets cached state, cancels pending timeouts, clears load metrics, and unregisters callbacks to avoid leaks on process shutdown.
|
|
16
|
+
|
|
17
|
+
### 📡 Intelligent Retry & Circuit Breaking
|
|
18
|
+
- **Exponential Backoff:** `fetchAdWithRetry()` automatically retries network and no-fill failures using configurable exponential backoff (`updateRetryConfiguration`).
|
|
19
|
+
- **Circuit Breaker Integration:** Tracks consecutive failures, opens a circuit breaker based on `AdManageKitConfig.circuitBreakerThreshold`, and auto-resets after the configured cooldown.
|
|
20
|
+
- **Load Analytics:** `getPerformanceMetrics()` surfaces average load time, failure counts, and current breaker state for dashboards or support tooling.
|
|
21
|
+
- **Robust Timeout Handling:** All pending timeouts are tracked and cancelled safely, ensuring callbacks never fire after a manager is cleaned up.
|
|
22
|
+
|
|
23
|
+
### 🧠 Smarter Native Ad Fallback
|
|
24
|
+
- **Same-Unit Cache Fallback:** `NativeAdManager.getCachedNativeAd()` now reuses cached ads that were fetched with the same ad unit ID (including screen-specific suffixes) when the primary cache bucket is empty.
|
|
25
|
+
- **Automatic Adoption:** `NativeBannerSmall`, `NativeBannerMedium`, and `NativeLarge` opt into the safe fallback path, improving cache hit rates after connectivity hiccups without crossing placements.
|
|
26
|
+
- **Analytics Visibility:** Fallback serves are logged with detailed analytics, making it easy to observe cache performance in Firebase.
|
|
27
|
+
|
|
28
|
+
### 💳 Billing & Sample Improvements
|
|
29
|
+
- **Billing Control Surface:** `AppPurchase` exposes `isBillingAvailable` and `connectToGooglePlayBilling()` so apps can manually reconnect or surface billing state.
|
|
30
|
+
- **Sample App Hardening:** `SplashActivity` now checks `AppOpenManager.isShowingAd()` before navigating to prevent duplicate navigation while app open ads display.
|
|
31
|
+
- **Documentation Fixes:** Updated README examples align `onProductPurchased` with the real callback signature.
|
|
32
|
+
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
## 📦 Installation
|
|
36
|
+
|
|
37
|
+
### Gradle Dependencies (Kotlin DSL)
|
|
38
|
+
```kotlin
|
|
39
|
+
implementation("com.github.i2hammad.AdManageKit:ad-manage-kit:v2.5.0")
|
|
40
|
+
implementation("com.github.i2hammad.AdManageKit:ad-manage-kit-billing:v2.5.0")
|
|
41
|
+
implementation("com.github.i2hammad.AdManageKit:ad-manage-kit-core:v2.5.0")
|
|
42
|
+
implementation("com.github.i2hammad.AdManageKit:ad-manage-kit-compose:v2.5.0")
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
### Gradle Dependencies (Groovy)
|
|
46
|
+
```groovy
|
|
47
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit:v2.5.0'
|
|
48
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-billing:v2.5.0'
|
|
49
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-core:v2.5.0'
|
|
50
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-compose:v2.5.0'
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
## 🔄 Migration from v2.3.0
|
|
56
|
+
|
|
57
|
+
- **Drop-In Upgrade:** No breaking API changes. Existing integrations continue to work after bumping the dependency version.
|
|
58
|
+
- **Optional Tuning:** Call `AppOpenManager.updateRetryConfiguration()` if you want to customize retry counts, base delay, or multipliers.
|
|
59
|
+
- **Manual Cleanup:** If you create multiple `AppOpenManager` instances, invoke `cleanup()` when an instance is no longer needed to free lifecycle callbacks promptly.
|
|
60
|
+
- **Native Cache Fallback:** The new same-unit fallback behaviour is on by default for bundled widgets; you can opt out by passing `useCachedAd = false` or disabling caching via `AdManageKitConfig`.
|
|
61
|
+
|
|
62
|
+
---
|
|
63
|
+
|
|
64
|
+
## 🧪 Testing Recommendations
|
|
65
|
+
|
|
66
|
+
1. **Cold Start Flow:** Launch from a cold start repeatedly to verify app open ads respect the circuit breaker and never double-display.
|
|
67
|
+
2. **Network Failure Drills:** Simulate offline/no-fill scenarios to confirm exponential backoff scheduling and circuit breaker logging.
|
|
68
|
+
3. **Native Cache Coverage:** Toggle airplane mode after initial load to ensure fallback cached ads render across banners, medium, and large placements.
|
|
69
|
+
4. **Billing Reconnections:** Force-stop Google Play services or revoke billing to validate manual `connectToGooglePlayBilling()` recovery paths.
|
|
70
|
+
|
|
71
|
+
---
|
|
72
|
+
|
|
73
|
+
AdManageKit v2.5.0 focuses on resiliency: tougher app open delivery, smarter native caching, and clearer billing controls so monetization keeps flowing even under adverse conditions.
|
|
@@ -0,0 +1,265 @@
|
|
|
1
|
+
# AdManageKit v2.6.0 Release Notes
|
|
2
|
+
|
|
3
|
+
**Release Date:** November 27, 2024
|
|
4
|
+
|
|
5
|
+
## Highlights
|
|
6
|
+
|
|
7
|
+
This release introduces **NativeTemplateView** - a unified native ad component supporting 17 different template styles, **Ad Loading Strategies** for fine-grained control over ad loading behavior, and comprehensive **Material 3 theme support** for automatic dark/light mode.
|
|
8
|
+
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
## New Features
|
|
12
|
+
|
|
13
|
+
### NativeTemplateView
|
|
14
|
+
|
|
15
|
+
A single, flexible component that replaces the need for multiple native ad views.
|
|
16
|
+
|
|
17
|
+
**17 Template Styles:**
|
|
18
|
+
|
|
19
|
+
| Standard Templates | Video Templates |
|
|
20
|
+
|-------------------|-----------------|
|
|
21
|
+
| card_modern | video_small |
|
|
22
|
+
| material3 | video_medium |
|
|
23
|
+
| minimal | video_large |
|
|
24
|
+
| compact_horizontal | video_square |
|
|
25
|
+
| full_width_banner | video_vertical |
|
|
26
|
+
| list_item | video_fullscreen |
|
|
27
|
+
| grid_card | |
|
|
28
|
+
| featured | |
|
|
29
|
+
| overlay_dark | |
|
|
30
|
+
| story_style | |
|
|
31
|
+
| magazine | |
|
|
32
|
+
|
|
33
|
+
**Usage:**
|
|
34
|
+
|
|
35
|
+
```xml
|
|
36
|
+
<com.i2hammad.admanagekit.admob.NativeTemplateView
|
|
37
|
+
android:id="@+id/nativeTemplateView"
|
|
38
|
+
android:layout_width="match_parent"
|
|
39
|
+
android:layout_height="wrap_content"
|
|
40
|
+
app:adTemplate="material3" />
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
```kotlin
|
|
44
|
+
// Programmatic usage
|
|
45
|
+
nativeTemplateView.setTemplate(NativeAdTemplate.MAGAZINE)
|
|
46
|
+
nativeTemplateView.loadNativeAd(activity, adUnitId)
|
|
47
|
+
|
|
48
|
+
// With loading strategy override
|
|
49
|
+
nativeTemplateView.loadNativeAd(activity, adUnitId, callback, AdLoadingStrategy.ONLY_CACHE)
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
**Features:**
|
|
53
|
+
- XML attribute support (`app:adTemplate`)
|
|
54
|
+
- Programmatic template switching
|
|
55
|
+
- XML Preview in Android Studio designer
|
|
56
|
+
- Shimmer loading animation
|
|
57
|
+
- Integration with NativeAdManager caching
|
|
58
|
+
|
|
59
|
+
---
|
|
60
|
+
|
|
61
|
+
### Ad Loading Strategies
|
|
62
|
+
|
|
63
|
+
Three strategies to control how ads are loaded and displayed:
|
|
64
|
+
|
|
65
|
+
| Strategy | Behavior | Interstitial | App Open | Native |
|
|
66
|
+
|----------|----------|:------------:|:--------:|:------:|
|
|
67
|
+
| `ON_DEMAND` | Always fetch fresh ad with loading dialog | ✅ | ✅ | ✅ |
|
|
68
|
+
| `ONLY_CACHE` | Instant display from cache, skip if unavailable | ✅ | ✅ | ❌ |
|
|
69
|
+
| `HYBRID` | Check cache first, fetch if needed (recommended) | ✅ | ✅ | ✅ |
|
|
70
|
+
|
|
71
|
+
> **Note:** `ONLY_CACHE` is only available for Interstitial and App Open ads. Native ads display inline with shimmer loading, so they always load content.
|
|
72
|
+
|
|
73
|
+
**Configuration:**
|
|
74
|
+
|
|
75
|
+
```kotlin
|
|
76
|
+
AdManageKitConfig.apply {
|
|
77
|
+
interstitialLoadingStrategy = AdLoadingStrategy.HYBRID
|
|
78
|
+
appOpenLoadingStrategy = AdLoadingStrategy.HYBRID
|
|
79
|
+
nativeLoadingStrategy = AdLoadingStrategy.HYBRID // ON_DEMAND or HYBRID only
|
|
80
|
+
}
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
See [Ad Loading Strategies Guide](docs/AD_LOADING_STRATEGIES.md) for detailed documentation.
|
|
84
|
+
|
|
85
|
+
---
|
|
86
|
+
|
|
87
|
+
### Material 3 Theme Support
|
|
88
|
+
|
|
89
|
+
All templates now use Material 3 theme attributes for automatic dark/light mode support:
|
|
90
|
+
|
|
91
|
+
- `?attr/colorSurface` - Background
|
|
92
|
+
- `?attr/colorOnSurface` - Primary text
|
|
93
|
+
- `?attr/colorOnSurfaceVariant` - Secondary text
|
|
94
|
+
- `?attr/colorPrimary` - CTA button
|
|
95
|
+
- `?attr/colorOutlineVariant` - Borders, dividers
|
|
96
|
+
|
|
97
|
+
No configuration needed - templates automatically adapt to your app's theme.
|
|
98
|
+
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
### Enhanced Video Ad Support
|
|
102
|
+
|
|
103
|
+
- **Minimum 120dp MediaView**: All templates support video ads with proper sizing
|
|
104
|
+
- **6 Video-Optimized Templates**: Designed specifically for video ad content
|
|
105
|
+
- **Proper Aspect Ratios**: Square, vertical, and fullscreen options
|
|
106
|
+
|
|
107
|
+
---
|
|
108
|
+
|
|
109
|
+
## Improvements
|
|
110
|
+
|
|
111
|
+
### Smart View Handling
|
|
112
|
+
|
|
113
|
+
- **GONE vs INVISIBLE**: Views now use `GONE` instead of `INVISIBLE` when content is missing, ensuring proper layout reflow
|
|
114
|
+
- **Container Auto-Hide**: Advertiser container automatically hides when both advertiser name and star rating are null
|
|
115
|
+
- **Proper Alignment**: RelativeLayout ensures correct alignment when optional items are missing
|
|
116
|
+
|
|
117
|
+
### AdChoices Support
|
|
118
|
+
|
|
119
|
+
- Automatic visibility handling for AdChoices view
|
|
120
|
+
- Hidden by default, shown when ad has AdChoices content
|
|
121
|
+
|
|
122
|
+
### Jetpack Compose Support
|
|
123
|
+
|
|
124
|
+
New Compose components for NativeTemplateView and loading strategies:
|
|
125
|
+
|
|
126
|
+
**NativeTemplateCompose:**
|
|
127
|
+
```kotlin
|
|
128
|
+
// Use any of 17 templates in Compose
|
|
129
|
+
NativeTemplateCompose(
|
|
130
|
+
adUnitId = "ca-app-pub-xxx/yyy",
|
|
131
|
+
template = NativeAdTemplate.MATERIAL3,
|
|
132
|
+
loadingStrategy = AdLoadingStrategy.HYBRID,
|
|
133
|
+
onAdLoaded = { /* success */ }
|
|
134
|
+
)
|
|
135
|
+
|
|
136
|
+
// Convenience functions for common templates
|
|
137
|
+
NativeCardModernCompose(adUnitId = adUnitId)
|
|
138
|
+
NativeMaterial3Compose(adUnitId = adUnitId)
|
|
139
|
+
NativeMinimalCompose(adUnitId = adUnitId)
|
|
140
|
+
NativeListItemCompose(adUnitId = adUnitId)
|
|
141
|
+
NativeMagazineCompose(adUnitId = adUnitId)
|
|
142
|
+
NativeFeaturedCompose(adUnitId = adUnitId)
|
|
143
|
+
NativeVideoMediumCompose(adUnitId = adUnitId)
|
|
144
|
+
NativeVideoLargeCompose(adUnitId = adUnitId)
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
**Loading Strategy Support in Existing Compose Components:**
|
|
148
|
+
```kotlin
|
|
149
|
+
// All native ad Compose functions now support loadingStrategy parameter
|
|
150
|
+
NativeBannerSmallCompose(
|
|
151
|
+
adUnitId = adUnitId,
|
|
152
|
+
loadingStrategy = AdLoadingStrategy.ONLY_CACHE
|
|
153
|
+
)
|
|
154
|
+
|
|
155
|
+
NativeBannerMediumCompose(
|
|
156
|
+
adUnitId = adUnitId,
|
|
157
|
+
loadingStrategy = AdLoadingStrategy.HYBRID
|
|
158
|
+
)
|
|
159
|
+
|
|
160
|
+
NativeLargeCompose(
|
|
161
|
+
adUnitId = adUnitId,
|
|
162
|
+
loadingStrategy = AdLoadingStrategy.ON_DEMAND
|
|
163
|
+
)
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
### XML Preview
|
|
167
|
+
|
|
168
|
+
- `NativeTemplateView` shows actual template layout in Android Studio designer
|
|
169
|
+
- Preview displays placeholder data instead of shimmer
|
|
170
|
+
- Helps visualize ad placement during development
|
|
171
|
+
|
|
172
|
+
---
|
|
173
|
+
|
|
174
|
+
## Bug Fixes
|
|
175
|
+
|
|
176
|
+
### Splash Screen Offline Mode Fix
|
|
177
|
+
|
|
178
|
+
**Issue:** App would get stuck on splash screen when device is offline
|
|
179
|
+
- UMP consent request failed with "Error making request"
|
|
180
|
+
- `canRequestAds()` returned `false`
|
|
181
|
+
- No fallback path existed, causing the app to freeze
|
|
182
|
+
|
|
183
|
+
**Fix:** Added fallback navigation when ads cannot be requested, allowing the app to proceed to the next screen in offline mode.
|
|
184
|
+
|
|
185
|
+
### Native Ad View Fixes
|
|
186
|
+
|
|
187
|
+
- Fixed duplicate `starRatingView` assignment
|
|
188
|
+
- Removed unused `priceView` and `storeView` references
|
|
189
|
+
- Fixed hardcoded "4.5" rating text in material3 template
|
|
190
|
+
- Improved star rating check (now checks `starRating > 0`)
|
|
191
|
+
|
|
192
|
+
---
|
|
193
|
+
|
|
194
|
+
## Breaking Changes
|
|
195
|
+
|
|
196
|
+
None. This release is fully backward compatible. Existing `NativeBannerSmall`, `NativeBannerMedium`, and `NativeLarge` views continue to work as expected.
|
|
197
|
+
|
|
198
|
+
---
|
|
199
|
+
|
|
200
|
+
## Migration Guide
|
|
201
|
+
|
|
202
|
+
### Optional: Adopt NativeTemplateView
|
|
203
|
+
|
|
204
|
+
```kotlin
|
|
205
|
+
// Old way (still works)
|
|
206
|
+
val nativeBannerMedium = NativeBannerMedium(context)
|
|
207
|
+
nativeBannerMedium.loadNativeBannerAd(activity, adUnitId)
|
|
208
|
+
|
|
209
|
+
// New unified approach
|
|
210
|
+
val nativeTemplateView = NativeTemplateView(context)
|
|
211
|
+
nativeTemplateView.setTemplate(NativeAdTemplate.CARD_MODERN)
|
|
212
|
+
nativeTemplateView.loadNativeAd(activity, adUnitId)
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
### Optional: Configure Loading Strategies
|
|
216
|
+
|
|
217
|
+
```kotlin
|
|
218
|
+
// In Application.onCreate()
|
|
219
|
+
AdManageKitConfig.apply {
|
|
220
|
+
interstitialLoadingStrategy = AdLoadingStrategy.HYBRID
|
|
221
|
+
appOpenLoadingStrategy = AdLoadingStrategy.HYBRID
|
|
222
|
+
nativeLoadingStrategy = AdLoadingStrategy.HYBRID
|
|
223
|
+
}
|
|
224
|
+
```
|
|
225
|
+
|
|
226
|
+
---
|
|
227
|
+
|
|
228
|
+
## Dependencies
|
|
229
|
+
|
|
230
|
+
No dependency changes in this release.
|
|
231
|
+
|
|
232
|
+
---
|
|
233
|
+
|
|
234
|
+
## Documentation
|
|
235
|
+
|
|
236
|
+
- [NativeTemplateView Guide](docs/NATIVE_TEMPLATE_VIEW.md)
|
|
237
|
+
- [Ad Loading Strategies Guide](docs/AD_LOADING_STRATEGIES.md)
|
|
238
|
+
- [README](README.md)
|
|
239
|
+
|
|
240
|
+
---
|
|
241
|
+
|
|
242
|
+
## Installation
|
|
243
|
+
|
|
244
|
+
```groovy
|
|
245
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit:v2.6.0'
|
|
246
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-billing:v2.6.0'
|
|
247
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-core:v2.6.0'
|
|
248
|
+
|
|
249
|
+
// For Jetpack Compose support
|
|
250
|
+
implementation 'com.github.i2hammad.AdManageKit:ad-manage-kit-compose:v2.6.0'
|
|
251
|
+
```
|
|
252
|
+
|
|
253
|
+
---
|
|
254
|
+
|
|
255
|
+
## What's Next
|
|
256
|
+
|
|
257
|
+
- Additional template styles based on user feedback
|
|
258
|
+
- Compose support for NativeTemplateView
|
|
259
|
+
- Enhanced analytics for loading strategies
|
|
260
|
+
|
|
261
|
+
---
|
|
262
|
+
|
|
263
|
+
## Feedback
|
|
264
|
+
|
|
265
|
+
For issues or feature requests, please open an issue on [GitHub](https://github.com/i2hammad/AdManageKit/issues).
|