Closed pvliss closed 5 years ago
@cbornet Can you help to fix the tests? Thanks
Did a bit of investigation on this issue and it appears that the problem is the use of javax.servlet.http.HttpServletRequest
which is not supported by reactive Spring as explained in this Stack Overflow answer. Further looking into the webflux docs verifies that servlet API is not supported and should be avoided.
We could instead instead pass the URI and params map to PaginationUtil
or find an interface that provides access to both parameters and supported by both webflux and blocking APIs.
@cbornet I could do a PR if you do not mind and have not already started work on this.
On a side note, I noticed that no integration tests are generated for the entities for the webflux-mongodb
sample and otherwise we would see more errors I guess. Is this intentional(e.g. not supported yet) or maybe we have another issue?
There are already PRs to fix this.
Oh sorry, I did not realize. Why are they not merged then?
See #9379. There was a change in PaginationUtils to make it use HttpServletRequest but that fails with Webflux. The fix is to use UriComponentsBuilder and RequestParam instead.
@DanielFran @cbornet has created https://github.com/jhipster/jhipster/pull/202 and https://github.com/jhipster/generator-jhipster/pull/9379 to fix this issue. Can you have a look and merge them as they fix the CI problem?
BTW the entity generator hasn't been done yet for Webflux.
Cool. Thanks
Closed by #9379
Overview of the issue
The integration tests fail for sample
webflux-mongo
that tests reactive support. See https://jhipster.visualstudio.com/generator-jhipster/_build/results?buildId=2494The problem
Motivation for or Use Case
The integration tests should pass
Reproduce the error
Run integration tests for
webflux-mongo
Related issues
The problem is more likely due to the changes in #9326 and was hidden while the integration tests were not properly executed. This is now fixed with #9396
Suggest a Fix
Not sure
JHipster Version(s)
Current master (6.x)
JHipster configuration, a
.yo-rc.json
file generated in the root folder.yo-rc.json file
JDL for the Entity configuration(s)
entityName.json
files generated in the.jhipster
directoryJDL entity definitions
Environment and Tools
java version "1.8.0_201" Java(TM) SE Runtime Environment (build 1.8.0_201-b09) Java HotSpot(TM) 64-Bit Server VM (build 25.201-b09, mixed mode)
git version 2.17.1
node: v10.15.2
npm: 6.8.0
yeoman: 2.0.5
Docker version 18.09.3, build 774a1f4
docker-compose version 1.23.2, build 1110ad01
INFO! Congratulations, JHipster execution is complete!
Browsers and Operating System
Ubuntu 18.04