You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by ji...@apache.org on 2020/06/17 11:12:00 UTC
[incubator-weex] branch master updated: [iOS] add air tag for
performance log
This is an automated email from the ASF dual-hosted git repository.
jianhan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-weex.git
The following commit(s) were added to refs/heads/master by this push:
new 14aaa91 [iOS] add air tag for performance log
new 0b6be92 Merge pull request #3227 from jianhan-he/master
14aaa91 is described below
commit 14aaa91924862c091389a9de9e6abe02efc29b52
Author: linghe.lh <li...@alibaba-inc.com>
AuthorDate: Thu Jun 11 19:17:29 2020 +0800
[iOS] add air tag for performance log
---
ios/sdk/WeexSDK/Sources/Monitor/WXExceptionUtils.m | 3 +++
ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.h | 3 ++-
ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.m | 9 +++++----
3 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/ios/sdk/WeexSDK/Sources/Monitor/WXExceptionUtils.m b/ios/sdk/WeexSDK/Sources/Monitor/WXExceptionUtils.m
index c913d33..b758176 100644
--- a/ios/sdk/WeexSDK/Sources/Monitor/WXExceptionUtils.m
+++ b/ios/sdk/WeexSDK/Sources/Monitor/WXExceptionUtils.m
@@ -82,6 +82,9 @@ static NSMutableDictionary *recordExceptionHistory = nil;
}
[extInfo setObject:bundleTemplateCommit forKey:@"wxTemplateOfBundle"];
[extInfo setObject:[instance.apmInstance templateInfo] forKey:@"templateInfo"];
+ if (instance.apmInstance.airInfo) {
+ [extInfo setObject:instance.apmInstance.airInfo forKey:KEY_PAGE_PROPERTIES_AIR_TAG];
+ }
NSNumber* pageStartTime = [instance.apmInstance.stageDic objectForKey:KEY_PAGE_STAGES_DOWN_BUNDLE_START];
if (nil == pageStartTime) {
pageStartTime = [instance.apmInstance.stageDic objectForKey:KEY_PAGE_STAGES_RENDER_ORGIGIN];
diff --git a/ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.h b/ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.h
index 990f7a0..7ed92fe 100644
--- a/ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.h
+++ b/ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.h
@@ -34,7 +34,7 @@ extern NSString* const KEY_PAGE_PROPERTIES_JSLIB_VERSION;
extern NSString* const KEY_PAGE_PROPERTIES_WEEX_VERSION;
extern NSString* const KEY_PAGE_PROPERTIES_REQUEST_TYPE;
extern NSString* const KEY_PAGE_PROPERTIES_Z_CACHE_INFO;
-extern NSString* const KEY_PAGE_PROPERTIES_GREY_BUNDLE;
+extern NSString* const KEY_PAGE_PROPERTIES_AIR_TAG;
extern NSString* const KEY_PAGE_PROPERTIES_JS_FM_INIT;
extern NSString* const KEY_PAGE_PROPERTIES_BUNDLE_TYPE;
extern NSString* const KEY_PAGE_PROPERTIES_CONTAINER_NAME;
@@ -125,6 +125,7 @@ extern NSString* const VALUE_ERROR_CODE_DEFAULT;
@property (nonatomic, assign) BOOL isDownLoadFailed;
@property (nonatomic, assign) BOOL forceStopRecordInteractionTime;
@property (nonatomic,assign) double pageRatio;
+@property (nonatomic, copy) NSString* airInfo;
@property (nonatomic,strong) NSMutableDictionary<NSString*,NSNumber*>* recordStatsMap;
@property (nonatomic,strong) NSMutableDictionary<NSString*,NSNumber*>* recordStageMap;
diff --git a/ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.m b/ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.m
index ad9f01b..712afd0 100644
--- a/ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.m
+++ b/ios/sdk/WeexSDK/Sources/Performance/WXApmForInstance.m
@@ -44,7 +44,7 @@ NSString* const KEY_PAGE_PROPERTIES_JSLIB_VERSION = @"wxJSLibVersion";
NSString* const KEY_PAGE_PROPERTIES_WEEX_VERSION = @"wxSDKVersion";
NSString* const KEY_PAGE_PROPERTIES_REQUEST_TYPE = @"wxRequestType";
NSString* const KEY_PAGE_PROPERTIES_Z_CACHE_INFO = @"wxZCacheInfo";
-NSString* const KEY_PAGE_PROPERTIES_GREY_BUNDLE = @"wxGreyBundle";
+NSString* const KEY_PAGE_PROPERTIES_AIR_TAG = @"wxAirTag";
NSString* const KEY_PAGE_PROPERTIES_JS_FM_INIT = @"wxJsFrameworkInit";
NSString* const KEY_PAGE_PROPERTIES_BUNDLE_TYPE = @"wxBundleType";
NSString* const KEY_PAGE_PROPERTIES_CONTAINER_NAME = @"wxContainerName";
@@ -441,9 +441,10 @@ NSString* const VALUE_ERROR_CODE_DEFAULT = @"0";
return;
}
- id wxGreyBundle = [extInfo objectForKey:KEY_PAGE_PROPERTIES_GREY_BUNDLE];
- if (nil != wxGreyBundle && [wxGreyBundle isKindOfClass:NSString.class]) {
- [self setProperty:KEY_PAGE_PROPERTIES_GREY_BUNDLE withValue:wxGreyBundle];
+ id wxAirTag = [extInfo objectForKey:KEY_PAGE_PROPERTIES_AIR_TAG];
+ if (nil != wxAirTag && [wxAirTag isKindOfClass:NSString.class]) {
+ [self setProperty:KEY_PAGE_PROPERTIES_AIR_TAG withValue:wxAirTag];
+ _airInfo = wxAirTag;
}
id wxRequestType = [extInfo objectForKey:KEY_PAGE_PROPERTIES_REQUEST_TYPE];