GCC: RateController does not use the internal state
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Stale
- Tech stack
- go
- Domain
- audio-video-rtc, networking
Research direction
Start in pkg/gcc/rate_controller.go at rateController.onDelayStats and trace how c.delayStats.State is updated between delay-stat samples. Compare the current transition source with the expected internal state shown in the issue, then run the relevant existing GCC tests if available. Done means state transitions use the retained controller state and the behavior is covered by passing tests.
Written by the indexing model from the issue text.
Description
Your environment.
- Version: v0.1.30
What did you do?
RateController on the delay stats update doesn't use the internals state. Should we make a transition from the internal state, not from the current one (which is always increase actually)? Snippet from the rate_controller.go :
func (c *rateController) onDelayStats(ds DelayStats) {
now := time.Now()
if !c.init {
c.delayStats = ds
c.delayStats.State = stateIncrease
c.init = true
return
}
c.delayStats = ds
// Transition from the current state?
c.delayStats.State = c.delayStats.State.transition(ds.Usage)
if c.delayStats.State == stateHold {
return
}
// ... more logic
}
What did you expect?
Using the internal state (smth like this):
func (c *rateController) onDelayStats(ds DelayStats) {
now := time.Now()
if !c.init {
c.delayStats = ds
c.delayStats.State = stateIncrease
c.init = true
return
}
prev := c.delayStats
c.delayStats = ds
c.delayStats.State = prev.State.transition(ds.Usage)
if c.delayStats.State == stateHold {
return
}
// ... more logic
}
What happened?
- Dominant language
- Go
- Stars
- 147
- Forks
- 103
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 19
Contributor guide
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.
More from pion/interceptor
-
Difficulty 1/5 Under an hour Newbie friendliness 64/100
pion/interceptor#413 · 1 reaction ·
-
pion/interceptor#453 · 1 comment · 1 assignee ·
-
Gap skipping policy Open
Difficulty 5/5 Over a week Newbie friendliness 35/100
pion/interceptor#429 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
pion/interceptor#416 · 4 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
pion/interceptor#406 · 4 comments ·
All issues in pion/interceptor
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 84/100
-
enhancement needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
kind/cleanup
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
kubernetes-sigs/kueue#15947 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
sympozium-ai/sympozium#627 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100