generator-jhipster 7.9.0 → 7.9.1
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/cli/jhipster.js +0 -0
- package/generators/client/templates/angular/package.json +2 -2
- package/generators/client/templates/angular/src/main/webapp/app/admin/gateway/gateway.component.ts.ejs +14 -0
- package/generators/client/templates/common/package.json +3 -3
- package/generators/client/templates/react/package.json +5 -5
- package/generators/client/templates/react/src/main/webapp/app/index.tsx.ejs +4 -5
- package/generators/client/templates/react/src/main/webapp/app/modules/administration/gateway/gateway.tsx.ejs +9 -1
- package/generators/client/templates/vue/package.json +2 -2
- package/generators/client/templates/vue/src/main/webapp/app/admin/gateway/gateway.component.ts.ejs +14 -0
- package/generators/common/templates/.husky/pre-commit.ejs +0 -0
- package/generators/generate-blueprint/esm.mjs +0 -0
- package/generators/generate-blueprint/templates/cli/cli.mjs.ejs +0 -0
- package/generators/generate-blueprint/templates/generators/generator/templates/template-file.ejs +0 -0
- package/generators/generator-constants.js +1 -1
- package/generators/init/templates/.husky/pre-commit +0 -0
- package/generators/kubernetes/templates/kubectl-apply.sh.ejs +0 -0
- package/generators/kubernetes-knative/templates/kubectl-apply.sh.ejs +0 -0
- package/generators/maven/templates/mvnw +0 -0
- package/generators/server/templates/gradlew +0 -0
- package/generators/server/templates/mvnw +0 -0
- package/generators/server/templates/npmw +0 -0
- package/generators/server/templates/src/main/resources/config/application-prod.yml.ejs +1 -1
- package/package.json +2 -2
- package/utils/field.js +6 -8
package/cli/jhipster.js
CHANGED
|
File without changes
|
|
@@ -24,11 +24,11 @@
|
|
|
24
24
|
"@angular-eslint/eslint-plugin": "14.0.2",
|
|
25
25
|
"@types/node": "16.11.47",
|
|
26
26
|
"@types/jest": "28.1.6",
|
|
27
|
-
"@typescript-eslint/eslint-plugin": "5.
|
|
27
|
+
"@typescript-eslint/eslint-plugin": "5.32.0",
|
|
28
28
|
"browser-sync": "2.27.10",
|
|
29
29
|
"browser-sync-webpack-plugin": "2.3.0",
|
|
30
30
|
"copy-webpack-plugin": "11.0.0",
|
|
31
|
-
"eslint": "8.
|
|
31
|
+
"eslint": "8.21.0",
|
|
32
32
|
"eslint-config-prettier": "8.5.0",
|
|
33
33
|
"eslint-webpack-plugin": "3.2.0",
|
|
34
34
|
"folder-hash": "4.0.2",
|
|
@@ -39,6 +39,20 @@ export class GatewayComponent implements OnInit {
|
|
|
39
39
|
refresh(): void {
|
|
40
40
|
this.updatingRoutes = true;
|
|
41
41
|
this.gatewayRoutesService.findAll().subscribe(gatewayRoutes => {
|
|
42
|
+
<%_ if (serviceDiscoveryType === 'consul') { _%>
|
|
43
|
+
gatewayRoutes.serviceInstances = gatewayRoutes.serviceInstances.map(serviceInstance => {
|
|
44
|
+
if (serviceInstance.healthService && serviceInstance.healthService.checks) {
|
|
45
|
+
if (serviceInstance.healthService.checks.filter(
|
|
46
|
+
check => check.status === 'PASSING'
|
|
47
|
+
).length === serviceInstance.healthService.checks.length) {
|
|
48
|
+
serviceInstance.instanceInfo.status = 'UP'
|
|
49
|
+
} else {
|
|
50
|
+
serviceInstance.instanceInfo.status = 'DOWN'
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
return serviceInstance;
|
|
54
|
+
});
|
|
55
|
+
<%_ } _%>
|
|
42
56
|
this.gatewayRoutes = gatewayRoutes;
|
|
43
57
|
this.updatingRoutes = false;
|
|
44
58
|
});
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
"@cypress/code-coverage": "3.10.0",
|
|
4
4
|
"babel-loader": "8.2.5",
|
|
5
5
|
"babel-plugin-istanbul": "6.1.1",
|
|
6
|
-
"cypress": "10.
|
|
6
|
+
"cypress": "10.4.0",
|
|
7
7
|
"cypress-audit": "1.1.0",
|
|
8
8
|
"eslint-plugin-cypress": "2.12.1",
|
|
9
|
-
"lighthouse": "9.6.
|
|
9
|
+
"lighthouse": "9.6.5",
|
|
10
10
|
"nyc": "15.1.0",
|
|
11
|
-
"swagger-ui-dist": "4.13.
|
|
11
|
+
"swagger-ui-dist": "4.13.1"
|
|
12
12
|
},
|
|
13
13
|
"dependencies": {
|
|
14
14
|
"dayjs": "1.11.4"
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"react-redux-loading-bar": "5.0.4",
|
|
19
19
|
"react-router-dom": "6.3.0",
|
|
20
20
|
"react-toastify": "9.0.7",
|
|
21
|
-
"react-transition-group": "4.4.
|
|
21
|
+
"react-transition-group": "4.4.5",
|
|
22
22
|
"reactstrap": "9.1.2",
|
|
23
23
|
"redux": "4.2.0",
|
|
24
24
|
"redux-thunk": "2.4.1",
|
|
@@ -36,8 +36,8 @@
|
|
|
36
36
|
"@types/react-redux": "7.1.24",
|
|
37
37
|
"@types/redux": "3.6.31",
|
|
38
38
|
"@types/webpack-env": "1.17.0",
|
|
39
|
-
"@typescript-eslint/eslint-plugin": "5.
|
|
40
|
-
"@typescript-eslint/parser": "5.
|
|
39
|
+
"@typescript-eslint/eslint-plugin": "5.32.0",
|
|
40
|
+
"@typescript-eslint/parser": "5.32.0",
|
|
41
41
|
"autoprefixer": "10.4.8",
|
|
42
42
|
"browser-sync": "2.27.10",
|
|
43
43
|
"browser-sync-webpack-plugin": "2.3.0",
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"cross-env": "7.0.3",
|
|
47
47
|
"css-loader": "6.7.1",
|
|
48
48
|
"css-minimizer-webpack-plugin": "4.0.0",
|
|
49
|
-
"eslint": "8.
|
|
49
|
+
"eslint": "8.21.0",
|
|
50
50
|
"eslint-config-prettier": "8.5.0",
|
|
51
51
|
"eslint-plugin-react": "7.30.1",
|
|
52
52
|
"eslint-webpack-plugin": "3.2.0",
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
"react-infinite-scroll-component": "6.1.0",
|
|
67
67
|
"redux-mock-store": "1.5.4",
|
|
68
68
|
"rimraf": "3.0.2",
|
|
69
|
-
"sass": "1.54.
|
|
69
|
+
"sass": "1.54.1",
|
|
70
70
|
"sass-loader": "13.0.2",
|
|
71
71
|
"simple-progress-webpack-plugin": "2.0.0",
|
|
72
72
|
"sinon": "14.0.0",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
limitations under the License.
|
|
18
18
|
-%>
|
|
19
19
|
import React from 'react';
|
|
20
|
-
import
|
|
20
|
+
import { createRoot } from 'react-dom/client';
|
|
21
21
|
import { Provider } from 'react-redux';
|
|
22
22
|
import { bindActionCreators } from 'redux';
|
|
23
23
|
|
|
@@ -42,18 +42,17 @@ setupAxiosInterceptors(() => actions.clearAuthentication('login.error.unauthoriz
|
|
|
42
42
|
loadIcons();
|
|
43
43
|
|
|
44
44
|
const rootEl = document.getElementById('root');
|
|
45
|
+
const root = createRoot(rootEl);
|
|
45
46
|
|
|
46
47
|
const render = Component =>
|
|
47
|
-
|
|
48
|
-
ReactDOM.render(
|
|
48
|
+
root.render(
|
|
49
49
|
<ErrorBoundary>
|
|
50
50
|
<Provider store={store}>
|
|
51
51
|
<div>
|
|
52
52
|
<Component />
|
|
53
53
|
</div>
|
|
54
54
|
</Provider>
|
|
55
|
-
</ErrorBoundary
|
|
56
|
-
rootEl
|
|
55
|
+
</ErrorBoundary>
|
|
57
56
|
);
|
|
58
57
|
|
|
59
58
|
render(AppComponent);
|
|
@@ -50,11 +50,19 @@ export const GatewayPage = () => {
|
|
|
50
50
|
|
|
51
51
|
const badgeInfo = info => {
|
|
52
52
|
if (info) {
|
|
53
|
+
<%_ if (serviceDiscoveryType === 'consul') { _%>
|
|
54
|
+
if (info.checks && info.checks.filter(check => check.status === 'PASSING').length === info.checks.length) {
|
|
55
|
+
return <Badge color="success">UP</Badge>;
|
|
56
|
+
} else {
|
|
57
|
+
return <Badge color="danger">DOWN</Badge>;
|
|
58
|
+
}
|
|
59
|
+
<%_ } else { _%>
|
|
53
60
|
if (info.status === 'UP') {
|
|
54
61
|
return <Badge color="success">{info.status}</Badge>;
|
|
55
62
|
} else {
|
|
56
63
|
return <Badge color="danger">{info.status}</Badge>;
|
|
57
64
|
}
|
|
65
|
+
<%_ } _%>
|
|
58
66
|
} else {
|
|
59
67
|
return <Badge color="warning">?</Badge>;
|
|
60
68
|
}
|
|
@@ -68,7 +76,7 @@ export const GatewayPage = () => {
|
|
|
68
76
|
{route.serviceInstances.map((instance, i) =>
|
|
69
77
|
<tr key={instance.instanceInfo + '-info'}>
|
|
70
78
|
<td><a href={instance.uri} target="_blank" rel="noopener noreferrer">{instance.uri}</a></td>
|
|
71
|
-
<td>{badgeInfo(instance.instanceInfo)}</td>
|
|
79
|
+
<td>{badgeInfo(<% if (serviceDiscoveryType === 'consul') { %>instance.healthService<% } else { %>instance.instanceInfo<% } %>)}</td>
|
|
72
80
|
<td>{metadata(instance.metadata)}</td>
|
|
73
81
|
</tr>
|
|
74
82
|
)}
|
|
@@ -50,13 +50,13 @@
|
|
|
50
50
|
"postcss-loader": "7.0.1",
|
|
51
51
|
"postcss-url": "10.1.3",
|
|
52
52
|
"rimraf": "3.0.2",
|
|
53
|
-
"sass": "1.54.
|
|
53
|
+
"sass": "1.54.1",
|
|
54
54
|
"sass-loader": "13.0.2",
|
|
55
55
|
"sinon": "14.0.0",
|
|
56
56
|
"terser-webpack-plugin": "5.3.3",
|
|
57
57
|
"ts-jest": "28.0.7",
|
|
58
58
|
"ts-loader": "9.3.1",
|
|
59
|
-
"eslint": "8.
|
|
59
|
+
"eslint": "8.21.0",
|
|
60
60
|
"eslint-plugin-prettier": "4.2.1",
|
|
61
61
|
"eslint-plugin-vue": "8.7.1",
|
|
62
62
|
"typescript": "4.7.4",
|
package/generators/client/templates/vue/src/main/webapp/app/admin/gateway/gateway.component.ts.ejs
CHANGED
|
@@ -16,6 +16,20 @@ export default class <%=jhiPrefixCapitalized%>GatewayComponent extends Vue {
|
|
|
16
16
|
this.updatingRoutes = true;
|
|
17
17
|
this.gatewayService().findAll().then((res) => {
|
|
18
18
|
this.gatewayRoutes = res.data;
|
|
19
|
+
<%_ if (serviceDiscoveryType === 'consul') { _%>
|
|
20
|
+
this.gatewayRoutes.serviceInstances = this.gatewayRoutes.serviceInstances.map(serviceInstance => {
|
|
21
|
+
if (serviceInstance.healthService && serviceInstance.healthService.checks) {
|
|
22
|
+
if (serviceInstance.healthService.checks.filter(
|
|
23
|
+
check => check.status === 'PASSING'
|
|
24
|
+
).length === serviceInstance.healthService.checks.length) {
|
|
25
|
+
serviceInstance.instanceInfo.status = 'UP'
|
|
26
|
+
} else {
|
|
27
|
+
serviceInstance.instanceInfo.status = 'DOWN'
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
return serviceInstance;
|
|
31
|
+
});
|
|
32
|
+
<%_ } _%>
|
|
19
33
|
this.updatingRoutes = false;
|
|
20
34
|
});
|
|
21
35
|
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/generators/generate-blueprint/templates/generators/generator/templates/template-file.ejs
CHANGED
|
File without changes
|
|
@@ -33,7 +33,7 @@ const NPM_VERSION = commonPackageJson.devDependencies.npm;
|
|
|
33
33
|
const OPENAPI_GENERATOR_CLI_VERSION = '2.5.1';
|
|
34
34
|
|
|
35
35
|
// Libraries version
|
|
36
|
-
const JHIPSTER_DEPENDENCIES_VERSION = '7.9.
|
|
36
|
+
const JHIPSTER_DEPENDENCIES_VERSION = '7.9.1';
|
|
37
37
|
// The spring-boot version should match the one managed by https://mvnrepository.com/artifact/tech.jhipster/jhipster-dependencies/JHIPSTER_DEPENDENCIES_VERSION
|
|
38
38
|
const SPRING_BOOT_VERSION = '2.7.2';
|
|
39
39
|
const LIQUIBASE_VERSION = '4.12.0';
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -229,7 +229,7 @@ spring:
|
|
|
229
229
|
# keytool -genkey -alias <%= baseName.toLowerCase() %> -storetype PKCS12 -keyalg RSA -keysize 2048 -keystore keystore.p12 -validity 3650
|
|
230
230
|
#
|
|
231
231
|
# You can also use Let's Encrypt:
|
|
232
|
-
#
|
|
232
|
+
# See details in topic "Create a Java Keystore (.JKS) from Let's Encrypt Certificates" on https://maximilian-boehm.com/en-gb/blog
|
|
233
233
|
#
|
|
234
234
|
# Then, modify the server.ssl properties so your "server" configuration looks like:
|
|
235
235
|
#
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "generator-jhipster",
|
|
3
|
-
"version": "7.9.
|
|
3
|
+
"version": "7.9.1",
|
|
4
4
|
"description": "Spring Boot + Angular/React/Vue in one handy generator",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"yeoman-generator",
|
|
@@ -123,7 +123,7 @@
|
|
|
123
123
|
"devDependencies": {
|
|
124
124
|
"chai": "4.3.6",
|
|
125
125
|
"ejs-lint": "1.2.2",
|
|
126
|
-
"eslint": "8.
|
|
126
|
+
"eslint": "8.21.0",
|
|
127
127
|
"eslint-config-airbnb-base": "15.0.0",
|
|
128
128
|
"eslint-config-prettier": "8.5.0",
|
|
129
129
|
"eslint-plugin-chai-friendly": "0.7.2",
|
package/utils/field.js
CHANGED
|
@@ -187,15 +187,13 @@ const generateFakeDataForField = (field, faker, changelogDate, type = 'csv') =>
|
|
|
187
187
|
data = undefined;
|
|
188
188
|
}
|
|
189
189
|
}
|
|
190
|
-
if (
|
|
191
|
-
data !== undefined &&
|
|
192
|
-
type === 'ts' &&
|
|
190
|
+
if (data !== undefined) {
|
|
193
191
|
// eslint-disable-next-line no-template-curly-in-string
|
|
194
|
-
![BOOLEAN, INTEGER, LONG, FLOAT, '${floatType}', DOUBLE, BIG_DECIMAL].includes(field.fieldType)
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
192
|
+
if (type === 'ts' && ![BOOLEAN, INTEGER, LONG, FLOAT, '${floatType}', DOUBLE, BIG_DECIMAL].includes(field.fieldType)) {
|
|
193
|
+
data = `'${typeof data === 'string' ? data.replace(/'/g, "\\'") : data}'`;
|
|
194
|
+
} else if (type === 'csv' && field.fieldValidate && field.fieldValidateRules.includes(PATTERN)) {
|
|
195
|
+
data = `"${typeof data === 'string' ? data.replace(/"/g, '\\"') : data}"`;
|
|
196
|
+
}
|
|
199
197
|
}
|
|
200
198
|
|
|
201
199
|
return data;
|