-
-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Default admin/user accounts don't work on Monolithic app w/ H2 disk-based persistence #24608
Comments
Using h2 disk-based persistence worked fine for me when I tried it with 8.1.0 and Angular last week as part of my jhipster8-demo tutorial and screencast. |
JHipster has completed the sample check This check uses |
I could not reproduce:
user/user 👍 |
Discovered that this is a token-relate issue. Repro case:
This happened to me because I ran the generator multiple times (testing different front-ends). This isn't strictly a defect, but has to do with token management. |
thanks @cfreyer. it works in private window |
This is a bug. Probably happens with expired jwt token too. |
Overview of the issue
After generating a new Monolithic app with H2 disk-based persistence, the standard Administrator and User accounts do not allow login. No console warnings are given. This functionality worked before my upgrade to jhipster 8.1.0, so I suspect this is a regression.
Motivation for or Use Case
Previous new projects have allowed
admin
anduser
accounts to login with no issuesReproduce the error
Run
jhipster
at the command line. Answer questions as follows:? What is the base name of your application? sample
? Which type of application would you like to create? Monolithic application (recommended for simple projects)
? Do you want to generate a feign client? No
? Besides Junit, which testing frameworks would you like to use?
? Do you want to make it reactive with Spring WebFlux? No
? What is your default Java package name? com.mycompany.myapp
? Which type of authentication would you like to use? JWT authentication (stateless, with a token)
? Which type of database would you like to use? SQL (H2, PostgreSQL, MySQL, MariaDB, Oracle, MSSQL)
? Which production database would you like to use? PostgreSQL
? Which development database would you like to use? H2 with disk-based persistence
? Which cache do you want to use? (Spring cache abstraction) No cache - Warning, when using an SQL database, this will disable the Hibernate 2nd level cache!
? Would you like to use Maven or Gradle for building the backend? Maven
? Which other technologies would you like to use? API first development using OpenAPI-generator
INFO! Disabling hibernate cache for cache provider no
? Which Framework would you like to use for the client? Vue <-- also fails w/ Angular (didn't test React)
? Besides Jest/Vitest, which testing frameworks would you like to use?
? Do you want to generate the admin UI? Yes
? Would you like to use a Bootswatch theme (https://bootswatch.com/)? Default JHipster
? Would you like to enable internationalization support? Yes
? Please choose the native language of the application English
? Please choose additional languages to install Spanish
info Generating 2,048 bit RSA key pair and self-signed certificate (SHA256withRSA) with a validity of 99,999 days
........
And then
./mvnw
and attempt to login at http://localhost:8080/Related issues
None
Suggest a Fix
I'll
JHipster Version(s)
JHipster configuration
JHipster configuration, a
.yo-rc.json
file generated in the root folder.yo-rc.json file
Environment and Tools
openjdk version "17.0.9" 2023-10-17
OpenJDK Runtime Environment GraalVM CE 17.0.9+9.1 (build 17.0.9+9-jvmci-23.0-b22)
OpenJDK 64-Bit Server VM GraalVM CE 17.0.9+9.1 (build 17.0.9+9-jvmci-23.0-b22, mixed mode, sharing)
git version 2.39.2
node: v18.18.2
npm: 10.2.5
Docker version 24.0.7, build afdd53b
JDL for the Entity configuration(s)
entityName.json
files generated in the.jhipster
directoryJDL entity definitions
Entity configuration(s)
entityName.json
files generated in the.jhipster
directoryNone created yet
Browsers and Operating System
lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 12 (bookworm)
Release: 12
Codename: bookworm
uname -a ──(Mon,Dec18)─┘
Linux pluto 6.1.0-13-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.55-1 (2023-09-29) x86_64 GNU/Linux
Browser:
Google Chrome
Version 119.0.6045.159 (Official Build) (64-bit)
The text was updated successfully, but these errors were encountered: