NetLogo / NetLogo/Sound-Extension
Switch to event-queue model to avoid spurious thread-creation
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 4
- Forks
- 6
- PR merge metrics
- No merged PRs in 30d
Description
This extension works by creating 1-2 threads for every note played, one to start the note playing and one to stop it. This can lead to literally thousands of threads being created within a second or two of each other. Instead of starting a thread for each start/stop, it would be better to have a pool of x (probably 1-2) background threads which take various start/stop operations from a DelayQueue and execute them. This would reduce the total number of threads and conceptually simplify the model this extension uses.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the extension code that creates threads for note start and stop operations, then read how those operations are scheduled and ended. Compare that flow with Java's DelayQueue; done means a small background-thread pool handles delayed start/stop work without creating a thread for every note.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- audio-video-rtc
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100