jhipster / generator-jhipster

JHipster is a development platform to quickly generate, develop, & deploy modern web applications & microservice architectures.
https://www.jhipster.tech
Apache License 2.0
21.53k stars 4.02k forks source link

LazyInitialization failed to lazily initialize a collection: could not initialize proxy - no Session #21434

Closed igortregub closed 9 months ago

igortregub commented 1 year ago
Overview of the issue

I tried to create and test application using latest version of jhipster-generator (from main branch), but I've got issue when tried to execute tests

[ERROR] Errors: 
[ERROR]   DomainUserDetailsServiceIT.assertThatUserCanBeFoundByLogin:75 » LazyInitialization failed to lazily initialize a collection: could not initialize proxy - no Session
[ERROR]   PublicUserResourceIT.setup:49 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   PublicUserResourceIT.setup:49 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   PublicUserResourceIT.setup:49 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
[ERROR]   UserResourceIT.setup:81 » Cache org.redisson.client.RedisException: Unexpected exception while processing command
Reproduce the error

./mvnw -ntp verify -P-webapp

JHipster Version(s)

dev version from main branch

JHipster configuration
.yo-rc.json file
{
  "applicationIndex": 0,
  "applicationType": "monolith",
  "authenticationType": "jwt",
  "baseName": "Test",
  "blueprints": [],
  "buildTool": "maven",
  "cacheProvider": "redis",
  "clientFramework": "react",
  "clientPackageManager": "npm",
  "clientTheme": "none",
  "clientThemeVariant": "",
  "creationTimestamp": 1678913585184,
  "databaseType": "sql",
  "devDatabaseType": "mariadb",
  "devServerPort": 9060,
  "dtoSuffix": "DTO",
  "enableGradleEnterprise": false,
  "enableHibernateCache": true,
  "enableSwaggerCodegen": false,
  "enableTranslation": true,
  "entities": [],
  "entitySuffix": "",
  "gradleEnterpriseHost": "",
  "incrementalChangelog": true,
  "jhiPrefix": "jhi",
  "jhipsterVersion": "7.9.3",
  "languages": [
    "en",
    "ru"
  ],
  "messageBroker": false,
  "nativeLanguage": "en",
  "otherModules": [],
  "packageFolder": "dev/test/test",
  "packageName": "dev.test.test",
  "pages": [],
  "prodDatabaseType": "mariadb",
  "reactive": false,
  "searchEngine": false,
  "serverPort": "8080",
  "serviceDiscoveryType": false,
  "skipCheckLengthOfIdentifier": false,
  "skipClient": false,
  "skipFakeData": false,
  "skipUserManagement": false,
  "testFrameworks": [],
  "websocket": false,
  "withAdminUi": true
}
Environment and Tools

openjdk version "17.0.6" 2023-01-17 OpenJDK Runtime Environment GraalVM CE 22.3.1 (build 17.0.6+10-jvmci-22.3-b13) OpenJDK 64-Bit Server VM GraalVM CE 22.3.1 (build 17.0.6+10-jvmci-22.3-b13, mixed mode, sharing)

git version 2.40.0

node: v16.19.1 npm: 8.19.3

Docker version 20.10.22, build 3a2c30b

JDL for the Entity configuration(s) entityName.json files generated in the .jhipster directory
JDL entity definitions

mshima commented 1 year ago

Redis and infinispan are currently broken at main. See https://github.com/jhipster/generator-jhipster/pull/20398.

igortregub commented 1 year ago

Hello, is there any changes or update relating to the issue with redis? Thank you

github-actions[bot] commented 11 months ago

JHipster has completed the sample check .yo-rc.json: valid Entities JDL: blank Application: successfully generated Frontend check: success Backend check: failure E2E check: success

mshima commented 9 months ago

Closing if favor of https://github.com/jhipster/generator-jhipster/issues/22889

mshima commented 9 months ago

Duplicated of https://github.com/jhipster/generator-jhipster/issues/22889