Skip to content

jooby-netty: possible leak in scheduled tasks under HTTP traffic #3871

@NastyaYarotskas

Description

@NastyaYarotskas

Bug

jooby-netty shows increasing memory and CPU usage under repeated HTTP traffic.
After traffic stops, usage stays high instead of returning to baseline.

Environment

Steps to reproduce

  1. mvn clean package
  2. ./runJar.bat
  3. Send ~500 req/s with any HTTP request for ~30 min
  4. Stop traffic and observe metrics

Expected

Memory/CPU should drop close to baseline after traffic stops.

Actual

Memory/CPU remain elevated; object counts keep growing across bursts.

Observations

  • scheduledTaskQueue keeps growing
  • NettyString / NettyDateService are not fully released

Possible cause

NettyDateService is created per connection and schedules periodic tasks (scheduleAtFixedRate(...)) that appear not to be cancelled on channel close.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions