Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android BOINC 7.16.16 stays in memory all the time #4189

Closed
Ageless93 opened this issue Feb 16, 2021 · 2 comments · Fixed by #5338
Closed

Android BOINC 7.16.16 stays in memory all the time #4189

Ageless93 opened this issue Feb 16, 2021 · 2 comments · Fixed by #5338

Comments

@Ageless93
Copy link
Contributor

It's not possible to get BOINC out of memory, it's become an always on application. I can open the message about it being suspended in my phone's notification bar but I cannot swipe it left or right out of memory. Pressing square and choosing the garbage bin to remove all active apps from memory will leave BOINC running and using battery.

https://ibb.co/5G03SjN

@Ageless93
Copy link
Contributor Author

It gets better. Having unplugged my phone, after half an hour I could swipe away the notification on the notification bar that BOINC was suspended. I had already cleared memory, so normally for other apps this means they are really really not running. Not so for BOINC.

https://user-images.githubusercontent.com/10869587/108099574-1928d600-7085-11eb-9fa7-80763508d89b.jpg
6.95% of BOINC using my battery for an app that is suspended... ouch.

@AenBleidd AenBleidd moved this from Backlog to Backlog Prioritized in Android Release 7.18 Feb 16, 2021
@Ageless93
Copy link
Contributor Author

Ran BOINC overnight while my phone was being charged.
https://i.ibb.co/y8xk276/Battery-usage-30.jpg shows it used 30% of the battery during that charging time. It's also running while I manually suspended BOINC and it's not on the charger. I then force stop BOINC and wait half an hour.
https://i.ibb.co/TbxtvC8/Battery-usage-1.jpg is what I would count as normal usage of the battery (1%), with a forced stopped BOINC.

@AenBleidd AenBleidd removed this from Backlog Prioritized in Android Release 7.18 Jun 23, 2021
@AenBleidd AenBleidd added this to Backlog in BOINC Android via automation Jun 23, 2021
@AenBleidd AenBleidd moved this from Backlog to Backlog Prioritized in BOINC Android Jun 23, 2021
AenBleidd added a commit to AenBleidd/boinc that referenced this issue Aug 19, 2023
In BOINC#3418 I changed the behavior of BOINC to run always in the foreground mode.
This lead to the situation when notification was always shown, even when BOINC in not running, and thus making a lot of notification noise.
3 years ago I thought that this is good decision and a necessary evil.
Unfortunately, I was wrong.
My main motivation of this was to be able to be on track, and have our application in the Play Store.
But every new API increase the limitations from the Android side become stronger and stronger, and prevent us from doing what we want.
For example, in the Android versions starting from Oreo, it is not possible to start a service from the background.
And while we can leave with that fact, we received and issue with the notifications.
I thought, that if we will have BOINC always running on the foreground, it will be possible to keep it always running and prevent it from being killed by the system.
Unfortunately, this is not the case.
The system still kills the application, and the notification is still shown.
And this is not the only problem.
Other problem is that starting from API 29, we are not able to start executables downloaded from the server.
Since this is a core functionality, we are not able to target API 29 or higher.
And since we are not able to target API 29 or higher, we are not able to put BOINC in the Play Store.
And thus it makes no sense to target any API higher than 21 because it will just kill the functionality of the application.
So, I decided to revert back to the API 21, and make the application work as it was before.
But even in this case there is a chance that on the newer version of Android, some of the gard limitations will be applied, and it will prevent (again) BOINC from working.
But at least currently application is working, and we can add necessary features to it.
The only issue I see now is that the user will see a notification, that this application was developed for the older version of Android and thus might not work correctly,
but I believe we can live with that.

This fixes: BOINC#4189, BOINC#4218 and BOINC#4190

Signed-off-by: Vitalii Koshura <lestat.de.lionkur@gmail.com>
AenBleidd added a commit to AenBleidd/boinc that referenced this issue Aug 19, 2023
In BOINC#3418 I changed the behavior of BOINC to run always in the foreground mode.
This lead to the situation when notification was always shown, even when BOINC in not running, and thus making a lot of notification noise.
3 years ago I thought that this is good decision and a necessary evil.
Unfortunately, I was wrong.
My main motivation of this was to be able to be on track, and have our application in the Play Store.
But every new API increase the limitations from the Android side become stronger and stronger, and prevent us from doing what we want.
For example, in the Android versions starting from Oreo, it is not possible to start a service from the background.
And while we can leave with that fact, we received and issue with the notifications.
I thought, that if we will have BOINC always running on the foreground, it will be possible to keep it always running and prevent it from being killed by the system.
Unfortunately, this is not the case.
The system still kills the application, and the notification is still shown.
And this is not the only problem.
Other problem is that starting from API 29, we are not able to start executables downloaded from the server.
Since this is a core functionality, we are not able to target API 29 or higher.
And since we are not able to target API 29 or higher, we are not able to put BOINC in the Play Store.
And thus it makes no sense to target any API higher than 21 because it will just kill the functionality of the application.
So, I decided to revert back to the API 21, and make the application work as it was before.
But even in this case there is a chance that on the newer version of Android, some of the gard limitations will be applied, and it will prevent (again) BOINC from working.
But at least currently application is working, and we can add necessary features to it.
The only issue I see now is that the user will see a notification, that this application was developed for the older version of Android and thus might not work correctly,
but I believe we can live with that.

This fixes: BOINC#4189, BOINC#4218 and BOINC#4190

Signed-off-by: Vitalii Koshura <lestat.de.lionkur@gmail.com>
AenBleidd added a commit to AenBleidd/boinc that referenced this issue Aug 19, 2023
In BOINC#3418 I changed the behavior of BOINC to run always in the foreground mode.
This lead to the situation when notification was always shown, even when BOINC in not running, and thus making a lot of notification noise.
3 years ago I thought that this is good decision and a necessary evil.
Unfortunately, I was wrong.
My main motivation of this was to be able to be on track, and have our application in the Play Store.
But every new API increase the limitations from the Android side become stronger and stronger, and prevent us from doing what we want.
For example, in the Android versions starting from Oreo, it is not possible to start a service from the background.
And while we can leave with that fact, we received and issue with the notifications.
I thought, that if we will have BOINC always running on the foreground, it will be possible to keep it always running and prevent it from being killed by the system.
Unfortunately, this is not the case.
The system still kills the application, and the notification is still shown.
And this is not the only problem.
Other problem is that starting from API 29, we are not able to start executables downloaded from the server.
Since this is a core functionality, we are not able to target API 29 or higher.
And since we are not able to target API 29 or higher, we are not able to put BOINC in the Play Store.
And thus it makes no sense to target any API higher than 21 because it will just kill the functionality of the application.
So, I decided to revert back to the API 21, and make the application work as it was before.
But even in this case there is a chance that on the newer version of Android, some of the gard limitations will be applied, and it will prevent (again) BOINC from working.
But at least currently application is working, and we can add necessary features to it.
The only issue I see now is that the user will see a notification, that this application was developed for the older version of Android and thus might not work correctly,
but I believe we can live with that.

This fixes: BOINC#4189, BOINC#4218 and BOINC#4190

Signed-off-by: Vitalii Koshura <lestat.de.lionkur@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
BOINC Android
  
Prioritized
Development

Successfully merging a pull request may close this issue.

2 participants