• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

valkyrjaio / valkyrja-java / 30236270400
100%

Build:
DEFAULT BRANCH: 26.x
Ran 27 Jul 2026 04:09AM UTC
Jobs 1
Files 653
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

27 Jul 2026 04:08AM UTC coverage: 99.977%. Remained the same
30236270400

push

github

web-flow
[Application] Emit worker HTTP responses through the runtime and marshal native requests (#50)

# Description

Makes the persistent-worker HTTP entries (`exchange`, `netty`, `jetty`,
`tomcat`) worker-safe by wiring both halves of their request/response
I/O to the runtime's own objects instead of the ambient PHP-SAPI-style
sinks.

Before this change the worker adapters dispatched through
`RequestHandler.run()`, whose pipeline ends in `Response.send()` — which
writes the status line, headers, and body to `System.out`. In a
persistent worker that means the response is printed to the worker
process's stdout, never sent to the client. Request ingestion was
equally stubbed: every `getRequest(...)` returned
`RequestFactory.fromGlobals()`, ignoring the native request.

This follows the PHP reference worker entries
(`Application/Entry/OpenSwoole/OpenSwooleHttp`,
`.../RoadRunner/RoadRunnerHttp`, PR valkyrjaio/valkyrja-php#919): split
the pipeline into `handle → SendingResponse → terminate` and emit the
returned response through the runtime's own response object. It also
brings the HTTP side to parity with the gRPC side, which already does
exactly this in `WorkerGrpc.dispatch`.

The shared split and request-marshaling logic live once in `WorkerHttp`
(framework core, covered by tests); each per-runtime adapter only
translates its native request/response types.

One deliberate deviation from the PHP reference: `terminate`
(`ResponseSent`) runs **after** the response is emitted, matching Java's
own CGI `run()` ordering and `WorkerGrpc.dispatch`
(emit-then-terminate), rather than PHP's terminate-then-emit.
`ResponseSent` semantically means "the response has been sent", so it
belongs after the wire write; the emit is wrapped so `terminate` still
runs if the emit throws.

Depends on / stacked conceptually on #45 (the fold of the runtime
entries into the framework), now merged; this PR bases on `26.x`.

Parsed form bodies and uploaded files are intentionally left empty... (continued)

1870 of 1872 branches covered (99.89%)

Branch coverage included in aggregate %.

47 of 47 new or added lines in 1 file covered. (100.0%)

6798 of 6798 relevant lines covered (100.0%)

4.34 hits per line

Jobs
ID Job ID Ran Files Coverage
1 30236270400.1 27 Jul 2026 04:09AM UTC 653
99.98
GitHub Action Run
Source Files on build 30236270400
  • Tree
  • List 653
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #30236270400
  • 4f602059 on github
  • Prev Build on 26.x (#30235881102)
  • Next Build on 26.x (#30322446063)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc