Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Complete frame callback when opcode is not PONG #31869

Closed
wants to merge 1 commit into from

Conversation

leonchen83
Copy link
Contributor

onWebSocketFrame method should complete callback. more details see issue JETTY 11088

onWebSocketFrame method should complete callback. more details see issue [JETTY 11088](jetty/jetty.project#11088)
@pivotal-cla
Copy link

@leonchen83 Please sign the Contributor License Agreement!

Click here to manually synchronize the status of this Pull Request.

See the FAQ for frequently asked questions.

@pivotal-cla
Copy link

@leonchen83 Thank you for signing the Contributor License Agreement!

Copy link

@sbordet sbordet left a comment

Choose a reason for hiding this comment

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

Good catch!

@sdeleuze sdeleuze self-assigned this Dec 21, 2023
@sdeleuze sdeleuze added in: web Issues in web modules (web, webmvc, webflux, websocket) type: bug A general bug and removed status: waiting-for-triage An issue we've not yet triaged or decided on labels Dec 21, 2023
@sdeleuze sdeleuze added this to the 6.1.3 milestone Dec 21, 2023
@sdeleuze
Copy link
Contributor

@sbordet From your perspective, should we apply this fix to the Jetty 11 support we have in Spring Framework 6.0.x as well?

@sbordet
Copy link

sbordet commented Dec 21, 2023

@sdeleuze Jetty 11 does not need this fix because it does not use Callback.

The corresponding signature in Jetty 11 would be:

@OnWebSocketFrame
public void onWebSocketFrame(Frame frame)

so no Callback.
In Jetty 11 there is the requirement that the frame payload must be consumed synchronously in the method invocation, or copied to be consumed asynchronously, because when returning from the onWebSocketFrame() method the frame payload buffer is recycled.

@sdeleuze sdeleuze closed this in e00a882 Dec 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: web Issues in web modules (web, webmvc, webflux, websocket) type: bug A general bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants