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

Aggregated fixes from Payara #2112

Merged

Conversation

dmatej
Copy link
Contributor

@dmatej dmatej commented Nov 19, 2020

Fixes #2016 and #2111

This is a aggregated PR of Payara's fork of 2.4.4, I hope I didn't skip anything.
Current Payara 5.2020.7-SNAPSHOT with these commits in it's own patch of Grizzly passed following tests:

Merge:

@dmatej dmatej force-pushed the eclipse-2016-http2Trailers-clear branch from 1d495fb to 8ba9b17 Compare November 19, 2020 23:42
@dmatej
Copy link
Contributor Author

dmatej commented Nov 19, 2020

All commits are signed, but eclipsefdn/eca has different opinion - what can I do?

@edbratt
Copy link
Contributor

edbratt commented Nov 20, 2020

I agree, it does appear you have signed all the commits and you do have a valid ECA. A committer can go ahead and merge, once a review has been completed.

All commits are signed, but eclipsefdn/eca has different opinion - what can I do?

@dmatej dmatej force-pushed the eclipse-2016-http2Trailers-clear branch from 8ba9b17 to f5b7381 Compare November 20, 2020 06:38
@dmatej
Copy link
Contributor Author

dmatej commented Nov 20, 2020

I tried even to match my name including czech letters č and ě, but it is still the same. I'm giving up fighting with the eclipsefdn/eca checker ... the PR is prepared to be merged now, I don't plan any other pushes except those which would come from reviews.

dmatej and others added 22 commits November 20, 2020 14:59
…implementations

- default is none (uses JDK's impl)
- profile npn uses grizzly-npn-bootstrap
- profile openjsse uses openjsse
- versions can be overriden from command line (to compare results)

Signed-off-by: David Matějček <dmatej@seznam.cz>
- important loggers are explicitly named in logging.properties

Signed-off-by: David Matějček <dmatej@seznam.cz>
Signed-off-by: David Matějček <dmatej@seznam.cz>
Create new phase in the handshake listener to allow registration of the
custom ALPN logic. This allows the HTTP/2 filter to work correctly.

Signed-off-by: Matthew Gill <matthew.gill@live.co.uk>
Signed-off-by: David Matějček <dmatej@seznam.cz>
Streams still allowed pushing resources when globally disabled as the
stream itself and the session both allow it. This change makes the
stream also respect the global configuration.

Signed-off-by: Matthew Gill <matthew.gill@live.co.uk>
Signed-off-by: David Matějček <dmatej@seznam.cz>
…nterface

- moving this interface out is a breaking change

Signed-off-by: David Matějček <dmatej@seznam.cz>
…y connection closure.

Signed-off-by: Matt Gill <matthew.gill@live.co.uk>
Signed-off-by: David Matějček <dmatej@seznam.cz>
Signed-off-by: Matt Gill <matthew.gill@live.co.uk>
Signed-off-by: David Matějček <dmatej@seznam.cz>
Signed-off-by: Matt Gill <matthew.gill@live.co.uk>
Signed-off-by: David Matějček <dmatej@seznam.cz>
- partial cleanup, but requires much more than this
- DefaultOutputSink
  - combination of "fixes by refactoring" mixed with the changes in the flow
    of the logic
  - sendTrailers now locks the deflater
- added some javadocs and much more logs

Signed-off-by: David Matějček <dmatej@seznam.cz>
- can run with any compatible implementation, not only NPN Bootstrap
- with new JDK versions after 8u250 uses it's JSSE impl by default
- still can use older NPN bootstrap versions if configured
- can use also other implementations (openjsse)

Signed-off-by: David Matějček <dmatej@seznam.cz>
…mes, but ...

- in this state grizzly:
  - fails TrailersTest (grizzly-http2; race condition, passes if I use stepping)
  - passes TCK tests with Payara (websocket)
  - still fails h2spec with Payara (race condition, different, but related issue)

Signed-off-by: David Matějček <dmatej@seznam.cz>
- 19001 is often occupied in Kubuntu

Signed-off-by: David Matějček <dmatej@seznam.cz>
- if the queue size is not same as reserved space, and if it is last content
  and the content is a trailer, send trailers
- if the queue size is same as reserved space, and record was already processed,
  don't send trailers.
- TrailersTest - just formatting and finals

Signed-off-by: David Matějček <dmatej@seznam.cz>
Signed-off-by: David Matějček <dmatej@seznam.cz>
Signed-off-by: David Matějček <dmatej@seznam.cz>
Signed-off-by: Matthew Gill <matthew.gill@live.co.uk>
Signed-off-by: David Matějček <dmatej@seznam.cz>
- original code was throwing NPE
- handler can be null
  - then we have nothing to handle the reason
- closeReason can be null
  - then we use "locally closed" as a default (may be incorrect)
- even ignored exception should be visible somewhere (logging)

Signed-off-by: David Matějček <dmatej@seznam.cz>
- based on h2spec results - client was able to cause ISE on the server simply
  by misformatted header
- assertions are worthless in production

Signed-off-by: David Matějček <dmatej@seznam.cz>
- fixes another NPE seen in logs

Signed-off-by: David Matějček <dmatej@seznam.cz>
Signed-off-by: David Matějček <dmatej@seznam.cz>
- Test results:
- OpenJDK 8u275, openjsse 1.1.5 ... SUCCESS
- OpenJDK 11.0.8, openjsse 1.1.5 ... FAIL ... as expected
- OpenJDK 8u275, npn bootstrap 1.9 ... FAIL ... as expected
- OpenJDK 8u232, npn bootstrap 1.9.payara-p1 ... SUCCESS
- OpenJDK 8u275 ... SUCCESS
- OpenJDK 11.0.8 ... SUCCESS

Signed-off-by: David Matějček <dmatej@seznam.cz>
@dmatej dmatej force-pushed the eclipse-2016-http2Trailers-clear branch from f5b7381 to 360f431 Compare November 20, 2020 14:45
@dmatej
Copy link
Contributor Author

dmatej commented Nov 20, 2020

I rebased the PR, the build will now fail here for two reasons:

  • npn is not released yet
  • I reenabled AlpnSupportTest, locally tested in following configurations (see npn/openjsse profiles, default is no profile -> using JDK's impl). Travis is using now obsoleted JDK8u151 which does not contain backported ALPN support from newer JDKs yet.
  • OpenJDK 8u275, openjsse 1.1.5 ... SUCCESS
  • OpenJDK 11.0.8, openjsse 1.1.5 ... FAIL ... as expected
  • OpenJDK 8u275, npn bootstrap 1.9 ... FAIL ... as expected
  • OpenJDK 8u232, npn bootstrap 1.9.payara-p1 ... SUCCESS
  • OpenJDK 8u275 ... SUCCESS
  • OpenJDK 11.0.8 ... SUCCESS

@dmatej dmatej mentioned this pull request Nov 20, 2020
@arjantijms
Copy link
Contributor

npn is not released yet

npn is now staged as 2.0.0, which can be used to do the build

Signed-off-by: David Matejcek <dmatej@seznam.cz>
Signed-off-by: David Matejcek <dmatej@seznam.cz>
@dmatej
Copy link
Contributor Author

dmatej commented Nov 21, 2020

The build passed locally with profile -Pstaging now, so after npn will make it to Maven Central it should pass now also on Travis :-)

Signed-off-by: David Matejcek <dmatej@seznam.cz>
@dmatej dmatej force-pushed the eclipse-2016-http2Trailers-clear branch from 573ea71 to 24eab02 Compare November 21, 2020 12:54
- required to be able to access staging repository with grizzly npn on Travis
- discussed with Arjan
- artifacts are not cached on Travis, so it should not cause any harm

Signed-off-by: David Matejcek <dmatej@seznam.cz>
@dmatej dmatej force-pushed the eclipse-2016-http2Trailers-clear branch from 24eab02 to 87569a5 Compare November 21, 2020 13:27
@arjantijms arjantijms merged commit a2ce777 into eclipse-ee4j:master Nov 21, 2020
@dmatej dmatej deleted the eclipse-2016-http2Trailers-clear branch November 25, 2020 19:22
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.

Async servlet failed to send large data frames completely when HTTP/2 trailers are present
4 participants