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

[BUG] CPU overconsumption related to the new audio switch feature #1131

Open
Fred89210 opened this issue Jul 23, 2024 · 5 comments
Open

[BUG] CPU overconsumption related to the new audio switch feature #1131

Fred89210 opened this issue Jul 23, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@Fred89210
Copy link

Fred89210 commented Jul 23, 2024

I recently installed the latest version of the Deckboard server (3.0.5 and 3.0.6) and since then I have noticed an abnormal CPU consumption.
If the Deckboard window is open, it is the Deckboard process that consumes the CPU.
If the Deckboard window is closed (but the Deckboard server is started), I have the Windows Powershell process that starts to consume the CPU.
By controlling the Windows Powershell process that consumes abnormally, I notice that the parent is Deckboard.exe and the command line is powershell.exe "Get-AudioDevice -Playback | ConvertTo-Json".

I suspect that this comes from the new feature that allows you to change the audio output with Deckboard.
I think that I may have a device that is causing a problem and that would therefore lead to this CPU consumption. So I removed my buttons using the new feature but that doesn't change anything, the Deckboard server continues to check the audio devices in a loop, even if we don't use the feature and it causes an overconsumption of the CPU.

The problem persists even if no client is connected.
By completely quitting the Deckboard server, the problem disappears.

To Reproduce
Install the latest version of Deckboard and monitor the Task Manager.
Deckboard or Windows Powershell may be consuming CPU abnormally.

Expected behavior
Deckboard should consume as many CPU resources as it did with version 3.0.4 or earlier.
It would be at least necessary for Deckboard to stop monitoring audio devices when this feature is not in use, or to have the option to disable this option.

Screenshots
image

Server App (please complete the following information):

  • OS: Windows 10 22H2
  • Deckboard Server 3.0.6

Client App (please complete the following information):

  • Android 14 (Google Pixel 6 Pro)
  • Deckboard Pro 3.1.5

Required files

  • database.db (Github does not accept uploading .db files, I have replaced the extension with .json to be able to upload it)
  • log.log

In order to temporarily resolve my problem, I have reinstalled version 3.0.4 of the Deckboard server.

@Fred89210 Fred89210 added the bug Something isn't working label Jul 23, 2024
@rivafarabi
Copy link
Owner

That powershell command is indeed added in version 3.0.5 to get the active device, polled every 2 seconds.
The process should stop immediately, is it the same on your end? And how much percentage of CPU amount we are talking here?

Probably need to adjust the polling interval.

@Fred89210
Copy link
Author

The process stops and restarts immediately, this happens in a loop for several minutes.
After several minutes, Powershell will not reappear for a few seconds (between 30 seconds and one minute I would say) and will reappear in a loop.

This process consumes about 15% of the CPU.

I have 5 active audio inputs and 5 active audio outputs.
I also have other audio inputs and outputs that are disabled or disconnected.
I have physical devices and virtual devices.

@rivafarabi
Copy link
Owner

rivafarabi commented Jul 24, 2024 via email

@Fred89210
Copy link
Author

Great, thank you. I will watch for updates and keep you informed.

@rivafarabi
Copy link
Owner

Just released the patch 3.0.7. The active audio output device updates every 60 seconds instead of 2 seconds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants