jakartaee / jakartaee/faces

Provide response headers in Event Data Payload

Open
#975 6 comments 0 reactions 0 assignees View on GitHub
Priority: Minor Type: Sub-task
Dominant language
Java
Stars
127
Forks
59
Avg merge
23h
Merged PRs (30d)
7

Description

I need to access the response headers in a callback function as defined in section 14.4.1\. I propose to extend TABLE 14-4 Event Data Payload like this:

responseHeaders | The response headers (XMLHttpRequest.getAllResponseHeaders()); Not present for "begin" event;

Alternatively, it might make sense to add the XMLHttpRequest (or equivalent) object itself available in the payload. This would allow for greater flexibility.

Reason:
In the system environment of one of our applications a non-standard HTTP proxy is setting response headers we have to evaluate and handle in Ajax requests. The callback mechansim is perfect for this and we made a POC with Mojarra 2.1.1-b03 that our needs are satisfied by just extending the event data payload as described.
#### Affected Versions
[2.1]

Contributor guide

Open the contributing guide

Research direction

Start with section 14.4.1 and Table 14-4, then trace the existing callback event payload handling in Jakarta Faces. Compare the proposed responseHeaders field with the alternative of exposing XMLHttpRequest, including the stated exception for begin events. Done means the chosen payload behavior is implemented and documented consistently.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, javascript
Domain
api, web-dev
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.