generator-jhipster 8.7.2 → 8.7.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -18,9 +18,9 @@ We are honored by any contributions you may have small or large. Please refer to
18
18
 
19
19
  The following Java and Node combinations are tested and verified by GitHub Actions:
20
20
 
21
- | Java | Node | Status |
22
- | -------- | ----- | ------ |
23
- | 17/21/23 | 18/20 | ✅ |
21
+ | Java | Node | Status |
22
+ | -------- | -------- | ------ |
23
+ | 17/21/23 | 18/20/22 | ✅ |
24
24
 
25
25
  ## Sponsors
26
26
 
@@ -48,7 +48,7 @@
48
48
  "rimraf": "5.0.8",
49
49
  "ts-jest": "29.2.5",
50
50
  "typescript": "5.5.4",
51
- "typescript-eslint": "8.11.0",
51
+ "typescript-eslint": "8.12.2",
52
52
  "webpack": "5.95.0",
53
53
  "webpack-bundle-analyzer": "4.10.2",
54
54
  "webpack-merge": "6.0.1",
@@ -56,9 +56,7 @@ export type HealthKey =
56
56
 
57
57
  export interface Health {
58
58
  status: HealthStatus;
59
- components: {
60
- [key in HealthKey]?: HealthDetails;
61
- };
59
+ components?: Partial<Record<HealthKey, HealthDetails>>;
62
60
  }
63
61
 
64
62
  export interface HealthDetails {
@@ -92,12 +92,7 @@ export interface GarbageCollector {
92
92
  classesUnloaded: number;
93
93
  }
94
94
 
95
- export type Services = Record<
96
- string,
97
- {
98
- [key in HttpMethod]?: MaxMeanCount;
99
- }
100
- >;
95
+ export type Services = Record<string, Record<HttpMethod, MaxMeanCount>>;
101
96
 
102
97
  export enum HttpMethod {
103
98
  Post = 'POST',
@@ -3,7 +3,7 @@
3
3
  "dayjs": "1.11.13"
4
4
  },
5
5
  "devDependencies": {
6
- "@cypress/code-coverage": "3.13.4",
6
+ "@cypress/code-coverage": "3.13.5",
7
7
  "babel-loader": "9.2.1",
8
8
  "babel-plugin-istanbul": "7.0.0",
9
9
  "cypress": "13.15.1",
@@ -56,7 +56,7 @@ sonar.issue.ignore.multicriteria=\
56
56
  <%_ if (authenticationTypeJwt) { _%>
57
57
  S4502,\
58
58
  <%_ } _%>
59
- S4684,S5145,UndocumentedApi
59
+ S4684,S5145,S7027-domain,S7027-dto,UndocumentedApi
60
60
 
61
61
  <%_ if (backendTypeSpringBoot) { _%>
62
62
  # Rule https://rules.sonarsource.com/java/RSPEC-6437 is ignored, hardcoded passwords are provided for development purposes
@@ -65,25 +65,31 @@ sonar.issue.ignore.multicriteria.S6437.ruleKey=java:S6437
65
65
  <%_ } _%>
66
66
  <%_ if (gatlingTests) { _%>
67
67
  # Rule https://rules.sonarsource.com/java/RSPEC-2187 is ignored, gatling tests are not supported by sonar
68
- sonar.issue.ignore.multicriteria.S2187.resourceKey=<%= TEST_DIR %>java/gatling/**/*
68
+ sonar.issue.ignore.multicriteria.S2187.resourceKey= <%- srcTestJava %>gatling/**/*
69
69
  sonar.issue.ignore.multicriteria.S2187.ruleKey=java:S2187
70
70
  <%_ } _%>
71
71
  # Rule https://rules.sonarsource.com/java/RSPEC-3437 is ignored, as a JPA-managed field cannot be transient
72
- sonar.issue.ignore.multicriteria.S3437.resourceKey=<%= MAIN_DIR %>java/**/*
72
+ sonar.issue.ignore.multicriteria.S3437.resourceKey= <%- srcMainJava %>**/*
73
73
  sonar.issue.ignore.multicriteria.S3437.ruleKey=squid:S3437
74
74
  <%_ if (authenticationTypeJwt) { _%>
75
75
  # Rule https://rules.sonarsource.com/java/RSPEC-4502 is ignored, as for JWT tokens we are not subject to CSRF attack
76
- sonar.issue.ignore.multicriteria.S4502.resourceKey=<%= MAIN_DIR %>java/**/*
76
+ sonar.issue.ignore.multicriteria.S4502.resourceKey= <%- srcMainJava %>**/*
77
77
  sonar.issue.ignore.multicriteria.S4502.ruleKey=java:S4502
78
78
  <%_ } _%>
79
79
  # Rule https://rules.sonarsource.com/java/RSPEC-4684
80
- sonar.issue.ignore.multicriteria.S4684.resourceKey=<%= MAIN_DIR %>java/**/*
80
+ sonar.issue.ignore.multicriteria.S4684.resourceKey= <%- srcMainJava %>**/*
81
81
  sonar.issue.ignore.multicriteria.S4684.ruleKey=java:S4684
82
82
  # Rule https://rules.sonarsource.com/java/RSPEC-5145 log filter is applied
83
- sonar.issue.ignore.multicriteria.S5145.resourceKey=<%= MAIN_DIR %>java/**/*
83
+ sonar.issue.ignore.multicriteria.S5145.resourceKey= <%- srcMainJava %>**/*
84
84
  sonar.issue.ignore.multicriteria.S5145.ruleKey=javasecurity:S5145
85
+ # Rule https://rules.sonarsource.com/java/RSPEC-7027 is ignored for entities
86
+ sonar.issue.ignore.multicriteria.S7027-domain.resourceKey = <%- srcMainJava %><%- packageFolder %>domain/**/*
87
+ sonar.issue.ignore.multicriteria.S7027-domain.ruleKey = javaarchitecture:S7027
88
+ # Rule https://rules.sonarsource.com/java/RSPEC-7027 is ignored for dtos
89
+ sonar.issue.ignore.multicriteria.S7027-dto.resourceKey = <%- srcMainJava %><%- packageFolder %>service/dto/**/*
90
+ sonar.issue.ignore.multicriteria.S7027-dto.ruleKey = javaarchitecture:S7027
85
91
  # Rule https://rules.sonarsource.com/java/RSPEC-1176 is ignored, as we want to follow "clean code" guidelines and classes, methods and arguments names should be self-explanatory
86
- sonar.issue.ignore.multicriteria.UndocumentedApi.resourceKey=<%= MAIN_DIR %>java/**/*
92
+ sonar.issue.ignore.multicriteria.UndocumentedApi.resourceKey= <%- srcMainJava %>**/*
87
93
  sonar.issue.ignore.multicriteria.UndocumentedApi.ruleKey=squid:UndocumentedApi
88
94
  <%_ } _%>
89
95
  <%_ if (cacheProviderAny) { _%>
@@ -23,8 +23,8 @@ import {
23
23
  } from '../../support/commands';
24
24
 
25
25
  describe('logout', () => {
26
- const username = Cypress.env('E2E_USERNAME') ?? 'user';
27
- const password = Cypress.env('E2E_PASSWORD') ?? 'user';
26
+ const username = Cypress.env('E2E_USERNAME') ?? '<%- generateInMemoryUserCredentials ? 'admin' : 'user' %>';
27
+ const password = Cypress.env('E2E_PASSWORD') ?? '<%- generateInMemoryUserCredentials ? 'admin' : 'user' %>';
28
28
 
29
29
  it<%- clientFrameworkReact ? '.skip' : '' %>('go to home page when successfully logs out', () => {
30
30
  cy.login(username, password);
@@ -1 +1 @@
1
- 20.18.0
1
+ 22.11.0
@@ -25,7 +25,7 @@
25
25
  "sockjs-client": "1.6.1",
26
26
  "sonar-scanner": "3.1.0",
27
27
  "tslib": "2.8.0",
28
- "uuid": "11.0.1",
28
+ "uuid": "11.0.2",
29
29
  "webstomp-client": "1.2.6"
30
30
  },
31
31
  "devDependencies": {
@@ -34,7 +34,7 @@
34
34
  "@module-federation/utilities": "3.1.19",
35
35
  "@testing-library/react": "16.0.1",
36
36
  "@types/jest": "29.5.14",
37
- "@types/lodash": "4.17.12",
37
+ "@types/lodash": "4.17.13",
38
38
  "@types/node": "20.11.25",
39
39
  "@types/react": "18.3.12",
40
40
  "@types/react-dom": "18.3.1",
@@ -82,12 +82,12 @@
82
82
  "ts-jest": "29.2.5",
83
83
  "ts-loader": "9.5.1",
84
84
  "typescript": "5.6.3",
85
- "typescript-eslint": "8.11.0",
85
+ "typescript-eslint": "8.12.2",
86
86
  "webpack": "5.95.0",
87
87
  "webpack-cli": "5.1.4",
88
88
  "webpack-dev-server": "5.1.0",
89
89
  "webpack-merge": "6.0.1",
90
90
  "webpack-notifier": "1.15.0",
91
- "workbox-webpack-plugin": "7.1.0"
91
+ "workbox-webpack-plugin": "7.3.0"
92
92
  }
93
93
  }
@@ -3,7 +3,7 @@ export default class SpringBootGenerator extends BaseApplicationGenerator {
3
3
  fakeKeytool: any;
4
4
  beforeQueue(): Promise<void>;
5
5
  get prompting(): import("../../lib/types/base/tasks.js").GenericTaskGroup<any, import("../../lib/types/base/tasks.js").TaskParamWithControl, "askForServerTestOpts" | "askForServerSideOpts" | "askForOptionalItems">;
6
- get configuring(): import("../../lib/types/base/tasks.js").GenericTaskGroup<any, import("../../lib/types/base/tasks.js").TaskParamWithControl, "checks" | "feignMigration">;
6
+ get configuring(): import("../../lib/types/base/tasks.js").GenericTaskGroup<any, import("../../lib/types/base/tasks.js").TaskParamWithControl, "feignMigration">;
7
7
  get composing(): import("../../lib/types/base/tasks.js").GenericTaskGroup<any, import("../../lib/types/base/tasks.js").TaskParamWithControl, "composing">;
8
8
  get composingComponent(): import("../../lib/types/base/tasks.js").GenericTaskGroup<any, import("../../lib/types/base/tasks.js").TaskParamWithControl, "composing" | "composeLanguages">;
9
9
  get preparing(): import("../../lib/types/base/tasks.js").GenericTaskGroup<any, import("../../lib/types/application/tasks.js").PreparingTaskParam<import("../base-application/index.js").Entity<import("../base-application/index.js").Field, never>, import("../../lib/types/application/application.js").ApplicationType<import("../base-application/index.js").Entity<import("../base-application/index.js").Field, never>>>, "prepareForTemplates" | "prepare" | "checksWebsocket" | "loadSpringBootBom" | "registerSpringFactory" | "addSpringIntegrationTest" | "addLogNeedles" | "addApplicationPropertiesNeedles">;
@@ -31,7 +31,7 @@ import { writeFiles as writeEntityFiles } from './entity-files.js';
31
31
  import cleanupTask from './cleanup.js';
32
32
  import { serverFiles } from './files.js';
33
33
  import { askForOptionalItems, askForServerSideOpts, askForServerTestOpts } from './prompts.js';
34
- const { CAFFEINE, EHCACHE, HAZELCAST, INFINISPAN, MEMCACHED, REDIS, NO: NO_CACHE } = cacheTypes;
34
+ const { CAFFEINE, EHCACHE, HAZELCAST, INFINISPAN, MEMCACHED, REDIS } = cacheTypes;
35
35
  const { NO: NO_WEBSOCKET, SPRING_WEBSOCKET } = websocketTypes;
36
36
  const { CASSANDRA, COUCHBASE, MONGODB, NEO4J, SQL } = databaseTypes;
37
37
  const { MICROSERVICE, GATEWAY } = applicationTypes;
@@ -63,13 +63,6 @@ export default class SpringBootGenerator extends BaseApplicationGenerator {
63
63
  }
64
64
  get configuring() {
65
65
  return this.asConfiguringTaskGroup({
66
- checks() {
67
- const config = this.jhipsterConfigWithDefaults;
68
- if (config.enableHibernateCache && [NO_CACHE, MEMCACHED].includes(config.cacheProvider)) {
69
- this.log.verboseInfo(`Disabling hibernate cache for cache provider ${config.cacheProvider}`);
70
- this.jhipsterConfig.enableHibernateCache = false;
71
- }
72
- },
73
66
  feignMigration() {
74
67
  const { reactive, applicationType, feignClient } = this.jhipsterConfigWithDefaults;
75
68
  if (feignClient) {
@@ -33,10 +33,14 @@ export default class SpringCacheGenerator extends BaseApplicationGenerator {
33
33
  get configuring() {
34
34
  return this.asConfiguringTaskGroup({
35
35
  configure() {
36
- const { databaseType, reactive } = this.jhipsterConfigWithDefaults;
36
+ const { databaseType, reactive, cacheProvider } = this.jhipsterConfigWithDefaults;
37
37
  if (this.jhipsterConfig.enableHibernateCache && (reactive || databaseType !== 'sql')) {
38
+ this.log.verboseInfo(`Disabling hibernate cache for ${reactive ? 'reactive application' : 'non-SQL databases'}`);
38
39
  this.jhipsterConfig.enableHibernateCache = undefined;
39
40
  }
41
+ if (reactive && cacheProvider !== 'no') {
42
+ this.log.error(`Cache provider is not supported in reactive application`);
43
+ }
40
44
  },
41
45
  });
42
46
  }
@@ -13,7 +13,7 @@
13
13
  "bootswatch": "4.6.2",
14
14
  "deepmerge": "4.3.1",
15
15
  "js-cookie": "3.0.5",
16
- "pinia": "2.2.4",
16
+ "pinia": "2.2.5",
17
17
  "rxjs": "7.8.1",
18
18
  "sockjs-client": "1.6.1",
19
19
  "vue": "3.5.12",
@@ -39,7 +39,7 @@
39
39
  "css-minimizer-webpack-plugin": "7.0.0",
40
40
  "eslint": "9.13.0",
41
41
  "eslint-plugin-prettier": "5.2.1",
42
- "eslint-plugin-vue": "9.29.1",
42
+ "eslint-plugin-vue": "9.30.0",
43
43
  "flush-promises": "1.0.2",
44
44
  "folder-hash": "4.0.4",
45
45
  "happy-dom": "14.12.3",
@@ -57,10 +57,10 @@
57
57
  "terser-webpack-plugin": "5.3.10",
58
58
  "ts-loader": "9.5.1",
59
59
  "typescript": "5.6.3",
60
- "typescript-eslint": "8.11.0",
60
+ "typescript-eslint": "8.12.2",
61
61
  "vite": "5.4.10",
62
62
  "vite-plugin-static-copy": "2.0.0",
63
- "vitest": "2.1.3",
63
+ "vitest": "2.1.4",
64
64
  "vitest-sonar-reporter": "2.0.0",
65
65
  "vue-loader": "17.4.2",
66
66
  "vue-style-loader": "4.1.3",
@@ -70,6 +70,6 @@
70
70
  "webpack-cli": "5.1.4",
71
71
  "webpack-dev-server": "5.1.0",
72
72
  "webpack-merge": "6.0.1",
73
- "workbox-webpack-plugin": "7.1.0"
73
+ "workbox-webpack-plugin": "7.3.0"
74
74
  }
75
75
  }
@@ -28,9 +28,7 @@ export declare const rulesNames: {
28
28
  ENUM_UNUSED: string;
29
29
  };
30
30
  type RuleNames = keyof typeof rulesNames;
31
- export declare const rules: {
32
- [key in RuleNames]: Rule;
33
- };
31
+ export declare const rules: Record<RuleNames, Rule>;
34
32
  /**
35
33
  * Gets and returns the rule having the passed name.
36
34
  * @param ruleName - the name of the rule to fetch
@@ -31,7 +31,7 @@ const { OptionNames, OptionValues } = applicationOptions;
31
31
  const { JWT, OAUTH2 } = authenticationTypes;
32
32
  const { ANGULAR, NO: NO_CLIENT_FRAMEWORK } = clientFrameworkTypes;
33
33
  const { EHCACHE, HAZELCAST } = cacheTypes;
34
- const NO_CACHE_PROVIDER = cacheTypes.NO;
34
+ const { NO: NO_CACHE_PROVIDER, MEMCACHED } = cacheTypes;
35
35
  const NO_SERVICE_DISCOVERY = serviceDiscoveryTypes.NO;
36
36
  const { MAVEN } = buildToolTypes;
37
37
  const { APPLICATION_TYPE, AUTHENTICATION_TYPE, BASE_NAME, BUILD_TOOL, CACHE_PROVIDER, CLIENT_FRAMEWORK, CLIENT_THEME, CLIENT_THEME_VARIANT, WITH_ADMIN_UI, DATABASE_TYPE, DEV_DATABASE_TYPE, DTO_SUFFIX, ENABLE_HIBERNATE_CACHE, ENABLE_SWAGGER_CODEGEN, ENABLE_TRANSLATION, ENTITY_SUFFIX, JHI_PREFIX, LANGUAGES, NATIVE_LANGUAGE, PACKAGE_FOLDER, PACKAGE_NAME, PROD_DATABASE_TYPE, REACTIVE, SEARCH_ENGINE, SERVER_PORT, SERVICE_DISCOVERY_TYPE, SKIP_CLIENT, SKIP_USER_MANAGEMENT, TEST_FRAMEWORKS, WEBSOCKET, ENABLE_GRADLE_ENTERPRISE, GRADLE_ENTERPRISE_HOST, } = OptionNames;
@@ -113,7 +113,8 @@ export function getConfigForCacheProvider(options = {}) {
113
113
  if (options[REACTIVE] || options[CACHE_PROVIDER] === undefined) {
114
114
  options[CACHE_PROVIDER] = NO_CACHE_PROVIDER;
115
115
  }
116
- options[ENABLE_HIBERNATE_CACHE] ??= options[DATABASE_TYPE] === SQL && !options[REACTIVE] && options[CACHE_PROVIDER] !== NO_CACHE_PROVIDER;
116
+ options[ENABLE_HIBERNATE_CACHE] ??=
117
+ options[DATABASE_TYPE] === SQL && !options[REACTIVE] && ![NO_CACHE_PROVIDER, MEMCACHED].includes(options[CACHE_PROVIDER]);
117
118
  return options;
118
119
  }
119
120
  export function getConfigForReactive(options = {}) {
@@ -2,7 +2,7 @@ import { createHash } from 'node:crypto';
2
2
  import { readFileSync } from 'node:fs';
3
3
  import { join } from 'node:path';
4
4
  import { RECOMMENDED_JAVA_VERSION, RECOMMENDED_NODE_VERSION } from '../../generators/index.js';
5
- import { getPackageRoot } from '../index.js';
5
+ import { getSourceRoot } from '../index.js';
6
6
  import { JAVA_COMPATIBLE_VERSIONS, JAVA_VERSION, NODE_VERSION } from '../../generators/generator-constants.js';
7
7
  const knwonGitHubMatrixProperties = [
8
8
  'os',
@@ -27,7 +27,7 @@ export const getUnknownGitHubMatrixGroupProperties = (matrixRecord) => {
27
27
  }
28
28
  return unknownProperties;
29
29
  };
30
- const NPM_VERSION = JSON.parse(readFileSync(join(getPackageRoot(), 'generators/common/resources/package.json'), 'utf-8')).devDependencies
30
+ const NPM_VERSION = JSON.parse(readFileSync(join(getSourceRoot(), 'generators/common/resources/package.json'), 'utf-8')).devDependencies
31
31
  .npm;
32
32
  export const defaultGithubEnvironment = {
33
33
  os: 'ubuntu-latest',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "generator-jhipster",
3
- "version": "8.7.2",
3
+ "version": "8.7.3",
4
4
  "description": "Spring Boot + Angular/React/Vue in one handy generator",
5
5
  "keywords": [
6
6
  "yeoman-generator",
@@ -142,7 +142,7 @@
142
142
  "eslint": "9.13.0",
143
143
  "eslint-plugin-import-x": "4.3.1",
144
144
  "eslint-plugin-unused-imports": "4.1.4",
145
- "execa": "9.5.0",
145
+ "execa": "9.5.1",
146
146
  "fast-xml-parser": "4.5.0",
147
147
  "glob": "10.4.2",
148
148
  "globals": "15.11.0",
@@ -169,14 +169,14 @@
169
169
  "sort-keys": "5.1.0",
170
170
  "type-fest": "4.26.1",
171
171
  "typescript": "5.5.4",
172
- "typescript-eslint": "8.11.0",
172
+ "typescript-eslint": "8.12.2",
173
173
  "yaml": "2.6.0",
174
174
  "yeoman-environment": "4.4.3",
175
175
  "yeoman-generator": "7.3.3"
176
176
  },
177
177
  "devDependencies": {
178
178
  "@actions/core": "1.11.1",
179
- "@eslint/core": "0.7.0",
179
+ "@eslint/core": "0.8.0",
180
180
  "@node-loaders/esbuild": "2.0.0",
181
181
  "@types/chai": "4.3.16",
182
182
  "@types/estree": "1.0.6",