com.amanotes.gdk 0.2.60 → 0.2.61
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/CHANGELOG.md +4 -0
- package/Extra/AmaGDKInstaller.unitypackage +0 -0
- package/Extra/CheckDiskSpace.unitypackage +0 -0
- package/Extra/ForceUpdate.unitypackage +0 -0
- package/Extra/PostProcessor.unitypackage +0 -0
- package/Extra/SDKVersionTracking.unitypackage +0 -0
- package/Packages/AmaGDKConfig.unitypackage +0 -0
- package/Packages/AmaGDKExample.unitypackage +0 -0
- package/Packages/AmaGDKTest.unitypackage +0 -0
- package/Packages/AppsFlyerAdapter.unitypackage +0 -0
- package/Packages/FirebaseAnalyticsAdapter.unitypackage +0 -0
- package/Packages/FirebaseRemoteConfigAdapter.unitypackage +0 -0
- package/Packages/IronSourceAdapter.unitypackage +0 -0
- package/Packages/RevenueCatAdapter.unitypackage +0 -0
- package/Packages/SqliteAnalyticsAdapter.unitypackage +0 -0
- package/Runtime/AmaGDK.Analytics.cs +15 -1
- package/Runtime/AmaGDK.cs +1 -1
- package/Runtime/Internal/AmaGDK.Internal.cs +6 -0
- package/Runtime/Klavar/KlavarEvent.cs +9 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.2.61 - 2024-04-25]
|
|
4
|
+
- Add immediate event logging logic
|
|
5
|
+
- [Feature] Improve handling of locked parameters in Klavar
|
|
6
|
+
|
|
3
7
|
## [0.2.60 - 2024-04-23]
|
|
4
8
|
- [Feature] Ensured container's context values remain unchanged
|
|
5
9
|
- [Feature] Check sent funnel event
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -92,6 +92,7 @@ namespace Amanotes.Core
|
|
|
92
92
|
|
|
93
93
|
public static IEventParamsBuilder LogEvent(string eventName)
|
|
94
94
|
{
|
|
95
|
+
ThrowExceptionIfImmediateEvent(eventName);
|
|
95
96
|
var result = PrepareEvent(eventName);
|
|
96
97
|
eventQueue.Enqueue(result);
|
|
97
98
|
return result;
|
|
@@ -99,6 +100,7 @@ namespace Amanotes.Core
|
|
|
99
100
|
|
|
100
101
|
public static IEventParamsBuilder LogEvent(string eventName, Dictionary<string, object> parameters)
|
|
101
102
|
{
|
|
103
|
+
ThrowExceptionIfImmediateEvent(eventName);
|
|
102
104
|
var result = PrepareEvent(eventName, parameters);
|
|
103
105
|
eventQueue.Enqueue(result);
|
|
104
106
|
return result;
|
|
@@ -106,6 +108,7 @@ namespace Amanotes.Core
|
|
|
106
108
|
|
|
107
109
|
public static IEventParamsBuilder LogEvent(string eventName, params (string, object)[] parameters)
|
|
108
110
|
{
|
|
111
|
+
ThrowExceptionIfImmediateEvent(eventName);
|
|
109
112
|
var result = PrepareEvent(eventName, parameters);
|
|
110
113
|
eventQueue.Enqueue(result);
|
|
111
114
|
return result;
|
|
@@ -171,6 +174,12 @@ namespace Amanotes.Core
|
|
|
171
174
|
s.SetUserProperty(key, value);
|
|
172
175
|
}
|
|
173
176
|
}
|
|
177
|
+
|
|
178
|
+
private static void ThrowExceptionIfImmediateEvent(string eventName)
|
|
179
|
+
{
|
|
180
|
+
if (Config.analytics.immediatelyLoggedEvents.Contains(eventName))
|
|
181
|
+
throw new GDKException($"This event '{eventName}' must be sent immediately by AmaGDK.Analytics.LogEventImmediately(eventName, params)");
|
|
182
|
+
}
|
|
174
183
|
|
|
175
184
|
private static IntegrityFlag MergeData(List<string> funnelEvents, Dictionary<string, int> eventCountMap, bool sumEventCount)
|
|
176
185
|
{
|
|
@@ -866,11 +875,15 @@ namespace Amanotes.Core
|
|
|
866
875
|
{
|
|
867
876
|
//Clear() is supported from .Net Standard 2.1
|
|
868
877
|
#if UNITY_2021_3_OR_NEWER
|
|
869
|
-
|
|
878
|
+
savedEventStatsInLastFrame.Clear();
|
|
879
|
+
lastFrameEventStats.Clear();
|
|
870
880
|
#else
|
|
871
881
|
while (savedEventStatsInLastFrame.TryDequeue(out var stat))
|
|
872
882
|
{
|
|
873
883
|
}
|
|
884
|
+
while (lastFrameEventStats.TryDequeue(out var stat))
|
|
885
|
+
{
|
|
886
|
+
}
|
|
874
887
|
#endif
|
|
875
888
|
}
|
|
876
889
|
}
|
|
@@ -1077,6 +1090,7 @@ namespace Amanotes.Core.Internal
|
|
|
1077
1090
|
[HideInInspector] public bool checkMigrationIntegrity = true;
|
|
1078
1091
|
[HideInInspector] public bool migrateAccumulatedCount = true;
|
|
1079
1092
|
[HideInInspector] public bool enableEventStat;
|
|
1093
|
+
[HideInInspector] public List<string> immediatelyLoggedEvents = new List<string>(){"ad_impression", "ad_impression_ama"};
|
|
1080
1094
|
public AnalyticQualityConfig quality;
|
|
1081
1095
|
}
|
|
1082
1096
|
|
package/Runtime/AmaGDK.cs
CHANGED
|
@@ -175,6 +175,12 @@ namespace Amanotes.Core.Internal
|
|
|
175
175
|
analyticsData.cachedEventDetails.Clear();
|
|
176
176
|
analyticsData.migrationLog = new MigrationLog();
|
|
177
177
|
analyticsData.SaveIfDirty();
|
|
178
|
+
sessionStat.Clear();
|
|
179
|
+
#if UNITY_2021_3_OR_NEWER
|
|
180
|
+
eventQueue.Clear();
|
|
181
|
+
#else
|
|
182
|
+
while (eventQueue.TryDequeue(out var stat)){}
|
|
183
|
+
#endif
|
|
178
184
|
}
|
|
179
185
|
}
|
|
180
186
|
|
|
@@ -33,7 +33,15 @@ namespace Amanotes.Core
|
|
|
33
33
|
@params[kvp.Key] = kvp.Value;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
|
-
AmaGDK.
|
|
36
|
+
if (AmaGDK.Config.analytics.immediatelyLoggedEvents.Contains(eventName))
|
|
37
|
+
{
|
|
38
|
+
AmaGDK.Analytics.LogEventImmediately(eventName, @params);
|
|
39
|
+
}
|
|
40
|
+
else
|
|
41
|
+
{
|
|
42
|
+
AmaGDK.Analytics.LogEvent(eventName, @params);
|
|
43
|
+
}
|
|
44
|
+
|
|
37
45
|
}
|
|
38
46
|
|
|
39
47
|
|