Post

Replies

Boosts

Views

Activity

MetricKit histogrammedApplicationResumeTime meaning
Hi! I've implemented collecting MetricKit data for my app. And I don't understand meaning of histogrammedApplicationResumeTime values from appLaunch metric. I explored data and found, that there are can be really huge values – around hours. For example, let's see one data snapshot from real user: It seems unbelievable, that resumeTime takes 10902720ms (1 hour). We've also built a bar chart per percentiles and it looks crazy: p85 – 1030ms | p95 – 1.52 million ms | p99 – 13.2 million ms (3.5 hours) Documentation says: A histogram of the different amounts of time taken to resume the app from the background. For me it sounds like: time between moment, when user launch app, which is in background mode already, to moment, when app comes to foreground stay. But the real data shows that it isn't. Can somebody describe what really means histogrammedApplicationResumeTime metric?
2
1
1.4k
Jun ’22
XCTestCase performance measurement has no results on M1
I want to test app launch performance in my project. Therefore I tried to use performance test with measure func and XCTApplicationLaunchMetric. But after test completion there is no any result with average time. Here is a test example: func testLaunchPerformance() throws {         if #available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 7.0, *) {             // This measures how long it takes to launch your application.             measure(metrics: [XCTApplicationLaunchMetric()]) {                 XCUIApplication().launch()             }         }     } But when I create a new empty project and add the same performance test – it works and shows app launch results. 1st image is a real project test – there is no test result. and the 2nd image is a demo empty project test – it has performance result diagram. I am running test on MacBook with M1 Pro chip. However, when my colleague is running the same performance test on our real project with Intel based MacBook Pro – all is fine, it shows app launch results correctly as my demo project. I have no idea how it can be fixed, because it seems that it depends on M1 chip 🤷🏻‍♂️. May be somebody have a solution?
1
2
1.3k
Jun ’22
TLS Validation Failure
Hi, my application has an NSAllowsArbitraryLoads flag in Info.plist which is set to YES. I want to enable ATS checks and therefore is trying to disable NSAllowsArbitraryLoads option. But I faced with problem. I am completely delete NSAppTransportSecurity section from Info.plist and then run the application. When I use dev stand everything is okay and works good. But since I've switched my application to production stand – any internet connection is failed with following error: 2022-03-30 03:23:17.511459+0300 *[10271:4471591] Connection 77: strict TLS Trust evaluation failed(-9802) 2022-03-30 03:23:17.511549+0300 *[10271:4471591] Connection 77: TLS Trust encountered error 3:-9802 2022-03-30 03:23:17.511629+0300 *[10271:4471591] Connection 77: encountered error(3:-9802) 2022-03-30 03:23:17.512571+0300 *[10271:4471591] Task <4F7E00BD-2CB7-4055-A8DF-69CD9F562800>.<54> HTTP load failed, 0/0 bytes (error code: -1200 [3:-9802]) Error Domain=NSURLErrorDomain Code=-1200 "An SSL error has occurred and a secure connection to the server cannot be made." UserInfo={NSLocalizedRecoverySuggestion=Would you like to connect to the server anyway?, _kCFStreamErrorDomainKey=3, ... // certificate chain I've already red a lot of topics about TLS validation and checked some hypothesis. For example I've checked this: openssl s_client -connect ***.***.com:443 And the returned info is said, that server meets ATS requirements Server public key is 2048 bit Protocol  : TLSv1.2 (ok) Cipher    : ECDHE-RSA-CHACHA20-POLY1305 (ok) Verify return code: 0 (ok) Another interesting point, is that if i use a corporate VPN – everything works perfect even for production stand. But when corporate VPN is switched off – error comes back. The main difference, that i realized – changed certificates list for this cases. Currently I have no idea what's going wrong, because it seems, that backend fully support ATS requirements. Any idea will be great!
1
0
3.0k
Mar ’22