In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly analyzes the relevant knowledge of what are the six common causes of App collapse, the content is detailed and easy to understand, the operation details are reasonable, and has a certain reference value. If you are interested, you might as well follow the editor and learn more about "what are the six common causes of App collapse".
People hate application crashes, especially when they slow down or get stuck for a few seconds. According to a survey by Dimensional Research, 61% of users want the program to start within 4 seconds, while 49% want to respond to input within 2 seconds. If the application crashes, freezes or reports errors, 53% of users will uninstall APP.
Whether you are targeting consumers or businesses, the collapse problem will completely disappoint them. I talked to some mobile developers and asked them what were the most common crash problems they encountered, and they gave six common reasons:
1. Memory management
Everyone I ask will talk about memory management, and most APP will open many threads to take up the system's memory. Sachin Agarwal, vice president of marketing at OpsClarity, says programmers write code as if there are only applications they write in app, and he suggests that when writing programs, consider making them "good citizens in the application ecosystem."
Memory problems are not the same for all developers. "in iOS, you can use Objective-C to deal with a lot of memory problems," said Andrew Whiting, vice president of business development at Solstice Mobile. But you need to weigh the pros and cons. "on Android, you need more control over [memory], and you can make it exactly what you want, but it adds complexity."
"when we encounter [running] insufficient memory in Java, we find that it is usually related to loading large images or processing bitmaps," said Jonathan Karon, senior software engineering manager at New Relic. The reasons for common problems are compiled in the Mobile SDK technical performance report. "there are actually some surprising numbers that look like linker problems on Android, cannot find classes, or have an exception called an unclassified link." IOS applications, on the other hand, are often affected by NSInternalInconsistency exceptions because when developers change arrays or data collections in one place, something else is reading the list of things there.
two。 Software life cycle
The iterative application development process and its versions are released frequently, opening the door to minimizing the entry of viable products to market, and then improving it over time, which is now very popular. However, due to the dependence on the operating system and the third-party API, the traditional software life cycle becomes more complex.
"if you look at the latest Android updated system, a lot of applications will crash," Agarwal said. "the operating system itself is unstable or the operating system is updated, the application is not updated, or users do not download the new version, which" you can't control, it illustrates a core development process. "
The development of mobile and cloud computing has increased the use of third-party services and their associated API, saving time and helping to bring applications to market faster, but they have their own set of problems.
"A lot of libraries have common problems," Whiting said. "they try to solve everyone's problems, not to provide the best solution for anyone." For example, a given API may have performance limits for a particular application.
API may also use tricky techniques, such as iOS method tuning. When the original code (such as Apple's API) is not available, developers modify it based on the original code (such as Apple's API). "you can call it one of the 'dark arts' of iOS application development," said Raman Bhatia, mobile director of online travel agency Fareportal. "[but] if your application code is written in some way, it can lead to a crash."
API can also cause other problems. "API latency, error rate, data bandwidth, the version of API and the number of API requests can all be issued by minor issues," Agarwal said. Then there is API itself, which requires specialized tools to track everything.
API can also cause other problems, such as memory errors. "if you create an object that has been removed from memory before creating another object, you will think that there is usually no problem, but it is important to note that you do not know whether subsequent created objects need to refer to deleted objects," said co-founder and developer Long Le. "this will cause problems, especially if you introduce a third-party framework. You can never be sure what they are cleaning up and what they are creating. "
3. Insufficient testing
The requirements for testing are obvious, but sufficient coverage is required, especially for a large number of Android versions and devices, which can be challenging. Although there is an emulator, the performance limitations of the software running on the server may be different from those of the real machine.
For example, one thread of the application reads the database while the second thread tries to modify the database. "it's a matter of time," said Wayne Carter, chief architect of Couchbase Mobile. "if they hadn't collided at the same time, the problem would not have occurred and could be masked by a log description." The simulator is usually not the same as the real machine.
Running different systems on different devices is a feasible solution, but this method is more expensive than simulators. This requires a tradeoff between budget and demand.
Testing should be combined with industry standards and user-expected benchmarks to ensure acceptable content for developers and users. Testing should also be carried out continuously. Monitor performance and find user feedback, and then resolve the problem as soon as possible.
4. Network management
As applications become more and more dependent on the network, whether data or third-party services, network management has become a source of trouble.
The main reason for a crash is that APP responds or hangs when you are about to get data or submit something waiting for recovery. Pravin Vazirani, vice president of operations, said that developers may make Wi-Fi connections very functional, but users will have problems when they are in a bad network area.
A good way to deal with network problems is to inform users that the connection is broken and, if possible, to provide opportunities to perform other operations that may be of interest. If people understand the reasons for temporary conditions beyond the control of the application, they are more likely to remain calm and not annoyed with the software.
5. Error conditions and exception handling
Due to the complexity of mobile development, some errors are inevitable, whether accidental API changes, avoiding previously detected memory problems, network connection conditions, or even slowing down data transfer when transferring large files (such as images or videos)
In this case, the best way is to give good error and exception handling. For example, users enter the wrong data, should provide numerical content but provide text into the text box, and so on, so that the application will not be accidentally tried and reported an error.
In any of these cases, the correctly coded application will notice unexpected conditions and can gracefully terminate the process or activity while notifying the user of the error. If you can keep the communication channels open, you will have a better chance to retain users.
6. There's too much code.
The best advice is to keep the application simple. Find plug-ins for specific purposes, use plug-ins, and write the necessary code. Felipe Laso-Marsetti, a senior systems engineer at Lextech Global Services, an enterprise mobile development company, said: "the best and most error-free code is not your own code."
About "what are the six common causes of App crash" here, more related content can be searched for previous articles, hope to help you answer questions, please support the website!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.