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

Resolving failing TCK #235

Merged
merged 3 commits into from Sep 26, 2022
Merged

Resolving failing TCK #235

merged 3 commits into from Sep 26, 2022

Conversation

dmatej
Copy link
Contributor

@dmatej dmatej commented Sep 25, 2022

Solution: partial cleanup in xml package.

  • Maybe (!!!) fixes race condition in GlassFish.
  • Since this change the TCK jstl/spec/xml/xmlcore/types passed several times without failing. However, I am still not convinced, because the failure wasn't well reproducible and also the cause wasn't clearly visible.
  • Updated dependencies
  • XPathUtil doesn't set system properties any more.
  • DocumentBuilderFactory should not be used as a constant, it is not thread-safe. Despite in this case I doubt it could cause issue, but I cannot be sure. EDIT: It can be used as a constant if it doesn't change. DocumentBuilder cannot.
  • Deleted unused methods
  • JSTLNodeList moved to own file
  • Deleted copy pasted javadocs from old versions
  • More should be done, but let's start with this.

cd /repo/git/jstl && mvn clean install && cd /repo/git/glassfish-beta && mvn clean install -Pfastest -T4C -Djstl-impl.version=3.0.1-SNAPSHOT && mvn clean install -Ptck -pl :tck-runner -Dit.test=CustomITest -Dtck.module=jstl

Or to run those randomly failing tests directly use -Dtck.module=jstl/spec/xml/xmlcore/types

Note: I tried to replace the JSTLXPathFactory by the factory from the JDK, but that failed, it needs more work, perhaps later.

TCK results with GlassFish 7.0.0-SNAPSHOT near to M9, commit e821a1a6a86fce6daa06db203bdd7676231bbec7

[runcts] OUT => [javatest.batch] Total time = 1,423s
[runcts] OUT => [javatest.batch] Setup time = 0s
[runcts] OUT => [javatest.batch] Cleanup time = 2s
[runcts] OUT => [javatest.batch] Test results: passed: 541

Signed-off-by: David Matějček <david.matejcek@omnifish.ee>
- Maybe (!!!) fixes race condition in GlassFish. Since this change the TCK
  jstl/spec/xml/xmlcore/types passed several times without failing.
  However, I am still not convinced, because the failure wasn't well
  reproducible and also the cause wasn't clearly visible.
- XPathUtil doesn't set system properties any more (see XPathUtil).
- DocumentBuilderFactory should not be used as a constant,
  it is not thread-safe. Despite in this case I doubt it could cause issue,
  I cannot be sure.
- Deleted unused methods
- JSTLNodeList moved to own file
- Deleted copy pasted javadocs from old versions
- More should be done, but let's start with this.


Signed-off-by: David Matějček <david.matejcek@omnifish.ee>
Signed-off-by: David Matějček <david.matejcek@omnifish.ee>
@arjantijms arjantijms merged commit d79b3b1 into jakartaee:master Sep 26, 2022
@dmatej dmatej deleted the xpathfactory branch September 26, 2022 12:52
@dmatej dmatej mentioned this pull request Sep 26, 2022
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.

None yet

2 participants