You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 15, 2022. It is now read-only.
My name is Alejandro Mazuera-Rozo, I am a PhD Student at Universidad de los Andes, and at Università della Svizzera italiana. I am part of a research on the usage of network libraries within Android apps. As result of this we identified some code locations that might have network related problems.
In this case, we address the code locations that are related to a potential issue because of implementing synchronous operations. As you might know, using the execute() method on a call object will perform a synchronous request which is not recommended and its usage is discouraged.
In synchronous operations, tasks are performed one at a time and only when one is completed, the following is unblocked.
In asynchronous operations, you can move to another task before the previous one finishes, allowing you to deal with multiple requests simultaneously.
Moreover, by avoiding this approach, it is less likely to perform network operations on the main thread. Android requires you to perform network operations on a thread other than the main UI thread; a NetworkOnMainThreadException is thrown otherwise.
In order to address this issue we recommend you to visit:
Dear Developer!
My name is Alejandro Mazuera-Rozo, I am a PhD Student at Universidad de los Andes, and at Università della Svizzera italiana. I am part of a research on the usage of network libraries within Android apps. As result of this we identified some code locations that might have network related problems.
In this case, we address the code locations that are related to a potential issue because of implementing synchronous operations. As you might know, using the
execute()
method on a call object will perform a synchronous request which is not recommended and its usage is discouraged.In synchronous operations, tasks are performed one at a time and only when one is completed, the following is unblocked.
In asynchronous operations, you can move to another task before the previous one finishes, allowing you to deal with multiple requests simultaneously.
Moreover, by avoiding this approach, it is less likely to perform network operations on the main thread. Android requires you to perform network operations on a thread other than the main UI thread; a
NetworkOnMainThreadException
is thrown otherwise.In order to address this issue we recommend you to visit:
Potential Code Location with synchronous operations:
Audinaut/app/src/main/java/net/nullsum/audinaut/service/RESTMusicService.java
Line 84 in aa4c877
Audinaut/app/src/main/java/net/nullsum/audinaut/service/RESTMusicService.java
Line 285 in aa4c877
Audinaut/app/src/main/java/net/nullsum/audinaut/service/RESTMusicService.java
Line 369 in aa4c877
Audinaut/app/src/main/java/net/nullsum/audinaut/service/RESTMusicService.java
Line 417 in aa4c877
Audinaut/app/src/main/java/net/nullsum/audinaut/service/RESTMusicService.java
Line 534 in aa4c877
Audinaut/app/src/main/java/net/nullsum/audinaut/service/RESTMusicService.java
Line 561 in aa4c877
The text was updated successfully, but these errors were encountered: