Skip to content

compiler warning issues - #714

Merged
pjfanning merged 4 commits into
apache:mainfrom
pjfanning:compiler-warnings
Aug 7, 2025
Merged

pjfanning merged 4 commits into
apache:mainfrom
pjfanning:compiler-warnings

Conversation

@pjfanning

Copy link
Copy Markdown
Member
  • reduces the issues that we silence with -Wcat
  • fixes a couple of issues
  • adds explicit nowarns and TODOs in places where we need to think about making changes
  • there are some other issues left behind that I hope to revisit

@He-Pin He-Pin left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@pjfanning
pjfanning merged commit ee43056 into apache:main Aug 7, 2025
@pjfanning
pjfanning deleted the compiler-warnings branch August 7, 2025 08:34
He-Pin added a commit to He-Pin/incubator-pekko-http that referenced this pull request Nov 17, 2026
Motivation:
Fixed-rate keepalive ticks can catch up after a scheduler pause and
prematurely exhaust the acknowledgment window of a newly sent ping.

Modification:
Use fixed-delay ticks and cover delayed execution with a deterministic
regression. Clarify that the interval and ping timeout may be longer
under load for both client and server settings.

Result:
Delayed callbacks no longer compress the acknowledgment window;
unacknowledged pings still time out.

Tests:
The earlier identical runtime code passed the new focused regression
and six existing ping cases. The documentation follow-up was checked
as comment-only; no runtime retest or CI query for this squash.

References:
Refs apache#1462, apache#714 and akka/akka-http#4182.
He-Pin added a commit to He-Pin/incubator-pekko-http that referenced this pull request Nov 17, 2026
Motivation:
Fixed-rate keepalive ticks can catch up after a scheduler pause and
prematurely exhaust the acknowledgment window of a newly sent ping.

Modification:
Use fixed-delay ticks and cover delayed execution with a deterministic
regression. Clarify that the interval and ping timeout may be longer
under load for both client and server settings.

Result:
Delayed callbacks no longer compress the acknowledgment window;
unacknowledged pings still time out.

Tests:
The earlier identical runtime code passed the new focused regression
and six existing ping cases. The documentation follow-up was checked
as comment-only; no runtime retest or CI query for this squash.

References:
Refs apache#1462 and apache#714.
He-Pin added a commit to He-Pin/incubator-pekko-http that referenced this pull request Nov 17, 2026
### Motivation
HTTP/2 keepalive callbacks may accumulate while either the scheduler or stream interpreter is delayed. Counting callbacks can prematurely expire a newly sent ping even when its acknowledgment budget has not elapsed.

### Modification
- Keep fixed-delay scheduling and measure outstanding ping age with a monotonic clock.
- Keep one ping outstanding so queued ticks cannot replace its send timestamp.
- Preserve idle-data accounting, the zero-timeout fallback, and the existing internal two-argument constructor.
- Add deterministic clock coverage for queued callbacks, deadline expiry, acknowledgments, ordinary data, and clock wraparound. Pair the delayed-ACK integration with an unacknowledged-ping timeout observation, and drain pending scheduler work in both tests.

### Result
A callback burst alone cannot consume the acknowledgment budget. Missing acknowledgments still expire after elapsed time, with detection on a subsequent tick. This does not promise immediate processing during dispatcher starvation.

### Tests
- Offline Scala 2.13.18 compilation of changed production and focused test/support sources with `-deprecation -Wunused:imports -Werror`: passed.
- `org.scalatest.tools.Runner -o -s org.apache.pekko.http.impl.engine.http2.Http2PingSchedulingSpec`: 4 passed against cached HTTP module classes/dependencies after rebasing to 73c1ef8.
- Directional burst test: failed with old runtime body plus constructor-only test shim, passed with the new implementation.
- Cached official scalafmt 3.11.5 and `git diff --check`: passed.
- Not run: clean sbt build, cross-Scala/MiMa, full client/server ping suites. The no-ACK integration uses a bounded 1200ms no-output observation before advancing the paused scheduler; state-level clock coverage is deterministic.

### References
Refs apache#714.
Related timer discussion: akka/akka-http#4182 (citation only; no source copied for this follow-up).

Provenance: preserves original He-Pin PR head 8fef30f and incorporates PJ review feedback.
He-Pin added a commit to He-Pin/incubator-pekko-http that referenced this pull request Nov 18, 2026
Motivation:
HTTP/2 keepalive callbacks may accumulate while either the scheduler or stream interpreter is delayed. Counting callbacks can prematurely expire a newly sent ping even when its acknowledgment budget has not elapsed.

Modification:
- Keep fixed-delay scheduling and measure outstanding ping age with a monotonic clock.
- Keep one ping outstanding so queued ticks cannot replace its send timestamp.
- Preserve idle-data accounting, the zero-timeout fallback, and the existing internal two-argument constructor.
- Add deterministic clock coverage for queued callbacks, deadline expiry, acknowledgments, ordinary data, and clock wraparound. Pair the delayed-ACK integration with an unacknowledged-ping timeout observation, assert the timeout reason, and drain pending scheduler work in both tests.

Result:
A callback burst alone cannot consume the acknowledgment budget. Missing acknowledgments still expire after elapsed time, with detection on a subsequent tick. This does not promise immediate processing during dispatcher starvation.

Tests:
- Offline Scala 2.13.18 compilation of changed production and focused test/support sources with `-deprecation -Wunused:imports -Werror`: passed.
- `org.scalatest.tools.Runner -o -s org.apache.pekko.http.impl.engine.http2.Http2PingSchedulingSpec`: 4 passed against cached HTTP module classes/dependencies after rebasing to 73c1ef8, including the exact GOAWAY debug text.
- Directional burst test: failed with old runtime body plus constructor-only test shim, passed with the new implementation.
- Cached official scalafmt 3.11.5 and `git diff --check`: passed.
- Not run: clean sbt build, cross-Scala/MiMa, full client/server ping suites. The no-ACK integration uses a bounded 1200ms no-output observation before advancing the paused scheduler; state-level clock coverage is deterministic.

References:
Refs apache#714.
Related timer discussion: akka/akka-http#4182 (citation only; no source copied for this follow-up).

Provenance: preserves original He-Pin PR head 8fef30f and incorporates PJ review feedback.
pjfanning pushed a commit that referenced this pull request Nov 18, 2026
Motivation:
HTTP/2 keepalive callbacks may accumulate while either the scheduler or stream interpreter is delayed. Counting callbacks can prematurely expire a newly sent ping even when its acknowledgment budget has not elapsed.

Modification:
- Keep fixed-delay scheduling and measure outstanding ping age with a monotonic clock.
- Keep one ping outstanding so queued ticks cannot replace its send timestamp.
- Preserve idle-data accounting, the zero-timeout fallback, and the existing internal two-argument constructor.
- Add deterministic clock coverage for queued callbacks, deadline expiry, acknowledgments, ordinary data, and clock wraparound. Pair the delayed-ACK integration with an unacknowledged-ping timeout observation, assert the timeout reason, and drain pending scheduler work in both tests.

Result:
A callback burst alone cannot consume the acknowledgment budget. Missing acknowledgments still expire after elapsed time, with detection on a subsequent tick. This does not promise immediate processing during dispatcher starvation.

Tests:
- Offline Scala 2.13.18 compilation of changed production and focused test/support sources with `-deprecation -Wunused:imports -Werror`: passed.
- `org.scalatest.tools.Runner -o -s org.apache.pekko.http.impl.engine.http2.Http2PingSchedulingSpec`: 4 passed against cached HTTP module classes/dependencies after rebasing to 73c1ef8, including the exact GOAWAY debug text.
- Directional burst test: failed with old runtime body plus constructor-only test shim, passed with the new implementation.
- Cached official scalafmt 3.11.5 and `git diff --check`: passed.
- Not run: clean sbt build, cross-Scala/MiMa, full client/server ping suites. The no-ACK integration uses a bounded 1200ms no-output observation before advancing the paused scheduler; state-level clock coverage is deterministic.

References:
Refs #714.
Related timer discussion: akka/akka-http#4182 (citation only; no source copied for this follow-up).

Provenance: preserves original He-Pin PR head 8fef30f and incorporates PJ review feedback.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants